B4J Question jshell net use command

Shivito1

Active Member
Licensed User
I have tried many different ways to accomplish this however to no avail. here is my code.
B4X:
Dim runit As Shell
Private switches As List
switches.Initialize
switches.Add("/user:johns")
switches.Add("password")
runit.Initialize("net use J:",$"\\example\windows\share"$,switches)
runit.RunSynchronous(-1)
 

Shivito1

Active Member
Licensed User
We cannot help you if you don't provide any information...
Right. I want to map a drive in windows. My thought is that I can use command prompt command "net use". I think this can be achieved with jshell, however I'm not sure I properly understand how to use jshell to map a drive.
 

Shivito1

Active Member
Licensed User
XD I was close haha
I just needed to see the error from the executed command. apparently I had a connection as the same user already established and it will not allow two connections by the same user.
 
Top