Solved

Transfer spreadsheet error

Posted on 2014-01-21
2
457 Views
Last Modified: 2014-01-21
Hi,
I have been transferring query results for the past year using the transfer spreadsheet routine. I have written a new one for a new query and all of a sudden it wont let me transfer the data saying that the destination folder is not available or already open! Not true. I even simplified the destination to my desktop on my laptop to see if that solved it but to no avail. the code is this;

DoCmd.TransferSpreadsheet acExport, acSpreadsheetTypeExcel9, "qryProdRprt", "C:\Users\StevieB\Desktop"

DoCmd.OutputTo acOutputReport, "rptShiftRptNow", acFormatPDF, "C:\Users\StevieB\Desktop"

it stops at the transfer spreadsheet line saying it cannot write to the file "C:\Users\StevieB\Desktop" it is already opened exclusively by another user, or I need permission to view and write it's data.
???

Any help as always is much appreciated.
Thanks
0
Comment
Question by:Stephen Byrom
[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 Comments
 
LVL 120

Accepted Solution

by:
Rey Obrero (Capricorn1) earned 500 total points
ID: 39797855
add the file name


DoCmd.TransferSpreadsheet acExport, acSpreadsheetTypeExcel9, "qryProdRprt", "C:\Users\StevieB\Desktop\myExcel.xls"
0
 
LVL 1

Author Closing Comment

by:Stephen Byrom
ID: 39798227
Bloody ell!
Silly me.
Thanks for your time
0

Featured Post

Revamp Your Training Process

Drastically shorten your training time with WalkMe's advanced online training solution that Guides your trainees to action.

Question has a verified solution.

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

In a multiple monitor setup, if you don't want to use AutoCenter to position your popup forms, you have a problem: where will they appear?  Sometimes you may have an additional problem: where the devil did they go?  If you last had a popup form open…
It’s been over a month into 2017, and there is already a sophisticated Gmail phishing email making it rounds. New techniques and tactics, have given hackers a way to authentically impersonate your contacts.How it Works The attack works by targeti…
Using Microsoft Access, learn some simple rules for how to construct tables in a relational database. Split up all multi-value fields into single values: Split up fields that belong to other things into separate tables: Make sure that all record…
In Microsoft Access, when working with VBA, learn some techniques for writing readable and easily maintained code.

705 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