Sign in to follow this  
Followers 0
ACalcutt

Running network programs that need auth

24 posts in this topic

I am trying t make my program run other programs from a network drive. this works fine if the server does not require authentication. but i work in a school...and that is not allowed.

i dont know if it is because the computer is not on the domain and i am trying to log on as an domain user

I have the top of my script set up like this

---------------------------------------------------------------------

Dim $netuser = IniRead($settings, "Program_Use_Only", "NetAdmin", "")

Dim $netpass = _StringEncrypt(0, IniRead($settings, "Program_Use_Only", "NetPass", ""), "Prepsys", 2)

Dim $netdom = IniRead($settings, "Program_Use_Only", "NetDom", "")

If IniRead($settings, "Program_Use_Only", "NetLogon", "0") = 1 Then RunAsSet ($netuser, $netdom, $netpass, 2)

---------------------------------------------------------------------

i get this error

RunWait($cleansns_exe)

error: unable to execute the external program

if i got to the network location and put in my credentials....the script runs fine because it does not need to authenticate


Andrew Calcutt

Http://www.Vistumbler.net

Http://www.TechIdiots.net

Its not an error, its a undocumented feature

Share this post


Link to post
Share on other sites



When running a program from a network share you need to specify a working directory.

Try this:

RunWait($cleansns_exe, @TempDir)

Share this post


Link to post
Share on other sites

When running a program from a network share you need to specify a working directory.

Try this:

RunWait($cleansns_exe, @TempDir)

will that mess things up when $cleansns_exe isn't on a network drive?

and does that automatically delete?


Andrew Calcutt

Http://www.Vistumbler.net

Http://www.TechIdiots.net

Its not an error, its a undocumented feature

Share this post


Link to post
Share on other sites

will that mess things up when $cleansns_exe isn't on a network drive?

No it won't mess anything up if it isn't.

and does that automatically delete?

I've never checked to see if it does or not.

Share this post


Link to post
Share on other sites

what does the tempdrive actually do....i am runing a scipt that uses other files outside of the exe (its used to autoinstall programs)


Andrew Calcutt

Http://www.Vistumbler.net

Http://www.TechIdiots.net

Its not an error, its a undocumented feature

Share this post


Link to post
Share on other sites

what does the tempdrive actually do....i am runing a scipt that uses other files outside of the exe (its used to autoinstall programs)

@TempDir = path to the temporary files folder

This just gives the script a place to store the files while it is running them. It won't do anything to your script other than make it work.

Share this post


Link to post
Share on other sites

@TempDir = path to the temporary files folder

This just gives the script a place to store the files while it is running them. It won't do anything to your script other than make it work.

thanks for the help....hopefully it work when i am at work on the network...it at least works like it did before


Andrew Calcutt

Http://www.Vistumbler.net

Http://www.TechIdiots.net

Its not an error, its a undocumented feature

Share this post


Link to post
Share on other sites

It didn't work, i get the same error basically

--------------------------

RunWait($cleansns_exe, @TempDir)

error: unable to execute the external program


Andrew Calcutt

Http://www.Vistumbler.net

Http://www.TechIdiots.net

Its not an error, its a undocumented feature

Share this post


Link to post
Share on other sites

It didn't work, i get the same error basically

--------------------------

RunWait($cleansns_exe, @TempDir)

error: unable to execute the external program

I use PSEXEC from Sysinternals. This lets me run a program on a remote machine using credentials that are options on the command line. It can copy the program to the remote system if it's not already there, run it and then you can remove the remains, if any.

...by the way, it's pronounced: "JIF"... Bob Berry --- inventor of the GIF format

Share this post


Link to post
Share on other sites

I don't see any script code where the credentials are being used, are you using RunAsSet? RunAsSet starts child processes in a new session that doesn't inherit or initially have any network connectivity.

Thread that discusses this here, discussion is re: a NetWare environment, but the concepts and methods are the same for Windows...


