J
Jonnyboy117
I'm trying to run the following macro with a keyboard shortcut applied:
Sub MainPlot()
'
' MainPlot Macro
' Macro recorded 7/9/2004 by Jonathan G. Metts
' Keyboard Shortcut: Ctrl+Shift+M
Dim Message
ChDir _
"C:\Program Files\Microsoft Visual Studio\Common\MSDEV98\M
Projects\msic2003_mod"
Workbooks.OpenText Filename:= _
"C:\Program Files\Microsoft Visual Studio\Common\MSDEV98\M
Projects\msic2003_mod\rangedata.txt" _
, Origin:=xlWindows, StartRow:=1, DataType:=xlFixedWidth
FieldInfo:= _
Array(Array(0, 1), Array(12, 1), Array(28, 1), Array(44, 1)
Array(60, 1), _
Array(76, 1), Array(92, 1), Array(108, 1), Array(124, 1))
Call AltRangePlot
Call AltTimePlot
Call AoATimePlot
Call MachTimePlot
Call RangeTimePlot
Call ThrustTimePlot
Call VelocityTimePlot
Call WeightTimePlot
Message = MsgBox("When you are ready to plot the geometry in 3D
press Ctrl+Shift+T to " _
& "activate the RunTecplot macro." & Chr(13) & Chr(13) & "(
new Workbook will open, but you " _
& "can easily switch back to this one.", vbOKOnly)
End Sub
As you can see, it's basically a calling program which runs throug
several other macros. I've set the keyboard shortcut for this macro t
Ctrl+Shift+M in the Macro Options, and the macro itself works perfectl
when I click Run from the list of macros (Alt+F8). But if I run i
with the keyboard shortcut, the text file opens but none of the othe
macros are run.
So basically, the macro runs one way (correctly) when run through th
menus, and it runs another way (incompletely) when run with th
keyboard shorcut. It might be useful to note that I didn't include
keyboard shortcut when I originally created this macro; I added i
later by going to the list of macros and clicking on Options.
Any ideas
Sub MainPlot()
'
' MainPlot Macro
' Macro recorded 7/9/2004 by Jonathan G. Metts
' Keyboard Shortcut: Ctrl+Shift+M
Dim Message
ChDir _
"C:\Program Files\Microsoft Visual Studio\Common\MSDEV98\M
Projects\msic2003_mod"
Workbooks.OpenText Filename:= _
"C:\Program Files\Microsoft Visual Studio\Common\MSDEV98\M
Projects\msic2003_mod\rangedata.txt" _
, Origin:=xlWindows, StartRow:=1, DataType:=xlFixedWidth
FieldInfo:= _
Array(Array(0, 1), Array(12, 1), Array(28, 1), Array(44, 1)
Array(60, 1), _
Array(76, 1), Array(92, 1), Array(108, 1), Array(124, 1))
Call AltRangePlot
Call AltTimePlot
Call AoATimePlot
Call MachTimePlot
Call RangeTimePlot
Call ThrustTimePlot
Call VelocityTimePlot
Call WeightTimePlot
Message = MsgBox("When you are ready to plot the geometry in 3D
press Ctrl+Shift+T to " _
& "activate the RunTecplot macro." & Chr(13) & Chr(13) & "(
new Workbook will open, but you " _
& "can easily switch back to this one.", vbOKOnly)
End Sub
As you can see, it's basically a calling program which runs throug
several other macros. I've set the keyboard shortcut for this macro t
Ctrl+Shift+M in the Macro Options, and the macro itself works perfectl
when I click Run from the list of macros (Alt+F8). But if I run i
with the keyboard shortcut, the text file opens but none of the othe
macros are run.
So basically, the macro runs one way (correctly) when run through th
menus, and it runs another way (incompletely) when run with th
keyboard shorcut. It might be useful to note that I didn't include
keyboard shortcut when I originally created this macro; I added i
later by going to the list of macros and clicking on Options.
Any ideas