You should have RSlinx set to run as a Service, this will enable it to run in the Systray. Sorry but I do not know of any command line switches will will set this to run minimized.
To check to see if RSlinx is running you can use the following code in VB.
Place this in the General Declartions of a .bas file
Declare Function GetWindow Lib "user32" (ByVal hwnd As Long, ByVal wCmd As Long) As Long
Declare Function EnumWindows Lib "user32" (ByVal lpEnumFunc As Long, ByVal lParam As Long) As Boolean
Declare Function GetWindowText Lib "user32" Alias "GetWindowTextA" (ByVal hwnd As Long, ByVal lpString As String, ByVal cch As Long) As Long
Declare Function GetWindowTextLength Lib "user32" Alias "GetWindowTextLengthA" (ByVal hwnd As Long) As Long
Declare Function GetClassName Lib "user32" Alias "GetClassNameA" (ByVal hwnd As Long, ByVal lpClassName As String, ByVal nMaxCount As Long) As Long
:::::: Then add these Functions to the .bas file ::::::::
Public Function EnumWindowsProcCallBack(ByVal hwnd As Long, ByVal lParam As Long) As Boolean
Dim RetVal As Long
Dim WinClassBuf As String * 255
Dim WinTitleBuf As String * 255
Dim WinClass As String
Dim WinTitle As String
On Error Resume Next
RetVal = GetClassName(hwnd, WinClassBuf, 255)
WinClass = StripNulls(WinClassBuf) ' remove extra Nulls & spaces
RetVal = GetWindowText(hwnd, WinTitleBuf, 255)
WinTitle = StripNulls(WinTitleBuf)
' see the Windows Class and Title for each top level Window
'Debug.Print WinClass, "::::", WinTitle
'the Following line will check for a specific program
If InStr(WinTitle, sProgram) > 0 Then
bProgramFound = True
'Put code here for info if found
End If
EnumWindowsProcCallBack = True
End Function
Public Function EnumTopLevelWindows()
On Error Resume Next
EnumTopLevelWindows = EnumWindows(AddressOf EnumWindowsProcCallBack, 0)
End Function
Public Function StripNulls(OriginalStr As String) As String
On Error Resume Next
' This removes the extra Nulls so String comparisons will work
If (InStr(OriginalStr, Chr(0)) > 0) Then
OriginalStr = Left(OriginalStr, InStr(OriginalStr, Chr(0)) - 1)
End If
StripNulls = OriginalStr
End Function
::::: in you splash form you can then do the following ::::
bProgramFound = False
sProgram = "RSLinx"
Call EnumTopLevelWindows
If bProgramFound = False Then
Call RSlinx
End If