troubleshooting Question

Win 7 - switching from XP - any code issues

Avatar of pdvsa
pdvsaFlag for United States of America asked on
Microsoft Access
6 Comments1 Solution362 ViewsLast Modified:
Experts, I have switched from XP/Access 2007 to Win7/Acces 2010.
 I import excel data on a regular basis and for some reason the import doesnt work as it should.  
I am wondering if the below code (showing only partial code) should be updated to reflect the switch in operating system?

Maybe there are path differences between Win7 and XP but in addition is there anything else in the below that I need to change due to the switch?  I am trying to figure this out by process of elimination and first need to know if there are other codes to update besides the path.  thank you

       CurrentDb.Execute "delete * from [Import-CSM2]"

    Set xlApp = New Excel.Application
    With xlApp
        .Visible = False
        Set xlWB = .Workbooks.Open("C:\Documents and Settings\AJ\My Documents\Work\Company\Banks\CSM\Outstanding Reports (by tab).xlsm", , False)
        strName = xlWB.Sheets(1).Name
    End With
    Set xlWB = Nothing
    Set xlApp = Nothing
      DoCmd.TransferSpreadsheet acImport, , "Import-CSM2", "C:\Documents and Settings\AJ\My Documents\Work\Company\Banks\CSM\Outstanding Reports (by tab).xlsm", True, strName & "!"
    DoCmd.OpenQuery "qryUpdateCSM2_SovToSant"

Open in new window


Our community of experts have been thoroughly vetted for their expertise and industry experience.

Join our community to see this answer!
Unlock 1 Answer and 6 Comments.
Start Free Trial
Learn from the best

Network and collaborate with thousands of CTOs, CISOs, and IT Pros rooting for you and your success.

Andrew Hancock - VMware vExpert
See if this solution works for you by signing up for a 7 day free trial.
Unlock 1 Answer and 6 Comments.
Try for 7 days

”The time we save is the biggest benefit of E-E to our team. What could take multiple guys 2 hours or more each to find is accessed in around 15 minutes on Experts Exchange.

-Mike Kapnisakis, Warner Bros