'Execution error' on cancel

'Execution error' on cancel

Anonymous
Not applicable
518 Views
8 Replies
Message 1 of 9

'Execution error' on cancel

Anonymous
Not applicable
Okay, this is my first vba project so please don't crucify me 🙂

I've written a simple routine for plotting, which presents the user with a
dialog box of four option buttons, each representing a defined pagesetup in
the drawing. The user picks an option, and clicks GO. This all works fine.

I call the form up with a toolbar button:
--
^C^C(command "-vbarun" "QPlot.dvb!Module1.QuickPlot")
--
The QuickPlot sub is this:
--
Public Sub QuickPlot()
fmQPlot.Show
End Sub
--
The cmdCancel code:
--
Private Sub cmdCancel_Click()
End
End Sub
--
When I click Cancel, the command line reads:
--
Command: (command "-vbarun" "QPlot.dvb!Module1.QuickPlot") -vbarun
Initializing VBA System...
Macro name: QPlot.dvb!Module1.QuickPlot Execution error
Command: nil
--
Why the error?

Thanks,
Adam
0 Likes
519 Views
8 Replies
Replies (8)
Message 2 of 9

Anonymous
Not applicable
Don't use End, use Unload Me.

--
R. Robert Bell, MCSE
www.AcadX.com


"Adam Wuellner" wrote in message
news:DE98EA4484735D70E4F8843F28D971ED@in.WebX.maYIadrTaRb...
| Okay, this is my first vba project so please don't crucify me 🙂
|
| I've written a simple routine for plotting, which presents the user with a
| dialog box of four option buttons, each representing a defined pagesetup
in
| the drawing. The user picks an option, and clicks GO. This all works
fine.
|
| I call the form up with a toolbar button:
| --
| ^C^C(command "-vbarun" "QPlot.dvb!Module1.QuickPlot")
| --
| The QuickPlot sub is this:
| --
| Public Sub QuickPlot()
| fmQPlot.Show
| End Sub
| --
| The cmdCancel code:
| --
| Private Sub cmdCancel_Click()
| End
| End Sub
| --
| When I click Cancel, the command line reads:
| --
| Command: (command "-vbarun" "QPlot.dvb!Module1.QuickPlot") -vbarun
| Initializing VBA System...
| Macro name: QPlot.dvb!Module1.QuickPlot Execution error
| Command: nil
| --
| Why the error?
|
| Thanks,
| Adam
|
|
0 Likes
Message 3 of 9

Anonymous
Not applicable
Try using "Unload Me" in place of "End" in the cancel button's click event.

Chuck


"Adam Wuellner" wrote in message
news:DE98EA4484735D70E4F8843F28D971ED@in.WebX.maYIadrTaRb...
> Okay, this is my first vba project so please don't crucify me 🙂
>
> I've written a simple routine for plotting, which presents the user with a
> dialog box of four option buttons, each representing a defined pagesetup
in
> the drawing. The user picks an option, and clicks GO. This all works
fine.
>
> I call the form up with a toolbar button:
> --
> ^C^C(command "-vbarun" "QPlot.dvb!Module1.QuickPlot")
> --
> The QuickPlot sub is this:
> --
> Public Sub QuickPlot()
> fmQPlot.Show
> End Sub
> --
> The cmdCancel code:
> --
> Private Sub cmdCancel_Click()
> End
> End Sub
> --
> When I click Cancel, the command line reads:
> --
> Command: (command "-vbarun" "QPlot.dvb!Module1.QuickPlot") -vbarun
> Initializing VBA System...
> Macro name: QPlot.dvb!Module1.QuickPlot Execution error
> Command: nil
> --
> Why the error?
>
> Thanks,
> Adam
>
>
0 Likes
Message 4 of 9

Anonymous
Not applicable
...and the race is on between the fast guns rrb and cg with rrb by a nose!

"Chuck Gabriel" wrote in message
news:F35A3FD20FB291FFB24863F5C275AC17@in.WebX.maYIadrTaRb...
> Try using "Unload Me" in place of "End" in the cancel button's click
event.
>
> Chuck
>
>
> "Adam Wuellner" wrote in message
> news:DE98EA4484735D70E4F8843F28D971ED@in.WebX.maYIadrTaRb...
> > Okay, this is my first vba project so please don't crucify me 🙂
> >
> > I've written a simple routine for plotting, which presents the user with
a
> > dialog box of four option buttons, each representing a defined pagesetup
> in
> > the drawing. The user picks an option, and clicks GO. This all works
> fine.
> >
> > I call the form up with a toolbar button:
> > --
> > ^C^C(command "-vbarun" "QPlot.dvb!Module1.QuickPlot")
> > --
> > The QuickPlot sub is this:
> > --
> > Public Sub QuickPlot()
> > fmQPlot.Show
> > End Sub
> > --
> > The cmdCancel code:
> > --
> > Private Sub cmdCancel_Click()
> > End
> > End Sub
> > --
> > When I click Cancel, the command line reads:
> > --
> > Command: (command "-vbarun" "QPlot.dvb!Module1.QuickPlot") -vbarun
> > Initializing VBA System...
> > Macro name: QPlot.dvb!Module1.QuickPlot Execution error
> > Command: nil
> > --
> > Why the error?
> >
> > Thanks,
> > Adam
> >
> >
>
>
0 Likes
Message 5 of 9

Anonymous
Not applicable
I'm on DSL, wonder what Chuck is on... 😉

--
R. Robert Bell, MCSE
www.AcadX.com


