Results 1 to 3 of 3
  1. #1
    itm is offline Advanced Beginner
    Windows XP Access 2003
    Join Date
    Jun 2011
    Posts
    69

    Question trying to export table data tpo Excel

    Hi,
    This is really crazy but I have been trying to export, in MS Access 2007, data from a table to Excel. and it will not go for anything.
    it does not error it just does not go. Now I have used the following in other versions Access for years but not ion 2007, so I do not know.
    I have tryed these two techniqes:

    Where InpdfNotInMastFile holds the path where I want it to go.

    Code:
    DoCmd.TransferSpreadsheet acExport, acSpreadsheetTypeExcel7, "tblIn_Pdf_not_in_Master", InpdfNotInMastFile, True, "A1:D150"
    And I tryed this:

    Code:
      DoCmd.OutputTo acOutputTable, "tblIn_Pdf_not_in_Master", acFormatXLS, InpdfNotInMastFile
    Any Ideas would be a reeall help.


    Thank you
    Last edited by itm; 01-30-2012 at 10:45 AM. Reason: "solved."

  2. #2
    alansidman's Avatar
    alansidman is offline Indifferent
    Windows 7 32bit Access 2007
    Join Date
    Apr 2010
    Location
    Steamboat Springs
    Posts
    2,536
    What version of Excel are you using? If you are using Excel 2007, then you need to change this in your line of code

    Code:
     acSpreadsheetTypeExcel7,
    
    
    to 
    10,
    Here is background

    http://msdn.microsoft.com/en-us/libr...ffice.12).aspx

  3. #3
    itm is offline Advanced Beginner
    Windows XP Access 2003
    Join Date
    Jun 2011
    Posts
    69
    Thanks it now works Thank you

Please reply to this thread with any new information or opinions.

Similar Threads

  1. Export Access data to Excel
    By kaysersoze in forum Access
    Replies: 0
    Last Post: 01-21-2012, 12:25 AM
  2. Error when trying to export from table to Excel
    By tobinjames in forum Import/Export Data
    Replies: 3
    Last Post: 12-15-2011, 02:55 PM
  3. Export table to excel using excel template
    By allenjasonbrown@gmail.com in forum Programming
    Replies: 1
    Last Post: 06-27-2011, 02:10 AM
  4. Capture Form Data to Export to Excel
    By ajones92 in forum Forms
    Replies: 8
    Last Post: 06-16-2011, 03:35 PM
  5. Export Excel data to access on a button click
    By Grooz13 in forum Import/Export Data
    Replies: 0
    Last Post: 03-15-2011, 10:02 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Other Forums: Microsoft Office Forums