R
Rob Nicholson
How do you determine if a program is running in the Visual Studio
IDE/debugger as opposed to standalone? We often include support files in the
same folder as the executable and would so something like:
Dim SupportFile As String
SupportFile = Application.StartupPath & "\SupportFile.txt"
But of course this fails when running in the IDE as the executable is in the
BIN folder so we need to do something like this:
Readonly Property SupportFilesPath() As String
Get
If IsIde() Then
SupportFilesPath = Application.StartupPath & "..\"
Else
SupportFilesPath = Application.StartupPath & "\"
End If
End Get
End Property
Need to implement that IsIde() function/property...
Thanks, Rob.
IDE/debugger as opposed to standalone? We often include support files in the
same folder as the executable and would so something like:
Dim SupportFile As String
SupportFile = Application.StartupPath & "\SupportFile.txt"
But of course this fails when running in the IDE as the executable is in the
BIN folder so we need to do something like this:
Readonly Property SupportFilesPath() As String
Get
If IsIde() Then
SupportFilesPath = Application.StartupPath & "..\"
Else
SupportFilesPath = Application.StartupPath & "\"
End If
End Get
End Property
Need to implement that IsIde() function/property...
Thanks, Rob.