Yes yes yes, there it was. Youth must go, ah yes. But youth is only being in a way like it might be an animal. No, it is not just being an animal so much as being like one of these malenky toys you viddy being sold in the streets, like little chellovecks made out of tin and with a spring inside and then a winding handle on the outside and you wind it up grrr grrr grrr and off it itties, like walking, O my brothers. But it itties in a straight line and bangs straight into things bang bang and it cannot help what it is doing. Being young is like being like one of these malenky machines.

Share this post


Link to post
Share on other sites

#11 ·  Posted (edited)

i am running exes on from remote share (the exes are autoit autoinstalls i made that require other the programs install files to be used)

ex. ---->>

my programs are in

\\macross\Prepsys ...to view that folder i must enter a valid username and password

in \\macross\PrepSys i have

\\macross\PrepSys\Office, that contains my autoinstall script(compiled exe) and the office install files.

--------->>

If i manually log into \\macross\Prepsys then run my program, it works fine (using windows run, i get asked to enter a password to view contents of \\macross\PrepSys)

but if i dont log in first...i get the above error

If a network drive is being used a ini key(NetLogon) gets set to 1.(another program i made sets the settings)

in the script that performs the actions, i use RunAsSet

;Set privlages if needed
If IniRead($settings, "Program_Use_Only", "NetLogon", "0") = 1 Then RunAsSet($netuser, $netdom, $netpass, 2)

I don't see any script code where the credentials are being used, are you using RunAsSet? RunAsSet starts child processes in a new session that doesn't inherit or initially have any network connectivity.

Thread that discusses this here, discussion is re: a NetWare environment, but the concepts and methods are the same for Windows...

;-----------------------------------------------------------------------------
;-----------------------------------------------------------------------------
; AutoIt Version: 3.1.1.98(beta)
; Author:Andrew Calcutt     Date:08/11/2005
; Script Function: Auto-Sysprep Utility
;-----------------------------------------------------------------------------
#include <PrepSysFunc.au3>;Include PrepSys Functions
#include <GuiConstants.au3>
#include <string.au3>
;-----------------------------------------------------------------------------
Dim $settings = @HomeDrive & "\settings.ini"
If FileExists($settings) = 0 Then
    FileCopy(StringTrimRight(@ScriptDir, 8) & "\settings.ini", $settings, 0)
    FileSetAttrib($settings, "-R")
EndIf
If IniRead($settings, "Script_Settings", "Working_Dir", "") = "" Then IniWrite($settings, "Script_Settings", "Working_Dir", StringTrimRight(@ScriptDir, 8))
;-----------------------------------------------------------------------------
;-----------------------------------------------------------------------------
Dim $shutdown = "RUN"
Dim $workingdir = IniRead($settings, "Script_Settings", "Working_Dir", "")
Dim $progressref = IniRead($settings, "Program_Use_Only", "_Progress_Ref", "")
Dim $progressref2 = 0
Dim $run_todo = IniRead($settings, "Script_Settings", "Delete_Start_User", "0") + IniRead($settings, "Script_Settings", "Install_McAfee", "0") + IniRead($settings, "Script_Settings", "Install_Sophos", "0") + IniRead($settings, "Script_Settings", "Install_VPN", "0") + IniRead($settings, "Script_Settings", "Install_Office", "0") + IniRead($settings, "Script_Settings", "Set_Visual_Settings", "0") + IniRead($settings, "Script_Settings", "Copy_Profile", "0") + IniRead($settings, "Script_Settings", "Wait_Updates", "0") + IniRead($settings, "Script_Settings", "Clean_SMS", "0") + IniRead($settings, "Script_Settings", "Remove_McAfee_GUID", "0") + IniRead($settings, "Script_Settings", "Defrag", "0")
Dim $logonuser1 = IniRead($settings, "Script_Settings", "Admin_Username", "")
Dim $logonpass1 = _StringEncrypt(0, IniRead($settings, "Script_Settings", "Admin_Password", ""), "Prepsys", 2)
Dim $logonuser2 = IniRead($settings, "Script_Settings", "Sysprep_Username", "")
Dim $logonpass2 = _StringEncrypt(0, IniRead($settings, "Script_Settings", "Sysprep_Password", ""), "Prepsys", 2)
Dim $logonuser = $logonuser1
Dim $logonpass = $logonpass1
Dim $scriptdir = @ScriptDir & "\" & @ScriptName

