Very basic Visual Basic help required 
Author Message
 Very basic Visual Basic help required

I have reason to rename 25 tables within a single A2k mdb on a regular
basis. I have written a macro to do this with individual 'renames', but as
the new name varies from time to time I have to change each statement in the
macro to reflect this. What I want is a macro that runs a VBA module,
because I can change the VB code in a fraction of the time.

The renaming code I will work on myself, but I would like to know what code
wraps around this to enable me to access and rename table names. Do I use
'Private Sub/End Sub'? And what about DoCMD, where does that fit in?

I know it's a basic question but I *can* program to some extent. I once
learned REXX (any mainframers remember that?) from the online help files but
it took me weeks to actually run any code because I didn't know each module
had to begin with /* */  !!!

I'd appreciate a kickstart!

Terry



Wed, 26 Dec 2001 03:00:00 GMT  
 Very basic Visual Basic help required
I tried to dig up the code but failed.  You simply needs to declare the
table(s) as a tabledef and rename them using the .Name extension.  This way
you can step the names in whatever way you want, adding the current date and
time , etc... to the "new" name.  Lookup tabledef in your VBA help.

I am growing into the from an old Cobol (MVS) background.

ToddP


Quote:
> I have reason to rename 25 tables within a single A2k mdb on a regular
> basis. I have written a macro to do this with individual 'renames', but as
> the new name varies from time to time I have to change each statement in
the
> macro to reflect this. What I want is a macro that runs a VBA module,
> because I can change the VB code in a fraction of the time.

> The renaming code I will work on myself, but I would like to know what
code
> wraps around this to enable me to access and rename table names. Do I use
> 'Private Sub/End Sub'? And what about DoCMD, where does that fit in?

> I know it's a basic question but I *can* program to some extent. I once
> learned REXX (any mainframers remember that?) from the online help files
but
> it took me weeks to actually run any code because I didn't know each
module
> had to begin with /* */  !!!

> I'd appreciate a kickstart!

> Terry



Fri, 28 Dec 2001 03:00:00 GMT  
 
 [ 2 post ] 

 Relevant Pages 

1. URGENT: ASP Components from Visual Basic -- Help Required Please

2. RAS Dial Up API`s In Visual Basic 5/6 [Help Required]

3. Visual Basic 5 Game : Help required...

4. Help required using Winsock API calls with Visual Basic

5. Visual Basic 5 Control Help Required

6. Visual Basic 5 Control Help Required

7. Visual Basic & Visual C++ Programmers required

8. Visual Basic & Visual C++ Programmers required

9. quick basic to visual basic HELP

10. quick basic to visual basic HELP

11. do Visual Basic 6.0 and Visual Basic .NET version beta Working Both

12. Difference between Visual Basic 6 and Visual Basic.Net

 

 
Powered by phpBB® Forum Software