|
@@ -42,10 +42,10 @@ End Type
|
|
|
|
|
|
|
|
|
|
|
|
|
'Exports print vars for reports
|
|
'Exports print vars for reports
|
|
|
-Public Sub ExportPrintVars(ByVal obj_name As String, ByVal filepath As String)
|
|
|
|
|
|
|
+Public Sub ExportPrintVars(ByVal obj_name As String, ByVal filePath As String)
|
|
|
DoEvents
|
|
DoEvents
|
|
|
- Dim FSO As Object
|
|
|
|
|
- Set FSO = CreateObject("Scripting.FileSystemObject")
|
|
|
|
|
|
|
+ Dim fso As Object
|
|
|
|
|
+ Set fso = CreateObject("Scripting.FileSystemObject")
|
|
|
|
|
|
|
|
Dim DevModeString As str_DEVMODE
|
|
Dim DevModeString As str_DEVMODE
|
|
|
Dim DevModeExtra As String
|
|
Dim DevModeExtra As String
|
|
@@ -74,7 +74,7 @@ Public Sub ExportPrintVars(ByVal obj_name As String, ByVal filepath As String)
|
|
|
End If
|
|
End If
|
|
|
|
|
|
|
|
Dim OutFile As Object
|
|
Dim OutFile As Object
|
|
|
- Set OutFile = FSO.CreateTextFile(filepath, overwrite:=True, unicode:=False)
|
|
|
|
|
|
|
+ Set OutFile = fso.CreateTextFile(filePath, overwrite:=True, unicode:=False)
|
|
|
|
|
|
|
|
'print out print var values
|
|
'print out print var values
|
|
|
OutFile.WriteLine DM.intOrientation
|
|
OutFile.WriteLine DM.intOrientation
|
|
@@ -88,13 +88,13 @@ Public Sub ExportPrintVars(ByVal obj_name As String, ByVal filepath As String)
|
|
|
|
|
|
|
|
DoCmd.Close acReport, obj_name, acSaveYes
|
|
DoCmd.Close acReport, obj_name, acSaveYes
|
|
|
|
|
|
|
|
- logger "ExportPrintVars", "DEBUG", "PrintVars of report " & obj_name & " exported to " & filepath
|
|
|
|
|
|
|
+ logger "ExportPrintVars", "DEBUG", "PrintVars of report " & obj_name & " exported to " & filePath
|
|
|
End Sub
|
|
End Sub
|
|
|
|
|
|
|
|
-Public Sub ImportPrintVars(ByVal obj_name As String, ByVal filepath As String)
|
|
|
|
|
|
|
+Public Sub ImportPrintVars(ByVal obj_name As String, ByVal filePath As String)
|
|
|
On err GoTo err
|
|
On err GoTo err
|
|
|
- Dim FSO As Object
|
|
|
|
|
- Set FSO = CreateObject("Scripting.FileSystemObject")
|
|
|
|
|
|
|
+ Dim fso As Object
|
|
|
|
|
+ Set fso = CreateObject("Scripting.FileSystemObject")
|
|
|
|
|
|
|
|
Dim DevModeString As str_DEVMODE
|
|
Dim DevModeString As str_DEVMODE
|
|
|
Dim DevModeExtra As String
|
|
Dim DevModeExtra As String
|
|
@@ -121,7 +121,7 @@ Public Sub ImportPrintVars(ByVal obj_name As String, ByVal filepath As String)
|
|
|
End If
|
|
End If
|
|
|
|
|
|
|
|
Dim InFile As Object
|
|
Dim InFile As Object
|
|
|
- Set InFile = FSO.OpenTextFile(filepath, iomode:=ForReading, Create:=False, Format:=TristateFalse)
|
|
|
|
|
|
|
+ Set InFile = fso.OpenTextFile(filePath, iomode:=ForReading, Create:=False, Format:=TristateFalse)
|
|
|
|
|
|
|
|
'print out print var values
|
|
'print out print var values
|
|
|
DM.intOrientation = InFile.readline
|
|
DM.intOrientation = InFile.readline
|
|
@@ -140,7 +140,7 @@ Public Sub ImportPrintVars(ByVal obj_name As String, ByVal filepath As String)
|
|
|
|
|
|
|
|
DoCmd.Close acReport, obj_name, acSaveYes
|
|
DoCmd.Close acReport, obj_name, acSaveYes
|
|
|
|
|
|
|
|
- logger "ImportPrintVars", "DEBUG", "PrintVars of report " & obj_name & " imported from " & filepath
|
|
|
|
|
|
|
+ logger "ImportPrintVars", "DEBUG", "PrintVars of report " & obj_name & " imported from " & filePath
|
|
|
|
|
|
|
|
Exit Sub
|
|
Exit Sub
|
|
|
err:
|
|
err:
|