FATIHTALI Posted February 2, 2009 Share Posted February 2, 2009 (edited) I made a small agent. Program comparing pc and server sides ini file. I want to use this program in windows services. Is any one has experience for it. I need that because If I can start my program in windows services my program will work system account also it will work admin rights. Thanks. Fatih .expandcollapse popup#include <file.au3> #Include <Array.au3> Dim $serverARRAY Dim $pcARRAY $USERNAME = "xxxx" $DOMAIN = "xxxx" $PASSWORD ="xxxx" $tarih =@MDAY&"."&@MON&"."&@YEAR&"."&@HOUR&":"&@MIN&":"&@SEC FileWriteLine("\\server\agent.log",""&@ComputerName&".tofas.local,"&@OSVersion&","&@OSServicePack&","&$tarih);---------------hearth beet If Not _FileReadToArray("\\server\kurulacaklar.ini",$serverARRAY) Then MsgBox(16,"Bağlantı Hatası", "Server Bilgileri Şu an Okunamıyor. Program Bir sonraki açılışta tekrar bağlantıyı deneyecek.") Exit EndIf if not FileExists("C:\SISTEM\kurulumlar.ini") Then DirCreate ( "C:\SISTEM" ) _FileCreate("C:\SISTEM\kurulumlar.ini") EndIf If Not _FileReadToArray("C:\SISTEM\kurulumlar.ini",$pcARRAY) Then Exit EndIf For $x = 5 to $serverARRAY[0] $Flag = 0 For $y = 0 to $pcARRAY[0] If $serverARRAY[$x]=$pcARRAY[$y] then ;-----güncelleme yok ;MsgBox(0, "Line read:", $pcARRAY[$y]) $Flag = 1 ExitLoop endif Next if $flag = 0 then RunASWait($USERNAME,$DOMAIN,$PASSWORD,0,$serverARRAY[$x], @SystemDir) Endif Next Exit Edited February 2, 2009 by FATIHTALI Startup Agent It is my small Startup Agent. You can install programs on startup Domain pc without Admin rights. Link to comment Share on other sites More sharing options...
Andreik Posted February 2, 2009 Share Posted February 2, 2009 Read FAQ about running a script as service. When the words fail... music speaks. Link to comment Share on other sites More sharing options...
FATIHTALI Posted March 8, 2009 Author Share Posted March 8, 2009 Hello. I have new question. I made my program. It is working well. My program is working every restart. Can I run my program from a admin console like that. Program can listen from network when program reveive signal it will work. It can be possible? Thanks Fatih Startup Agent It is my small Startup Agent. You can install programs on startup Domain pc without Admin rights. Link to comment Share on other sites More sharing options...
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now