Access 2010 Macros (1 Viewer)

Design by Sue

Registered User.
Local time
Today, 00:09
Joined
Jul 16, 2010
Messages
648
I am sure this has been discussed ad nausium for many of you, but I just upgraded (?) to access 2010. After years of working with visual basic coding and access 2003 I am totally stumped by 2010 writing all coding in macros through their wizards. I know I am stuck in my old ways, but I just spent an overly long period of time trying to figure out how to add a simple me.refresh to the macro with no luck. So my question, is there some way to set Access to use code rather than macros for programming it's wizards? I have read where you can convert the macros to code, but why the double work? I have a project I need to complete and would rather not spend the extra time to learn every thing over.

Thanks
Sue
 

hardyd44

Registered User.
Local time
Today, 08:09
Joined
Nov 22, 2005
Messages
77
Sue,

I have had the same barrier as you, however i found using a wizard when needed then converting the macro to VBA pretty painless to be honest

Regards

Dean
 

DJkarl

Registered User.
Local time
Today, 02:09
Joined
Mar 16, 2007
Messages
1,028
I have Access 2010 at work and I am able to directly create VBA modules, and code just as before, I'm not sure what issue you are referring to.
 

Design by Sue

Registered User.
Local time
Today, 00:09
Joined
Jul 16, 2010
Messages
648
Again, please forgive me for asking what is probably a dumb thing, but can you tell me how - I have searched for instructions but must have a mental block about this. How do you convert it - so that it is painless?

Appreciate your input!
 

Design by Sue

Registered User.
Local time
Today, 00:09
Joined
Jul 16, 2010
Messages
648
AJkarl - I am using wizards to create the button coding to delete a record - instead of creating the code it produces a macro - I would like to add code to the wizard produced coding and rather than learn a whole new process I would like to code it as before in Visual Basic. This is what my problem is. Also I see in a button in the macro area "Convert Macros to Visual Basic" but it is grayed out.

Sue
 

Beetle

Duly Registered Boozer
Local time
Today, 01:09
Joined
Apr 30, 2011
Messages
1,808
After years of working with visual basic coding and access 2003 I am totally stumped by 2010 writing all coding in macros through their wizards.

You can still use VBA code in A2010 just as in previous versions, provided that you are designing client objects (forms, reports) rather than web objects. If you are designing web objects then VBA code is not an option, you must use macros for your event handling.

So my question, is there some way to set Access to use code rather than macros for programming it's wizards?

I don't believe so. The Wizard has to be designed to handle both client and web objects, therefore it's default is going to be macros because that's the only way to ensure that any Wizard designed events will be viable for both types of objects. If you're familiar with VBA coding then why use the Wizard at all? Why not just select an object event and write the code?
 

Design by Sue

Registered User.
Local time
Today, 00:09
Joined
Jul 16, 2010
Messages
648
Finally I found that I had to add the Convert Macros to Visual Basic to a custom group on the menu. Thanks for your help!

Sue
 

DJkarl

Registered User.
Local time
Today, 02:09
Joined
Mar 16, 2007
Messages
1,028
I guess I missed the part where you said you were using the wizard to create code. When creating a form I add a control, then go to the event handler, add the event and it pops up a choice for Code Builder, then I'm in the VBA window and can code to my hearts content.
 

Users who are viewing this thread

Top Bottom