Want to win a PS4? Go Premium and enter to win our High-Tech Treats giveaway. Enter to Win

x
?
Solved

Access 2007 Macro help

Posted on 2011-09-30
8
Medium Priority
?
397 Views
Last Modified: 2012-05-12
Inheirited a MS Access 2007 thingy.

There is a macro that is in the db that isn't functioning.  There are only 2 steps to this macro.  Single stepping through leads to the second step being the issue.
The error is:

cannot open database ''.  It may not be a database that your application recognizes, or the file may be corupt.

This second step is attempting to import a text file into an existing table (fyi... the first step deletes all existing records, successfully, from the same table).

Any idea on what the issue may be or how I can view the "saved" import for errors?

This was working at one time and now it isn't and I have been called in to help.
0
Comment
Question by:classnet
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 3
  • 2
  • 2
8 Comments
 
LVL 28

Accepted Solution

by:
burrcm earned 2000 total points
ID: 36891300
Hard to say without a look. Clean out data, compact, zip and post a copy of the db here along with a sample of the text file to import. Sounds like a missing import specification, but should be easy enough to sort out with a sample.

Chris B
0
 

Author Comment

by:classnet
ID: 36891472
Can I view the code to determine this?
0
 
LVL 74

Expert Comment

by:Jeffrey Coachman
ID: 36891785
<Can I view the code to determine this?>
There is no "Code to see this"

Simply post a sample of the DB as burrcm requested
0
Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

 
LVL 74

Expert Comment

by:Jeffrey Coachman
ID: 36891790
Sample database notes:
1. Back up your database(s).
2. Combine the front and back ends into one database file.
3. Remove any startup options, unless they are relevant to the issue.
4. Remove any records unless they are relevant to the issue.
5. Delete any objects that do not relate directly to the issue.
6. Remove any references to any "linked" files (files outside of the database, Images, OLE Files, ...etc)
7. Remove any references to any third party Active-x Controls (unless they are relevant to the issue)
8. Remove, obfuscate, encrypt, or otherwise disguise, any sensitive data.
9. Compile the code. (From the VBA code window, click: Debug-->Compile)
10. Run the compact/Repair utility.
11. Remove any Passwords and/or security.
12. If a form is involved in the issue, set the Modal and Popup properties to: No
    (Again, unless these properties are associated with the issue)
13. Post the explicit steps to replicate the issue.
14. Test the database before posting.

In other words, ...post a database that we can easily open and immediately see and/or troubleshoot the issue.
And if applicable, also include a clear graphical representation of the *Exact* results you are expecting, based on the sample data.
0
 
LVL 28

Expert Comment

by:burrcm
ID: 36894683
I doubt that you intended to accept my comment as a solution, as nothing has been resolved yet. Please post the requested samples so we may assist. I will request that this be reopened.

Mods - Please "unaccept" and reopen, as this is not resolved.

thanks

Chris B
0
 

Author Comment

by:classnet
ID: 36912900
Actually just needed to "compact and repair"  :-/
0
 
LVL 74

Expert Comment

by:Jeffrey Coachman
ID: 36914729
Then please accept  burrcm's first post as the solution...

;-)

Jeff
0

Featured Post

Free Tool: IP Lookup

Get more info about an IP address or domain name, such as organization, abuse contacts and geolocation.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

In Part II of this series, I will discuss how to identify all open instances of Excel and enumerate the workbooks, spreadsheets, and named ranges within each of those instances.
If you are a mobile app developer and especially develop hybrid mobile apps then these 4 mistakes you must avoid for hybrid app development to be the more genuine app developer.
Have you created a query with information for a calendar? ... and then, abra-cadabra, the calendar is done?! I am going to show you how to make that happen. Visualize your data!  ... really see it To use the code to create a calendar from a q…
Loops Section Overview
Suggested Courses

610 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question