Dim $mcafee_exe = IniRead($settings, "Program_Use_Only", "mcafee_exe", $workingdir & "\McAfee\AutoInstall_McAfee.exe")
Dim $mcafee_patch_exe = IniRead($settings, "Program_Use_Only", "mcafee_patch_exe", $workingdir & "\McAfee\Patch\AutoInstall_McAfee_Patch.exe")
Dim $sophos_exe = IniRead($settings, "Program_Use_Only", "sophos_exe", $workingdir & "\Sophos\AutoInstall_Sophos.exe")
Dim $vpn_exe = IniRead($settings, "Program_Use_Only", "vpn_exe", $workingdir & "\VPN\AutoInstall_VPN.exe")
Dim $office_exe = IniRead($settings, "Program_Use_Only", "office_exe", $workingdir & "\OFFICE\AutoInstall_Office.exe")
Dim $datatel_exe = IniRead($settings, "Program_Use_Only", "datatel_exe", $workingdir & "\DATATEL\AutoInstall_Datatel.exe")
Dim $cleansms_exe = IniRead($settings, "Program_Use_Only", "cleansms_exe", $workingdir & "\CleanSMS\AutoRun_cleansms.exe")

Dim $netuser = IniRead($settings, "Program_Use_Only", "NetAdmin", "")
Dim $netpass = _StringEncrypt(0, IniRead($settings, "Program_Use_Only", "NetPass", ""), "Prepsys", 2)
Dim $netdom = IniRead($settings, "Program_Use_Only", "NetDom", "")

;-----------------------------------------------------------------------------
If StringLen($workingdir) <> 3 Then $workingdir = $workingdir & "\"
;-----------------------------------------------------------------------------
;Auto Logon
_Logon ("REMOVE")
;-----------------------------------------------------------------------------
;Set privlages if needed
If IniRead($settings, "Program_Use_Only", "NetLogon", "0") = 1 Then RunAsSet($netuser, $netdom, $netpass, 2)
;-----------------------------------------------------------------------------
GUICreate("PrepSys Progress", 200, 50, (@DesktopWidth - 200) , (0))

$action_progress = GUICtrlCreateProgress(10, 2, 180, 12)
$current_action = GUICtrlCreateLabel("Current Action", 13, 28, 315, 23)

GUISetState()
While 1
    $msg = GUIGetMsg()
    Select
        Case $msg = $GUI_EVENT_CLOSE
            ExitLoop
    EndSelect
    
;*** COPY USERNAME OF INITIAL XP USER(IF NOT DEFAULT ADMIN ACCOUNT) ***
    If IniRead($settings, "Script_Settings", "Delete_Start_User", "0") = 1 And IniRead($settings, "Program_Use_Only", "Deleted_Start_User", "0") = 0 Then
        If @UserName <> $logonuser1 Then
            GUICtrlSetData($current_action, "Deleting Initial User")
            IniWrite($settings, "Script_Settings", "Delete_User", @UserName)
            IniWrite($settings, "Program_Use_Only", "Delete_Start_User_Step1", "1")
            _Shutdown ("LOGOFF", "ADD", $logonuser1, $logonpass1, $scriptdir)
        Else
            IniWrite($settings, "Program_Use_Only", "Deleted_Start_User", "1")
        EndIf
    EndIf
    
    
;*** DELETE INITIAL USER ***
    If IniRead($settings, "Program_Use_Only", "Delete_Start_User_Step1", "0") = 1 And IniRead($settings, "Program_Use_Only", "Deleted_Start_User", "0") = 0 Then
        GUICtrlSetData($current_action, "Deleting Initial User")
        _Profile ("REMOVE", IniRead($settings, "Script_Settings", "Delete_User", ""))
        _User ("REMOVE", IniRead($settings, "Script_Settings", "Delete_User", ""), "", "")
        IniWrite($settings, "Program_Use_Only", "Deleted_Start_User", "1")
        _Progress_Ref ("ADD")
    EndIf
    
    _Progress_Ref ("SHOW")
    
