N
niksto
In a form I have a button called myexport
and the code You see below.
I want to export this table (myaccesstable) giving it a name that identifies
it
including in my filename one singel
value from another table, "theothertable" that only contains one singel
value.
theothertable
myvalue 3
(this tableonly contains one value and one row)
Private Sub myexport _Click()
Dim str As String
Dim mydate As Date
mydate = Date
str = "mycreatedfile.xls"
DoCmd.OutputTo acOutputTable, "myaccesstable", acFormatXLS, "D:\" & mydate &
str, True
'I want to include myvalue, that here is 3 like this;
'DoCmd.OutputTo acOutputTable, "myaccesstable", acFormatXLS, "D:\" myvalue &
mydate & str, True
End Sub
and the code You see below.
I want to export this table (myaccesstable) giving it a name that identifies
it
including in my filename one singel
value from another table, "theothertable" that only contains one singel
value.
theothertable
myvalue 3
(this tableonly contains one value and one row)
Private Sub myexport _Click()
Dim str As String
Dim mydate As Date
mydate = Date
str = "mycreatedfile.xls"
DoCmd.OutputTo acOutputTable, "myaccesstable", acFormatXLS, "D:\" & mydate &
str, True
'I want to include myvalue, that here is 3 like this;
'DoCmd.OutputTo acOutputTable, "myaccesstable", acFormatXLS, "D:\" myvalue &
mydate & str, True
End Sub