Does Access Create VBA code when I use Menus & Wizards ? If so where is it ?

W

Will

When I use the Menus & Wizards in Access to create Tables, Queries, Forms,
Reports, etc

Does Access actualy create VBA code... just like one would do if they were a
programmer?

If so, where can I find it as I would like to study and see exactly what
Access is doing.

Thanks for any help.
 
D

Douglas J. Steele

No VBA code is involved with creating tables or queries, but anytime you use
a wizard with a form or report, there should be VBA associated with it.
 
W

Will

Thanks Doug.

If I create a form... with a sub-form... and maybe a combo box...

Does Access create VBA code for that?

Regardless... anytime Access creates VBA code... where do I click to find
it?

thanks for the help.
 
B

Br@dley

Will said:
Thanks Doug.

If I create a form... with a sub-form... and maybe a combo box...

Does Access create VBA code for that?

Regardless... anytime Access creates VBA code... where do I click to
find it?

thanks for the help.

You're creating Access objects (forms, controls). Access provides the
ability to use VBA to write script that can be triggered by different
events on an object (eg. button press, form open.. etc). Generally there
won't be any script unless you write it (or it has been generated by a
wizard or something).

eg. to view the VBA script behind a form open the form in design view
and select View/Code from the menu. Or, open the form/control's property
sheet and scroll down to the list of events. If there is VBA script
behind an event the text "[Event Procedure]" will be displayed. To
access it simply click on that text and then press the build button that
appears to the right.

Hope that was what you were wanting to know.....

--
regards,

Bradley

A Christian Response
http://www.pastornet.net.au/response
 
L

Larry Daugherty

At one time Microsoft included the code for the wizards with the
developer tools. They no longer do that but I believe that Getz et
alia were still including it in the Access [YourVersion] Developer's
Handbook.

I think that your question had to do with code behind the objects
created. Some of it can be pretty instructive. Take a copy of one of
your applications and play around with adding comboboxes in all of the
suggested flavors and look at the generated code.

HTH
--
-Larry-
--

Br@dley said:
Will said:
Thanks Doug.

If I create a form... with a sub-form... and maybe a combo box...

Does Access create VBA code for that?

Regardless... anytime Access creates VBA code... where do I click to
find it?

thanks for the help.

You're creating Access objects (forms, controls). Access provides the
ability to use VBA to write script that can be triggered by different
events on an object (eg. button press, form open.. etc). Generally there
won't be any script unless you write it (or it has been generated by a
wizard or something).

eg. to view the VBA script behind a form open the form in design view
and select View/Code from the menu. Or, open the form/control's property
sheet and scroll down to the list of events. If there is VBA script
behind an event the text "[Event Procedure]" will be displayed. To
access it simply click on that text and then press the build button that
appears to the right.

Hope that was what you were wanting to know.....

--
regards,

Bradley

A Christian Response
http://www.pastornet.net.au/response
 
W

Will

Larry,

Where do I find the "code behind the objects" in Access?

I thought the regular drag, drop and click interface was actually creating
real code to do all the various task... and yes, I wanted to study that code
to see what Access was really doing.

But, I don't know where to find such code... if indeed Access creates such.

Of course I can look at the actual SQL when a query is created... but when
you start building forms and adding combo boxes, etc... is Access creating
code... VBA/Access Code or other wise? And if so where is it?

Thanks for the help.

Larry Daugherty said:
At one time Microsoft included the code for the wizards with the
developer tools. They no longer do that but I believe that Getz et
alia were still including it in the Access [YourVersion] Developer's
Handbook.

I think that your question had to do with code behind the objects
created. Some of it can be pretty instructive. Take a copy of one of
your applications and play around with adding comboboxes in all of the
suggested flavors and look at the generated code.

HTH
--
-Larry-
--

Br@dley said:
Will said:
Thanks Doug.

If I create a form... with a sub-form... and maybe a combo box...

Does Access create VBA code for that?

Regardless... anytime Access creates VBA code... where do I click to
find it?

thanks for the help.

You're creating Access objects (forms, controls). Access provides the
ability to use VBA to write script that can be triggered by different
events on an object (eg. button press, form open.. etc). Generally there
won't be any script unless you write it (or it has been generated by a
wizard or something).

eg. to view the VBA script behind a form open the form in design view
and select View/Code from the menu. Or, open the form/control's property
sheet and scroll down to the list of events. If there is VBA script
behind an event the text "[Event Procedure]" will be displayed. To
access it simply click on that text and then press the build button that
appears to the right.

Hope that was what you were wanting to know.....
message No VBA code is involved with creating tables or queries, but anytime
you use a wizard with a form or report, there should be VBA
associated with it.

--
Doug Steele, Microsoft Access MVP

(no e-mails, please!)



When I use the Menus & Wizards in Access to create Tables, Queries,
Forms, Reports, etc

Does Access actualy create VBA code... just like one would do if
they were a programmer?

If so, where can I find it as I would like to study and see exactly
what Access is doing.

Thanks for any help.

--
regards,

Bradley

A Christian Response
http://www.pastornet.net.au/response
 
G

Guest

I have often wondered this and I can't seem to get a straight answer from
anyone either! What Will is asking is "Can I inspect the code generated by
wizards and if so where is it please". I'm with you Will!!
--
Peter J Aldersley (aka kayseypops)
BEDWORTH
England


