Let only work with small pieces of code that are manageable and demonstrate your issue.

Is the code segment that is causing you a problem?
code:
    Case InGroup ("Mgt", "Mgr", 1) = 1 
Use o: "\\$FileServer\mgt$"


if @error
? Error connecting O: drive
sleep 30
endif

;****************************************************************************
;**** Departments Data Share Folder (R:)
;****
if exist("r:")
use r: /del

if @error
? Error disconnecting R: drive
sleep 30
endif
endif

use r: "\\$FileServer\Work"

if @error
? Error connecting R: drive
sleep 30
endif

Case InGroup ("Mgt") = 1
Use o: "\\$FileServer\mgt$"


if @error
? Error connecting O: drive
sleep 30
endif

Let's change the structure to something that we can test.

Use this as test code and execute it in a DOS window. What is the result?


if InGroup ("Mgt", "Mgr", 1)
? "Success : InGroup (Mgt, Mgr, 1)"
else
? "Failed : InGroup (Mgt, Mgr, 1)"
endif

if InGroup ("Mgt")
? "Success : InGroup (Mgt)"
else
? "Failed : InGroup (Mgt)"
endif


Are Mgt and Mgr global or local groups?

[ 29. April 2003, 19:48: Message edited by: Howard Bullock ]
_________________________
Home page: http://www.kixhelp.com/hb/