Still celebrating National IT Professionals Day with 3 months of free Premium Membership. Use Code ITDAY17

x
?
Solved

Receiving run-time error '3161'. Could not decrypt file trying to do   DoCmd.TransferSpreadsheet  in Access 2003

Posted on 2010-08-31
5
Medium Priority
?
2,054 Views
Last Modified: 2012-08-13
I have an access aplication that parses through a list of excel files to populate an access table on a weekly basis

The excel files (which are in the same format) come from our various shops spread out across the country.

The process has been working great until this week's run of the appplication.

An attempt to process the following statement for only a few of the files

                    DoCmd.TransferSpreadsheet acImport, acSpreadsheetTypeExcel9, _
                    strTable, strPathFile, blnHasFieldNames, objExcel.Worksheets(lngCount).name & strTransferSpreadSheetRange

results in a run-time error '3161'. Could not decrypt file.

The remainder of the files have no problem.

Does anyone know of a recent windows xp pro and/or office 2003 update that may be causing this?

Visually all the files look to be in the same format.

If we copy the data into a different spreadsheet.  The error does not happen.

0
Comment
Question by:johnnyg123
[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
  • 2
  • 2
5 Comments
 
LVL 14

Expert Comment

by:ldunscombe
ID: 33571850
Could it be that one or more of your spreadsheets are excel version 2007 ? ie .xlsx
Leigh
0
 
LVL 4

Expert Comment

by:oldmanbim
ID: 33575104
Is the file you are trying open password protected?
0
 

Author Comment

by:johnnyg123
ID: 33576328
After further questions to the user, it appears the files were worked on a home computer with excel 2007 but then saved as an excel version 2003.  Could this make a difference?

Also, the files are all password protected but only a few are having issues.  (Again, it appears the ones that were edited in 2007 and then saved as 2003)
0
 
LVL 14

Accepted Solution

by:
ldunscombe earned 2000 total points
ID: 33581485
Only Guessing here but it would appear to me that while 2007 can save a file in 2003 format it would appear that it also has different encryption settings for password protected files that apparently it does not convert to 2003 format.
Try opening one of the files with excel  2003 and saving it as a different file.
If that doesn't work try doing the same "Removing the password"
Leigh
0
 

Author Comment

by:johnnyg123
ID: 33585962
You were correct 2007 does do things a bit differently when it comes to security

Thanks!
0

Featured Post

Concerto Cloud for Software Providers & ISVs

Can Concerto Cloud Services help you focus on evolving your application offerings, while delivering the best cloud experience to your customers? From DevOps to revenue models and customer support, the answer is yes!

Learn how Concerto can help you.

Question has a verified solution.

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

This article describes how to use a set of graphical playing cards to create a Draw Poker game in Excel or VB6.
Code that checks the QuickBooks schema table for non-updateable fields and then disables those controls on a form so users don't try to update them.
Access reports are powerful and flexible. Learn how to create a query and then a grouped report using the wizard. Modify the report design after the wizard is done to make it look better. There will be another video to explain how to put the final p…
Although Jacob Bernoulli (1654-1705) has been credited as the creator of "Binomial Distribution Table", Gottfried Leibniz (1646-1716) did his dissertation on the subject in 1666; Leibniz you may recall is the co-inventor of "Calculus" and beat Isaac…

660 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