Will said:
Larry,

Where do I find the "code behind the objects" in Access?

I thought the regular drag, drop and click interface was actually creating
real code to do all the various task... and yes, I wanted to study that code
to see what Access was really doing.

But, I don't know where to find such code... if indeed Access creates such.

Of course I can look at the actual SQL when a query is created... but when
you start building forms and adding combo boxes, etc... is Access creating
code... VBA/Access Code or other wise? And if so where is it?

Thanks for the help.

Larry Daugherty said:
At one time Microsoft included the code for the wizards with the
developer tools. They no longer do that but I believe that Getz et
alia were still including it in the Access [YourVersion] Developer's
Handbook.

I think that your question had to do with code behind the objects
created. Some of it can be pretty instructive. Take a copy of one of
your applications and play around with adding comboboxes in all of the
suggested flavors and look at the generated code.

HTH
--
-Larry-
--

Br@dley said:
Will wrote:
Thanks Doug.

If I create a form... with a sub-form... and maybe a combo box...

Does Access create VBA code for that?

Regardless... anytime Access creates VBA code... where do I click to
find it?

thanks for the help.

You're creating Access objects (forms, controls). Access provides the
ability to use VBA to write script that can be triggered by different
events on an object (eg. button press, form open.. etc). Generally there
won't be any script unless you write it (or it has been generated by a
wizard or something).

eg. to view the VBA script behind a form open the form in design view
and select View/Code from the menu. Or, open the form/control's property
sheet and scroll down to the list of events. If there is VBA script
behind an event the text "[Event Procedure]" will be displayed. To
access it simply click on that text and then press the build button that
appears to the right.

Hope that was what you were wanting to know.....

message No VBA code is involved with creating tables or queries, but anytime
you use a wizard with a form or report, there should be VBA
associated with it.

--
Doug Steele, Microsoft Access MVP

(no e-mails, please!)



When I use the Menus & Wizards in Access to create Tables, Queries,
Forms, Reports, etc

Does Access actualy create VBA code... just like one would do if
they were a programmer?

If so, where can I find it as I would like to study and see exactly
what Access is doing.

Thanks for any help.

--
regards,

Bradley

A Christian Response
http://www.pastornet.net.au/response
 
B

Brendan Reynolds

The answer depends on which wizard we're talking about. For example, the
control wizard that runs when you place a command button on a form creates
VBA code, which you can see by right-clicking the newly-created command
button and choosing 'Build Event' from the pop-up menu. But many other
wizards do not generate any code at all.

If you really want to see what happens 'behind the scenes' when you create a
form, you can use the undocumented 'SaveAsText' method to save the
definition of a form to a text file. For example ...

SaveAsText acForm, "Form1", "c:\usenet\formdef.txt"

But don't get too excited about this. It's really not very interesting or
useful.

--
Brendan Reynolds
Access MVP

kayseypops said:
I have often wondered this and I can't seem to get a straight answer from
anyone either! What Will is asking is "Can I inspect the code generated
by
wizards and if so where is it please". I'm with you Will!!
--
Peter J Aldersley (aka kayseypops)
BEDWORTH
England


Will said:
Larry,

Where do I find the "code behind the objects" in Access?

I thought the regular drag, drop and click interface was actually
creating
real code to do all the various task... and yes, I wanted to study that
code
to see what Access was really doing.

But, I don't know where to find such code... if indeed Access creates
such.

Of course I can look at the actual SQL when a query is created... but
when
you start building forms and adding combo boxes, etc... is Access
creating
code... VBA/Access Code or other wise? And if so where is it?

Thanks for the help.

Larry Daugherty said:
At one time Microsoft included the code for the wizards with the
developer tools. They no longer do that but I believe that Getz et
alia were still including it in the Access [YourVersion] Developer's
Handbook.

I think that your question had to do with code behind the objects
created. Some of it can be pretty instructive. Take a copy of one of
your applications and play around with adding comboboxes in all of the
suggested flavors and look at the generated code.

HTH
--
-Larry-
--

Will wrote:
Thanks Doug.

If I create a form... with a sub-form... and maybe a combo box...

Does Access create VBA code for that?

Regardless... anytime Access creates VBA code... where do I click
to
find it?

thanks for the help.

You're creating Access objects (forms, controls). Access provides
the
ability to use VBA to write script that can be triggered by
different
events on an object (eg. button press, form open.. etc). Generally
there
won't be any script unless you write it (or it has been generated by
a
wizard or something).

eg. to view the VBA script behind a form open the form in design
view
and select View/Code from the menu. Or, open the form/control's
property
sheet and scroll down to the list of events. If there is VBA script
behind an event the text "[Event Procedure]" will be displayed. To
access it simply click on that text and then press the build button
that
appears to the right.

Hope that was what you were wanting to know.....

message No VBA code is involved with creating tables or queries, but
anytime
you use a wizard with a form or report, there should be VBA
associated with it.

--
Doug Steele, Microsoft Access MVP

(no e-mails, please!)



When I use the Menus & Wizards in Access to create Tables,
Queries,
Forms, Reports, etc

Does Access actualy create VBA code... just like one would do if
they were a programmer?

If so, where can I find it as I would like to study and see
exactly
what Access is doing.

Thanks for any help.

--
regards,

Bradley

A Christian Response
http://www.pastornet.net.au/response
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top