Kamis, 12 April 2012

RE: [MS_AccessPros] Proc_Exit

 

Connie-

If you want the next executed statement to be the one after the Proc_Exit label,
then do:

GoTo Proc_Exit

But if all Proc_Exit does is fall into an Exit Sub, why do that?

John Viescas, author
Microsoft Office Access 2010 Inside Out
Microsoft Office Access 2007 Inside Out
Building Microsoft Access Applications
Microsoft Office Access 2003 Inside Out
SQL Queries for Mere Mortals
http://www.viescas.com/
(Paris, France)

----------------------------

From: MS_Access_Professionals@yahoogroups.com
[mailto:MS_Access_Professionals@yahoogroups.com] On Behalf Of mrsgoudge
Sent: Thursday, April 12, 2012 5:45 PM
To: MS_Access_Professionals@yahoogroups.com
Subject: Re: [MS_AccessPros] Proc_Exit

 
John,

Would I put "Exit" in the code to send it to Proc_Exit?

Thanks again!
Connie

--- In MS_Access_Professionals@yahoogroups.com, John Viescas <JohnV@...> wrote:
>
> Connie-
>
> No. Exit Sub leaves the code without executing anything else.
>
> John Viescas, author
> Microsoft Office Access 2010 Inside Out
> Microsoft Office Access 2007 Inside Out
> Building Microsoft Access Applications
> Microsoft Office Access 2003 Inside Out
> SQL Queries for Mere Mortals
> http://www.viescas.com/
> (Paris, France)
>
> -------------------------------------
>
> From: MS_Access_Professionals@yahoogroups.com
> [mailto:MS_Access_Professionals@yahoogroups.com] On Behalf Of mrsgoudge
> Sent: Thursday, April 12, 2012 5:12 PM
> To: MS_Access_Professionals@yahoogroups.com
> Subject: [MS_AccessPros] Proc_Exit
>
>  
> Good morning/afternoon all!
>
> I have the following near the end of each procedure:
> Proc_Exit:
> Exit Sub
>
> If an early exit is required does "Exit Sub" in the code before this then go
> through the Proc_Exit?
>
> Thanks!
> Connie
>

__._,_.___
Recent Activity:
.

__,_._,___

Tidak ada komentar:

Posting Komentar