;*** INSTALL MCAFEE ***
    If IniRead($settings, "Script_Settings", "Install_McAfee", "0") = 1 And IniRead($settings, "Program_Use_Only", "Installed_McAfee", "0") = 0 Then
        GUICtrlSetData($current_action, "Installing McAfee")
        RunWait($mcafee_exe, @TempDir@TempDir);Install McAfee
        RunWait($mcafee_patch_exe, @TempDir);Install McAfee Patch
        IniWrite($settings, "Program_Use_Only", "Installed_McAfee", "1")
        _Progress_Ref ("ADD")
    EndIf
    
    _Progress_Ref ("SHOW")
    
;Install Sophos Remote Update
    If IniRead($settings, "Script_Settings", "Install_Sophos", "0") = 1 And IniRead($settings, "Program_Use_Only", "Installed_Sophos", "0") = 0 Then
        GUICtrlSetData($current_action, "Installing Sophos")
        RunWait($sophos_exe, @TempDir);Install Sophos
        IniWrite($settings, "Program_Use_Only", "Installed_Sophos", "1")
        _Progress_Ref ("ADD")
    EndIf
    
    _Progress_Ref ("SHOW")
    
;*** INSTALL VPN SOFTWARE ***
    If IniRead($settings, "Script_Settings", "Install_VPN", "0") = 1 And IniRead($settings, "Program_Use_Only", "Installed_VPN", "0") = 0 Then
        GUICtrlSetData($current_action, "Installing VPN")
        RunWait($vpn_exe, @TempDir);Install VPN
        IniWrite($settings, "Program_Use_Only", "Installed_VPN", "1")
        _Progress_Ref ("ADD")
        $shutdown = "REBOOT"
    EndIf
    
    _Progress_Ref ("SHOW")
    
;*** INSTALL OFFICE ***
    If IniRead($settings, "Script_Settings", "Install_Office", "0") = 1 And IniRead($settings, "Program_Use_Only", "Installed_Office", "0") = 0 Then
        GUICtrlSetData($current_action, "Installing Office")
        RunWait($office_exe, @TempDir);Install Office
        IniWrite($settings, "Program_Use_Only", "Installed_Office", "1")
        If IniRead($settings, "OFFICE", "Add_Office_Toolbar", "0") = 1 And IniRead($settings, "Program_Use_Only", "Added_Office_Toolbar", "0") = 0 Then
            _TaskToolbar ($toolbardir)
            IniWrite($settings, "Program_Use_Only", "Added_Office_Toolbar", "1")
        EndIf
        _Progress_Ref ("ADD")
        $shutdown = "REBOOT"
    EndIf
    
    _Progress_Ref ("SHOW")
    
;*** INSTALL DATATEL ***
    If IniRead($settings, "Script_Settings", "Install_Datatel", "0") = 1 And IniRead($settings, "Program_Use_Only", "Installed_Datatel", "0") = 0 Then
        GUICtrlSetData($current_action, "Installing Datatel")
        RunWait($datatel_exe, @TempDir);Install Datatel
        IniWrite($settings, "Program_Use_Only", "Installed_Datatel", "1")
        _Progress_Ref ("ADD")
    EndIf
    
    _Progress_Ref ("SHOW")
    
;
    If $shutdown <> "" Then _Shutdown ($shutdown, "ADD", $logonuser1, $logonpass1, $scriptdir)
    
;Set Start Menu
    If IniRead($settings, "Script_Settings", "Set_Start_Menu", "0") = 1 And IniRead($settings, "Program_Use_Only", "Set_Start_Menu", "0") = 0 Then
        GUICtrlSetData($current_action, "Setting Start Menu/TaskBar Settings")
        $HKUS1521 = "HKEY_USERS\" & _FindReg ("HKEY_USERS", "S-1-5-21")
        _StartMenu ($settings, $HKUS1521)
        _Taskbar ($settings, $HKUS1521)
        IniWrite($settings, "Program_Use_Only", "Set_Start_Menu", "1")
        _Progress_Ref ("ADD")
        $shutdown = "LOGOFF"
    EndIf
    
    _Progress_Ref ("SHOW")
    
