T
TaylorBo
Guest
I'm trying to figure out what the code is in order for me to do the following...
I have the code below which exports an access file to an excel file. Currently it exports the file to a set folder. What code will enable a prompt so that the user can select where to export and save the file to? It's a "save as" type function I'd think, but I'm not super familar with VBA.
Thanks.
I have the code below which exports an access file to an excel file. Currently it exports the file to a set folder. What code will enable a prompt so that the user can select where to export and save the file to? It's a "save as" type function I'd think, but I'm not super familar with VBA.
Thanks.
Code:
Private Sub Command1_Click()
'***EXCEL EXPORT
On Error GoTo COMMAND1_Click_ERR
Call Msg_Box(36)
If G_MSGKBN = 2 Then
Exit Sub
End If
Dim Q_T_SHADAI_EXCEL As QueryDef
Dim F_NUM As Double
'FILECD GA EXCEL NI MAJITTARA ERROR
F_NUM = DCount("FILECD", "V_PLAN", "FILECD <> '" & G_FILECD & "'")
If F_NUM <> 0 Then
Call Msg_Box(7)
Exit Sub
End If
'DATA DELETE
Kill "C:\GNENKEI\VEHICLE_PLAN.XLS"
'FONT CHANGE
Call ole_Exl_font("Q_T_SHADAI_SUB", "C:\GNENKEI\VEHICLE_PLAN.XLS")
'EXPORT
Shell (EXCEL_PG & "C:\GNENKEI\VEHICLE_PLAN.XLS")
Exit Sub