Solved Export single record from table to Excel (1 Viewer)

Eureka99

New member
Local time
Today, 08:58
Joined
Jun 29, 2020
Messages
26
I have a customer that wants to export a single record to excel when a record is complete.

This is to do with Machine maintenance and keeping a record of the logged faults with any documents for auditing purposes.

I've tried the below code but it still exports the whole table:

Code:
Folder = "\\smc2k3f01.uklan.intranet\MANUFAC$\Machine Management\4. Production machine maintenance and service records\4.Machine Maintenance Info and  History\" & Me.Machine_ID & "\" & Me.ID & "\Fault" & Me.ID & ".xlsx"


DoCmd.TransferSpreadsheet acExport, acSpreadsheetTypeExcel12, "tbl_fault", Folder, True, "ID=" & Me.ID
 

Gasman

Enthusiastic Amateur
Local time
Today, 08:58
Joined
Sep 21, 2011
Messages
14,232
Use the form ID for the criteria of a query and export that.?
 

Eureka99

New member
Local time
Today, 08:58
Joined
Jun 29, 2020
Messages
26
COol, didnt think of that, still shaking off the new years cobwebs! thanks!
 

Users who are viewing this thread

Top Bottom