;*** SET VISUAL SETTINGS ***
    If IniRead($settings, "Script_Settings", "Set_Visual_Settings", "0") = 1 And IniRead($settings, "Program_Use_Only", "Set_Visual_Settings", "0") = 0 Then
        GUICtrlSetData($current_action, "Setting Visual Settings")
        _VisualSettings ()
        GUICtrlSetData($current_action, "Setting Desktop Settings")
        _Desktop ()
        IniWrite($settings, "Program_Use_Only", "Set_Visual_Settings", "1")
        _Progress_Ref ("ADD")
    EndIf
    
    _Progress_Ref ("SHOW")
    
;*** Set Folder Options ***
    If IniRead($settings, "Script_Settings", "Set_Folder_Options", "0") = 1 And IniRead($settings, "Program_Use_Only", "Set_Folder_Options", "0") = 0 Then
        GUICtrlSetData($current_action, "Setting Folder Options")
        $HKUS1521 = "HKEY_USERS\" & _FindReg ("HKEY_USERS", "S-1-5-21")
        _FolderOptions ($settings, $HKUS1521)
        IniWrite($settings, "Program_Use_Only", "Set_Folder_Options", "1")
        _Progress_Ref ("ADD")
        $shutdown = "LOGOFF"
    EndIf
    
    _Progress_Ref ("SHOW")
    
    If $shutdown <> "" Then _Shutdown ($shutdown, "ADD", $logonuser1, $logonpass1, $scriptdir)
    
;*** MAKE SYSPREP USER - RESTART FOR COPY PROFILE ***
    If IniRead($settings, "Script_Settings", "Copy_Profile", "0") = 1 And IniRead($settings, "Program_Use_Only", "Copy_Profile_Step1", "0") = 0 Then
        GUICtrlSetData($current_action, "Creating Copy Profile User")
        _User ("ADD", $logonuser2, $logonpass2, "Administrators")
        IniWrite($settings, "Program_Use_Only", "Copy_Profile_Step1", "1")
        _Shutdown ("LOGOFF", "ADD", $logonuser2, $logonpass2, $scriptdir)
    EndIf
    
;*** COPY PROFILE ***
    If IniRead($settings, "Script_Settings", "Copy_Profile", "0") = 1 And IniRead($settings, "Program_Use_Only", "Copy_Profile_Step2", "0") = 0 Then
        GUICtrlSetData($current_action, "Copying Profile")
        _Profile ("COPY", $logonuser1)
        IniWrite($settings, "Program_Use_Only", "Copy_Profile_Step2", "1")
        _Shutdown ("LOGOFF", "ADD", $logonuser1, $logonpass1, $scriptdir)
    EndIf
    
