Database Reference
In-Depth Information
sFormattedFileName = sBaseFileName & _
Strings.Format(Date.Now, sDateStampFormat) & "." &
sExtension
' 4g: assign external varables...
Dts.Variables("User::FormattedFileName").Value
= sFormattedFileName
Dts.Variables("SourceFileDirectory").Value
= sSourceFileDirectory
Dts.Variables("WorkingCopyFileName").Value
= sWorkingCopyFileName
' 4h: check for valid file...
If File.Exists(sSourceFilePath) Then
' 4i: set OkToProceed flag...
Dts.Variables("OkToProceed").Value = True
Else
' 4j: if raising an exception on file not
found...
If bExceptionOnFileNotFound Then
' 4k: fire an error...
Dts.Events.FireError(1001,
sSubComponent, "cannot locate file " & _
sSourceFilePath, "", 0)
End If
' 4l: set OkToProceed flag...
Dts.Variables("OkToProceed").Value = False
sMsg = "file " & sSourceFilePath & " not
found."
If bDebug Then MsgBox(sMsg,
MsgBoxStyle.OkOnly, sSubComponent)
' 4m: log file not found, exception or
not...
Dts.Events.FireInformation(2001,
sSubComponent, sMsg, "", 0, True)
End If
Catch ex As Exception
' 4n: log error message...
Search WWH ::




Custom Search