Since ExecuteMso does not work with gallery controls (apparently) the only
other option I can think of is sendkeys:
Sub aa()
SendKeys "%H"
SendKeys "J"
End Sub
--
Jim
"JeffreyW" wrote in message
...
| As I found out in an earlier post at:
|
|
http://msdn.microsoft.com/newsgroups...=en-us&m=1&p=1
|
| ... the Application.CommandBars.ExecuteMso method apparently does not
work
| with a Gallery Control in Excel 2007.
|
| I subsequently came across this info at:
|
|
http://msdn2.microsoft.com/en-us/library/aa722523.aspx
|
| "The Application.CommandBars class provides the following methods for
| interacting with Fluent UI controls.
|
| Table 1. Methods for the Application.CommandBars class
| Method | Description:
|
| Sub ExecuteMso(idMso As String) | Executes the command that is specified
in
| idMso."
|
| I seem to have problems getting this to work with a Gallery control as
well
| - maybe because of the same issue as above or maybe because I am messing
| something up. Can anyone suggest how I might successfully use this method
to
| call a Gallery Control like "CellStylesGallery" (which is a correct
idMSO)?
|
| Thanks for any insights.
|
| Jeff