UtterAccess.com
X   Site Message
(Message will auto close in 2 seconds)

Welcome Guest ( Log In | Register )

> Display specific excel worksheet on a form    
 
   
Wolvesbug
post Feb 5 2009, 05:09 AM
Post #1

UtterAccess Member
Posts: 30



Hi Guys,

I would like to be able to display/edit a specific excel worksheet on an access form. The location of the workbook would be the same everytime, however, the name of the worksheet would be obtained from a form control. Is this possible? If so how do I do it?

Thanks

M@
Go to the top of the page
 
+
 
Start new topic
Replies (1 - 1)
Larry Larsen
post Feb 5 2009, 05:27 AM
Post #2

UA Editor + Utterly Certified
Posts: 22,722
From: Melton Mowbray,Leicestershire (U.K)



Hi
Don't think you can actualy display it within a form but you sure can link:
CODE


Public Sub LinkSpreadsheet()

'

' Purpose:      To link a spreadsheet into Access

' Arguments:    none

' Returns:      none



    ' This links the spreadsheet into Access as though it was a table

    DoCmd.TransferSpreadsheet acLink, acSpreadsheetTypeExcel9, "tblImportTestData", "C:\TestSheet.xls"

End Sub

(IMG:style_emoticons/default/thumbup.gif)

Edited by: Larry Larsen on Thu Feb 5 5:45:15 EST 2009.
Go to the top of the page
 
+

Thank you for your support! Reply to this topicStart new topic

Jump To Forum:
 



RSS Go to Top  ·  Lo-Fi Version Time is now: 22nd May 2013 - 05:25 AM