View Single Post
  #2   Report Post  
Posted to microsoft.public.excel.programming
Jim Rech Jim Rech is offline
external usenet poster
 
Posts: 2,718
Default Rightclicking with 'sendkeys'

Right clicking on the column header does 2 things: it selects the column and
it opens the column context menu. Is that what you want to do via SendKeys?

Sub a()
SendKeys "^ "
SendKeys "+{F10}"
End Sub

or

Sub aa()
SendKeys "^ +{F10}"
End Sub


--
Jim
"Zakynthos" wrote in message
...
| Can this be done?
|
| I need to populate a database (Oracle based) with data from Excel but to
get
| data into this database it involves rightclicking the column heading
followed
| by tab keys to enter data. I have checked to see if the 'right click' key
on
| the keyboard works -it doesn't - nor can any other key on the keyboard
| replicate a right mouse click.
|
| I know I can use sendkeys for the tabs but is there a sendkeys statement
to
| produce the equivalent of this right clicking of the column heading?