Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Convert Access 2013 saved import task to code

Status
Not open for further replies.

crpjaviman

Technical User
Jan 24, 2002
57
US
Hello all,

I am getting back into VBA coding after a few years away and it's coming back slowly plus adapting to the new verbiage.

I have a curious question: how can I convert the saved import tasks in Access 2013 into VBA code? I can manage the import process better if it's in code. If the code can be done from Excel 2013, even better. I'm trying to make a one stop program for the end users from Excel, if possible.

Thanks in advance.

Thanks,
crpjaviman [rockband]
 
Of course in Excel you can record a macro which can take some of the mystery out of the process.
 
That would be great, kray, but I've tried that and it doesn't record the Access actions. I've made sure the references for Access are added but to no progress. I would have to create a createobject mod for Access.

Thoughts?

Thanks,
crpjaviman [rockband]
 
Hi,

You have an Access DB. How does Excel get into the picture?

Skip,
[sub]
[glasses]Just traded in my OLD subtlety...
for a NUance![tongue][/sub]
 
Hi Skip,

The reports originate in Excel, imported to Access, and end back in Excel. I use Access to do some of the heavy queries and sorting from multiple tables then back to Excel.

I am taking over the reports from a previous analyst so I am just trying to keep it moving while I make improvements.

Thanks,
crpjaviman [rockband]
 
I have seen code to do import from csv (not sure about Excel) and code to export to Excel. Unfortunately I do not have anything handy.
 
Of course in Excel you are also able to run queries (SQL) against other worksheets, other workbooks, Access tables, other databases, text files.

Skip,
[sub]
[glasses]Just traded in my OLD subtlety...
for a NUance![tongue][/sub]
 
It is quite possible to by-pass Access all together and do all your magic in Excel. This is just my guess since we don’t have any details about: what you start with and what you need to end up with. A little sample (a simple write-up) could shed some light on the issue...

Have fun.

---- Andy

A bus station is where a bus stops. A train station is where a train stops. On my desk, I have a work station.
 
Hello everyone,

Sorry, I was diverted to another project. I will be back soon to continue the search or re-mod of this report.

I like the idea of converting it all to Excel, maybe one report to do all of the pieces and full of VBA code.

Thanks and talk soon.

Thanks,
crpjaviman [rockband]
 
Hello all,

I've a break from the other project and want to continue my momentum on this project.

Here is the basis:
I have 7 reports that have certain info that I need to compile into a one page report per employee. The information includes DOH, supervisor, a few phone metrics, sales info, and a chart. Not worried about the chart at this time.

Here is what has been done:
I have the reports in an Excel 2013 workbook, a tab per report, and I created pivot tables to compile the info into what I need only in a different workbook. Two of the tabs had multiple entries per employee and had to be comprised and get to one row per agent per day. The workbooks are large in size and is the reason I am working with multiple workbooks.

This is what is needed:
I need to be able to choose an agent from a drop down box and the info to auto populate on the form. The form will have a month's worth of days listed per column (column C is 7/4/2016, column D is 7/5/2016, etc.) and the info below should correlate to the date and the employee.

I know that I need to have a few up to a bunch of Vlookups to accomplish this but I was wondering if there is a slightly different way to do the same. I also have tried to create tables from the pivots but it won't let me. I may be doing something wrong. Soooo, I can't create relationships in order to create a query.

Reminder; I have been out of reporting / programming for awhile but now I am getting back into it but am a bit behind the versions...catching up fast though.

Any ideas, suggestions, or examples would be greatly appreciated.

Thanks,
crpjaviman [rockband]
 
Using reports as data sources is often a huge mistake. I try to move heaven and earth to get as close to source data as possible.

So all we've heard is generalities. What happens in vagueness, stays in vagueness.

Chances are you will be AGGREGATING data rather than looking up specific data elements, but how could I know from what you've disclosed?

Skip,
[sub]
[glasses]Just traded in my OLD subtlety...
for a NUance![tongue][/sub]
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top