| View previous topic :: View next topic |
| Author |
Message |
EdScriptNewbie
Joined: 20 Jan 2007 Posts: 31
|
Posted: Fri Apr 18, 2008 4:15 pm Post subject: Excel: edit existing cell content: how shift to formula bar? |
|
|
I'm doing a script for excel (XP and Office 2003 + all s-p's). In-cell editing is on, but if i want to move around in, edit or add to the text in an existing cell--versus simply replacing it--I have to click on the right end of the formula bar's cell editing field. How do I make a script click there? The location of editing field's moves vertically wrt the window, depending on which tool bars are visible.
1. Is there an excel keystroke that takes the active cursor into the cell editing field? Microsoft's help is opaque on this matter (for something different!), google search results ditto.
2. Or, is there an ahk way to make a mouseclick at the right end of that field no matter where the field is vertically? One angle might be the fact that the field is white, where nothing else is white above the editing field, or even below it until you reach the first visible row (provided the looking is done to the right of the optimistically named "help" field).
THANKS! _________________ ...Ed |
|
| Back to top |
|
 |
Razlin
Joined: 05 Nov 2007 Posts: 434 Location: canada
|
Posted: Fri Apr 18, 2008 4:19 pm Post subject: |
|
|
Im not 100% sure I understand but normally the "end" key moves the cursor to the end of content in a cell in excell.
F2 moves to end of current cell content. _________________ -=Raz=- |
|
| Back to top |
|
 |
EdScriptNewbie
Joined: 20 Jan 2007 Posts: 31
|
Posted: Fri Apr 18, 2008 5:01 pm Post subject: Thanks Razlin I think F2 solves my problem |
|
|
Thanks Razlin I think F2 solves my problem. Thanks again. ...Ed _________________ ...Ed |
|
| Back to top |
|
 |
EdScriptNewbie
Joined: 20 Jan 2007 Posts: 31
|
Posted: Sun Apr 20, 2008 4:34 am Post subject: Didn't work: I need the edit window |
|
|
It turns out that I do need to place the active cursor in the formula bar's editing field. Here's why: if I hit F2 it lets me edit the contents of the cell, but I can't see where I active cursor is as I am doing it, and, it's just not the same. For instance, when I am in that F2 editing state, hitting the End key does move via active position to the end of the text in the cell, but, again, since there is no active cursor it's hard to see where you are and what you are doing.
the solution might be a script that starts at the "close window" X in the upper right-hand corner of the window, and moves straight down until it encounters a band of white space (the editing field), and then does a left click there.
How do I do that? THANKS! _________________ ...Ed |
|
| Back to top |
|
 |
Hasso
Joined: 23 Mar 2005 Posts: 158 Location: Germany
|
Posted: Mon Apr 21, 2008 11:25 am Post subject: |
|
|
Ed,
try | Code: | #IfWinActive, ahk_class XLMAIN
#2:: ;or any other hotkey
ControlClick, EXCEL<1
#IfWinActive
Return
|
Tested. _________________ Hasso
Programmers don't die, they GOSUB without RETURN |
|
| Back to top |
|
 |
EdScriptNewbie
Joined: 20 Jan 2007 Posts: 31
|
Posted: Fri Apr 25, 2008 6:34 am Post subject: |
|
|
Works just fine! THANKS ...Ed _________________ ...Ed |
|
| Back to top |
|
 |
|