;*** Remove sysprep user/profile ***
    If IniRead($settings, "Script_Settings", "Copy_Profile", "0") = 1 And IniRead($settings, "Program_Use_Only", "Copy_Profile_Step3", "0") = 0 Then
        GUICtrlSetData($current_action, "Removing Copy Profile User")
        _Profile ("REMOVE", $logonuser2)
        _User ("REMOVE", $logonuser2, "", "")
        FileDelete(@UserProfileDir & "\" & $logonuser2)
        IniWrite($settings, "Program_Use_Only", "Copy_Profile_Step3", "1")
        _Progress_Ref ("ADD")
    EndIf
    
    _Progress_Ref ("SHOW")
    
;*** WAIT FOR UPDATES/INSTALLS ***
    If IniRead($settings, "Script_Settings", "Wait_Updates", "0") = 1 And IniRead($settings, "Program_Use_Only", "Waited_For_Updates", "0") = 0 Then
        GUICtrlSetData($current_action, "Waiting for Updates")
        _Logon ("ADD", $logonuser1, $logonpass1, $scriptdir)
        MsgBox(0, "Waiting", "Install updates or extra software - HIT OK WHEN DONE - This window will start on next boot if you need to restart")
        _Logon ("REMOVE")
        IniWrite($settings, "Program_Use_Only", "Waited_For_Updates", "1")
        _Progress_Ref ("ADD")
    EndIf
    
    _Progress_Ref ("SHOW")
    
;*** CLEAN SMS ***
    If IniRead($settings, "Script_Settings", "Clean_SMS", "0") = 1 And IniRead($settings, "Program_Use_Only", "Cleaned_SMS", "0") = 0 Then
        GUICtrlSetData($current_action, "Cleaning SMS")
        RunWait($cleansms_exe, @TempDir);Run CleanSMS
        IniWrite($settings, "Program_Use_Only", "Cleaned_SMS", "1")
        _Progress_Ref ("ADD")
    EndIf
    
    _Progress_Ref ("SHOW")
    
;*** REMOVE McAfee GUID ***
    If IniRead($settings, "Script_Settings", "Remove_McAfee_GUID", "0") = 1 And IniRead($settings, "Program_Use_Only", "Removed_McAfee_GUID", "0") = 0 Then
        GUICtrlSetData($current_action, "Removing McAfee GUID")
        RunWait("net stop McAfeeFramework")
        RegDelete("HKEY_LOCAL_MACHINE\SOFTWARE\Network Associates\ePolicy Orchestrator\Agent", "AgentGUID")
        IniWrite($settings, "Program_Use_Only", "Removed_McAfee_GUID", "1")
        _Progress_Ref ("ADD")
    EndIf
    
    _Progress_Ref ("SHOW")
    
;*** DEFRAGMENT ***
    If IniRead($settings, "Script_Settings", "Defrag", "0") = 1 And IniRead($settings, "Program_Use_Only", "Defraged", "0") = 0 Then
        GUICtrlSetData($current_action, "Defraging Local Disk")
        _Defrag ()
        IniWrite($settings, "Program_Use_Only", "Defraged", "1")
        _Progress_Ref ("ADD")
    EndIf
    
    _Progress_Ref ("SHOW")
    
;*** SYSPREP ***
    If IniRead($settings, "Script_Settings", "Run_Sysprep", "0") = 1 And IniRead($settings, "Program_Use_Only", "Ran_Sysprep", "0") = 0 Then
        GUICtrlSetData($current_action, "Running Sysprep")
        If @OSVersion = "WIN_XP" Then
            DirCopy($workingdir & "sysprep\WinXP\sysprep", "c:\sysprep", 1)
            Run("c:\sysprep\sysprep.exe")
        EndIf
        If @OSVersion = "WIN_2000" Then
            DirCopy("sysprep\Win2K\sysprep", "c:\sysprep", 1)
            Run("c:\sysprep\sysprep.exe")
        EndIf
        $progressref2 = $progressref2 + 1
        _Progress_Ref ("SHOW")
        Sleep(10000)
    EndIf
    
    _Progress_Ref ("SHOW")
    
    ExitLoop
WEnd

GUIDelete()

;Delete settings.ini if done
_DeleteINI ()

Exit
Edited by ACalcutt

Andrew Calcutt

Http://www.Vistumbler.net

Http://www.TechIdiots.net

Its not an error, its a undocumented feature

Share this post


Link to post
Share on other sites

hmm.. i dont know what i did but i seems like its working...maybe i messed up on the filename before :-/

i'll see if it still works on the actual network (i am using it over vpn right now)


Andrew Calcutt

Http://www.Vistumbler.net

Http://www.TechIdiots.net

Its not an error, its a undocumented feature

Share this post


Link to post
Share on other sites

#13 ·  Posted (edited)

it worked over vpn from my house, but it doesn't work here on the actual network

i also tried DriveMapAdd, but i cant get that to work with my wsc_domain\ACalcutt login...even though it works to log in though windows

Edited by ACalcutt

Andrew Calcutt

Http://www.Vistumbler.net

Http://www.TechIdiots.net

Its not an error, its a undocumented feature

Share this post


Link to post
Share on other sites

Well, I haven't been following this, but gotta tell you, I'd never thought of putting an .exe in the error slot of an ini read, and run it if it threw one... I think that's rather ingenius.

But... $workingdir << are both the 'key' .exe and the 'error' .exe actually located there? Or if the 'key' .exe has s different path, does it have the correct one?

Sorry, I don't have the ini to look at to give a better answer, so I'll just speculate.


[center]Common sense plays a role in the basics of understanding AutoIt... If you're lacking in that, do us all a favor, and step away from the computer.[/center]

Share this post


Link to post
Share on other sites

#16 ·  Posted (edited)

Well, I haven't been following this, but gotta tell you, I'd never thought of putting an .exe in the error slot of an ini read, and run it if it threw one... I think that's rather ingenius.

But... $workingdir << are both the 'key' .exe and the 'error' .exe actually located there? Or if the 'key' .exe has s different path, does it have the correct one?

Sorry, I don't have the ini to look at to give a better answer, so I'll just speculate.

If you want to look at the code the whole program is here (with source)

http://www.autoitscript.com/forum/index.php?showtopic=19771

I dont really understand what your asking, basically i have another program that writes the ini file, if they change the default location of the program it writes that location to the [Program_Use_Only] section and program_exe key, then the program that performs the action checks the ini for that key, if it doesn't exist it uses the default(whats in the error slot)...so if a network location is used..or its somehwere else on the drive..it will use that instead of the default location (in the working dir)

Dim $cleansms_exe = IniRead($settings, "Program_Use_Only", "cleansms_exe", $workingdir & "\CleanSMS\AutoRun_cleansms.exe")

---

i know the path is correct...because it is located on \\macross\PrepSys...if i run the program i get the error i showed above...but if before i run the program i manually go start --> run --> enter \\macross\PrepSys --> then put my credentials in. if run the program after i do that the program rruns without any problem

Edited by ACalcutt

Andrew Calcutt

Http://www.Vistumbler.net

Http://www.TechIdiots.net

Its not an error, its a undocumented feature

Share this post


Link to post
Share on other sites

Did you try running it as:

RunWait(FileGetShortName($cleansns_exe), @TempDir)

[center]Common sense plays a role in the basics of understanding AutoIt... If you're lacking in that, do us all a favor, and step away from the computer.[/center]

Share this post


Link to post
Share on other sites

#18 ·  Posted (edited)

Did you try running it as:

RunWait(FileGetShortName($cleansns_exe), @TempDir)
no, i havent tried that yet.

i will monday when i get to work

it seems to me that it is just not authenticating the way i think it should...mayby i was wrong to put the 2 option in runasset

;Set privlages if needed
If IniRead($settings, "Program_Use_Only", "NetLogon", "0") = 1 Then RunAsSet($netuser, $netdom, $netpass, 2)

it also kind of bothered me that drivemapadd wouldn't work with my wsc_domain\ACalcutt account either

Edited by ACalcutt

Andrew Calcutt

Http://www.Vistumbler.net

Http://www.TechIdiots.net

Its not an error, its a undocumented feature

Share this post


Link to post
Share on other sites

Good Deal... I'll look for your post monday then... have a safe weekend.


[center]Common sense plays a role in the basics of understanding AutoIt... If you're lacking in that, do us all a favor, and step away from the computer.[/center]

Share this post


Link to post
Share on other sites

#20 ·  Posted (edited)

i just found out it was only working at home because my admin password on my laptop is the same as the admin password on \\macross... i changed my local password and now i get the same error from home...i am going to test your idea now

when i was at work i was testing from a differnet machine, that has a different admin password

Edited by ACalcutt

Andrew Calcutt

Http://www.Vistumbler.net

Http://www.TechIdiots.net

Its not an error, its a undocumented feature

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!


Register a new account

Sign in

Already have an account? Sign in here.


Sign In Now
Sign in to follow this  
Followers 0