Embarassingly simple question regarding VB Editor

C

carl.wilkens

Dear all,
excuse me for using space for this simple question -- but I have not
found a resolution in the documentation.

When writing Excel macros in the VB Editor, it almost immediately
immediately fills in blanks, but does not move the cursor
correspondingly -- which is very irritating since this suddenly leaves
me continuing my code in the middle of the line. I have to press
[(line) END] button after every VBE space completion (i e very often),
to continue writing the line in my code.

E g, when writing the following line of code
r(1,2)=-log(p(2))/dt
I get to
r(1,2)=-log(p(2))
when the automatic space completion fills in
r(1, 2) = -Log(p(2#))
*but* leaving the cursor at "#" (# just indicates the cursor
position), so if I do not discover the automatic change and do not
press [END] before continuing with "/dt" I end up with
r(1, 2) = -Log(p(2/dt))
which is clearly not the same thing.

I have switched off 'Auto Syntax Check' but it does not seem to cover
this situation. Any clues on how to e g have the code checking invoked
only when I press return?

Thanks,
Carl
 
G

Guest

When the autofill occurs, press "Tab" and the cursor will go to the end of
the autofill.
 
C

carl.wilkens

Thanks for your reply Jim,
but I can have cases where pressing tab once still leaves me inside
the expression instead of the end of the line. For example
r=log(p(i))/dt
is changed into
r = Log(p(i#)) ' # still cursor sign
and tabbing once gives
r = Log(p(i)#).
However, tabbing once more gives
r = Log(p(i) #)
which is then after some seconds changed into the desired
r = Log (p(i))#
suitable for continued code on that line.

Is there a way to turn off this immediate space completion, or at
least have it done when I press Return? It almost seems like a bug to
leave the cursor in the middle of the line, messing up continued
coding. I hope I do not have to start writing code using Notepad...

Thanks for any help.
Regards,
-- Carl

When the autofill occurs, press "Tab" and the cursor will go to the end of
the autofill.
--
Best wishes,

Jim



Dear all,
excuse me for using space for this simple question -- but I have not
found a resolution in the documentation.
When writing Excel macros in the VB Editor, it almost immediately
immediately fills in blanks, but does not move the cursor
correspondingly -- which is very irritating since this suddenly leaves
me continuing my code in the middle of the line. I have to press
[(line) END] button after every VBE space completion (i e very often),
to continue writing the line in my code.
E g, when writing the following line of code
r(1,2)=-log(p(2))/dt
I get to
r(1,2)=-log(p(2))
when the automatic space completion fills in
r(1, 2) = -Log(p(2#))
*but* leaving the cursor at "#" (# just indicates the cursor
position), so if I do not discover the automatic change and do not
press [END] before continuing with "/dt" I end up with
r(1, 2) = -Log(p(2/dt))
which is clearly not the same thing.
I have switched off 'Auto Syntax Check' but it does not seem to cover
this situation. Any clues on how to e g have the code checking invoked
only when I press return?
Thanks,
Carl- Dölj citerad text -

- Visa citerad text -
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top