Thanks for the repsonses. The problem wasn't the vba it was in the bat file. When I ran it from vba before I fixed the problem with the bat file it ran so fast that I didn't see that the dos prompt was starting at a different directory than when I pulled up the prompt myself. All I had to do...
I'm trying to run a bat file using the shell function and it's not working. It opens up the dos prompt then goes away. This is the code:
Shell "c:\smdr\swbdl.bat", vbNormalFocus
Is there something wrong with this or is there another approach I should take? The bat file itself...
Thank you neufarth. I didn't know I could make it replace itself. That was my hangup. Sothe code would be soehting like:
dbengine.compactdb "my.mdb, "my.mdb"
JoeMiller, I always get a space error if I reach 1 gb. What verson are you talking about? I'm using Access '97...
Is there anyway to compact a database without making a copy of it? What I really want to do is to compact the database before I create a large table in the database which will be close to the 1 gb size which is the max for '97.
Try this:
docmd.transferspreadsheet acimport, 8, _ strtable, "c:\samples\" & strfile, False
8 is for the version of the worksheet. strtable is the name of the table your importing to. In this case it's a variable i created normally it would have "" around it. the...
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.