"Mark Propst" wrote in message
news:0116F31AF3A3DC72834AE148F89D85D7@in.WebX.maYIadrTaRb...
| ...and the race is on between the fast guns rrb and cg with rrb by a nose!
|
| "Chuck Gabriel" wrote in message
| news:F35A3FD20FB291FFB24863F5C275AC17@in.WebX.maYIadrTaRb...
| > Try using "Unload Me" in place of "End" in the cancel button's click
| event.
| >
| > Chuck
| >
| >
| > "Adam Wuellner" wrote in message
| > news:DE98EA4484735D70E4F8843F28D971ED@in.WebX.maYIadrTaRb...
| > > Okay, this is my first vba project so please don't crucify me 🙂
| > >
| > > I've written a simple routine for plotting, which presents the user
with
| a
| > > dialog box of four option buttons, each representing a defined
pagesetup
| > in
| > > the drawing. The user picks an option, and clicks GO. This all works
| > fine.
| > >
| > > I call the form up with a toolbar button:
| > > --
| > > ^C^C(command "-vbarun" "QPlot.dvb!Module1.QuickPlot")
| > > --
| > > The QuickPlot sub is this:
| > > --
| > > Public Sub QuickPlot()
| > > fmQPlot.Show
| > > End Sub
| > > --
| > > The cmdCancel code:
| > > --
| > > Private Sub cmdCancel_Click()
| > > End
| > > End Sub
| > > --
| > > When I click Cancel, the command line reads:
| > > --
| > > Command: (command "-vbarun" "QPlot.dvb!Module1.QuickPlot") -vbarun
| > > Initializing VBA System...
| > > Macro name: QPlot.dvb!Module1.QuickPlot Execution error
| > > Command: nil
| > > --
| > > Why the error?
| > >
| > > Thanks,
| > > Adam
| > >
| > >
| >
| >
|
|
0 Likes
Message 6 of 9

Anonymous
Not applicable
Thank you Chuck and RRB.

-Adam
0 Likes
Message 7 of 9

Anonymous
Not applicable
I am on DSL as well. I blame my arthritis. I mean the sun was in my eyes.
Uh, I wasn't ready. I call Do Over.

Chuck


"R. Robert Bell" wrote in message
news:440127C8AA811BAF49ED84D2C185EC03@in.WebX.maYIadrTaRb...
> I'm on DSL, wonder what Chuck is on... 😉
>
> --
> R. Robert Bell, MCSE
> www.AcadX.com
>
>
> "Mark Propst" wrote in message
> news:0116F31AF3A3DC72834AE148F89D85D7@in.WebX.maYIadrTaRb...
> | ...and the race is on between the fast guns rrb and cg with rrb by a
nose!
> |
> | "Chuck Gabriel" wrote in message
> | news:F35A3FD20FB291FFB24863F5C275AC17@in.WebX.maYIadrTaRb...
> | > Try using "Unload Me" in place of "End" in the cancel button's click
> | event.
> | >
> | > Chuck
> | >
> | >
> | > "Adam Wuellner" wrote in message
> | > news:DE98EA4484735D70E4F8843F28D971ED@in.WebX.maYIadrTaRb...
> | > > Okay, this is my first vba project so please don't crucify me 🙂
> | > >
> | > > I've written a simple routine for plotting, which presents the user
> with
> | a
> | > > dialog box of four option buttons, each representing a defined
> pagesetup
> | > in
> | > > the drawing. The user picks an option, and clicks GO. This all
works
> | > fine.
> | > >
> | > > I call the form up with a toolbar button:
> | > > --
> | > > ^C^C(command "-vbarun" "QPlot.dvb!Module1.QuickPlot")
> | > > --
> | > > The QuickPlot sub is this:
> | > > --
> | > > Public Sub QuickPlot()
> | > > fmQPlot.Show
> | > > End Sub
> | > > --
> | > > The cmdCancel code:
> | > > --
> | > > Private Sub cmdCancel_Click()
> | > > End
> | > > End Sub
> | > > --
> | > > When I click Cancel, the command line reads:
> | > > --
> | > > Command: (command "-vbarun" "QPlot.dvb!Module1.QuickPlot") -vbarun
> | > > Initializing VBA System...
> | > > Macro name: QPlot.dvb!Module1.QuickPlot Execution error
> | > > Command: nil
> | > > --
> | > > Why the error?
> | > >
> | > > Thanks,
> | > > Adam
> | > >
> | > >
> | >
> | >
> |
> |
>
>
0 Likes
Message 8 of 9

Anonymous
Not applicable
ROTFLOL!!


"Chuck Gabriel" wrote in message
news:EF457E91510B0F080ACC97F84ED8DC9B@in.WebX.maYIadrTaRb...
| I am on DSL as well. I blame my arthritis. I mean the sun was in my
eyes.
| Uh, I wasn't ready. I call Do Over.
0 Likes
Message 9 of 9

Anonymous
Not applicable
Try this
PseudoCode:
'arrrrarrrrarrrrrrarrrrrarrrrrr
Implementation:
Sub Laugh ()
Dim oToDo as New ToDo
Dim sThis as String
sThis = "aarrrrrr"
Dim iTimes as Integer
iTimes = many
Set oToDo = RepeatThis (sThis , iTimes)
Set oToDo = Nothing
End Sub

Function RepeatThis (sWhat as String, iTimes as Integer ) as oToDO
RepeatThis = Repeat (iTimes, sWhat)
End Function

may need some debugging
0 Likes