shai Posted June 3, 2011 Share Posted June 3, 2011 i have this code: Public Sub mp_QueryStatus() Dim mp As PCHideLib.closer Dim bInstalled As Boolean mp = Getcloser() Dim lInstalled As Long Dim lRunning As Long If mp.GetServiceStatus(lInstalled, lRunning) = 0 Then bInstalled = False print.debug(Now & " - " & "no mp installed") Else If lInstalled = 1 Then bInstalled = True print.debug(Now & " - " & "mp installed") Else print.debug(Now & " - " & "no mp installed") End If If lRunning = 1 Then print.debug(Now & " - " & "mp is running") Else print.debug(Now & " - " & "mp is not running") End If End If End Sub Public Function Getcloser() As PCHideLib.closer Dim dt As New PCHideLib.closer Dim lSeed As Integer lSeed = dt.GetSeed dt.Initialize(CalculateAnswer(lSeed)) Getcloser = dt End Function how i can convert it to auto it? thanks. Link to comment Share on other sites More sharing options...
MHz Posted June 3, 2011 Share Posted June 3, 2011 Services is quite much discussed as many need the functions. I suggest searching the Example forum for some UDFs that handle services. SumTingWong/Pacman did the first IIRC in 2004 Other then the whitespace in the code missed up, the code is still intact. Many others have made variations since then that you may find.I am not sure what the Getcloser() function has to do with anything that you show in the code. Link to comment Share on other sites More sharing options...
shai Posted June 3, 2011 Author Share Posted June 3, 2011 I do not have enough experience with it. I would love more help. If possible sample code Link to comment Share on other sites More sharing options...
Maffe811 Posted June 3, 2011 Share Posted June 3, 2011 So you dont have experience with coding or autoit ? [font="helvetica, arial, sans-serif"]Hobby graphics artist, using gimp.Automating pc stuff, using AutoIt.Listening to music, using Grooveshark.[/font]Scripts:[spoiler]Simple ScreenshotSaves you alot of trouble when taking a screenshot!Don't remember what happened with this, but aperantly the exe is all i got.If you don't want to run it, simply don't._IsRun UDFIt figures out if the script has ben ran before based on the info in a ini file.If you don't want to use exactly what i wrote, you can use it as inspiration.[/spoiler] Link to comment Share on other sites More sharing options...
shai Posted June 4, 2011 Author Share Posted June 4, 2011 (edited) I know better autoit but converted from another language to make it more difficult for me. Edited June 4, 2011 by shai Link to comment Share on other sites More sharing options...
shai Posted June 8, 2011 Author Share Posted June 8, 2011 maybe anyone can help me? Link to comment Share on other sites More sharing options...
Developers Jos Posted June 8, 2011 Developers Share Posted June 8, 2011 maybe anyone can help me?Sure, just post what you have and what you have problems with. SciTE4AutoIt3 Full installer Download page - Beta files Read before posting How to post scriptsource Forum etiquette Forum Rules Live for the present, Dream of the future, Learn from the past. Link to comment Share on other sites More sharing options...
shai Posted June 8, 2011 Author Share Posted June 8, 2011 I have nothing. I want to know how to convert the code above to the autoit script. Link to comment Share on other sites More sharing options...
Maffe811 Posted June 8, 2011 Share Posted June 8, 2011 You.. Uhm... Start converting it ? [font="helvetica, arial, sans-serif"]Hobby graphics artist, using gimp.Automating pc stuff, using AutoIt.Listening to music, using Grooveshark.[/font]Scripts:[spoiler]Simple ScreenshotSaves you alot of trouble when taking a screenshot!Don't remember what happened with this, but aperantly the exe is all i got.If you don't want to run it, simply don't._IsRun UDFIt figures out if the script has ben ran before based on the info in a ini file.If you don't want to use exactly what i wrote, you can use it as inspiration.[/spoiler] Link to comment Share on other sites More sharing options...
shai Posted June 8, 2011 Author Share Posted June 8, 2011 no. because i dont know how. Link to comment Share on other sites More sharing options...
shai Posted June 12, 2011 Author Share Posted June 12, 2011 Sure, just post what you have and what you have problems with.you have something for help me? Link to comment Share on other sites More sharing options...
Developers Jos Posted June 12, 2011 Developers Share Posted June 12, 2011 (edited) you have something for help me?Sure, show us what you want help with ... Wait, didn't we already pas this part earlier in this discussion? Edited June 12, 2011 by Jos SciTE4AutoIt3 Full installer Download page - Beta files Read before posting How to post scriptsource Forum etiquette Forum Rules Live for the present, Dream of the future, Learn from the past. Link to comment Share on other sites More sharing options...
Maffe811 Posted June 12, 2011 Share Posted June 12, 2011 I think so! I would love to point you to some usefull sections in the helpfile. But i dont know vb so i dont know what the script does. I would suggest trying to figure out what the script does, find a matching command in the help file and then start writing the code. Then post the code and we will try to help [font="helvetica, arial, sans-serif"]Hobby graphics artist, using gimp.Automating pc stuff, using AutoIt.Listening to music, using Grooveshark.[/font]Scripts:[spoiler]Simple ScreenshotSaves you alot of trouble when taking a screenshot!Don't remember what happened with this, but aperantly the exe is all i got.If you don't want to run it, simply don't._IsRun UDFIt figures out if the script has ben ran before based on the info in a ini file.If you don't want to use exactly what i wrote, you can use it as inspiration.[/spoiler] Link to comment Share on other sites More sharing options...
guinness Posted June 12, 2011 Share Posted June 12, 2011 I'm guessing they should search for the Keywords, WMI, Win32_Service & _IsServiceRunning. UDF List: _AdapterConnections() • _AlwaysRun() • _AppMon() • _AppMonEx() • _ArrayFilter/_ArrayReduce • _BinaryBin() • _CheckMsgBox() • _CmdLineRaw() • _ContextMenu() • _ConvertLHWebColor()/_ConvertSHWebColor() • _DesktopDimensions() • _DisplayPassword() • _DotNet_Load()/_DotNet_Unload() • _Fibonacci() • _FileCompare() • _FileCompareContents() • _FileNameByHandle() • _FilePrefix/SRE() • _FindInFile() • _GetBackgroundColor()/_SetBackgroundColor() • _GetConrolID() • _GetCtrlClass() • _GetDirectoryFormat() • _GetDriveMediaType() • _GetFilename()/_GetFilenameExt() • _GetHardwareID() • _GetIP() • _GetIP_Country() • _GetOSLanguage() • _GetSavedSource() • _GetStringSize() • _GetSystemPaths() • _GetURLImage() • _GIFImage() • _GoogleWeather() • _GUICtrlCreateGroup() • _GUICtrlListBox_CreateArray() • _GUICtrlListView_CreateArray() • _GUICtrlListView_SaveCSV() • _GUICtrlListView_SaveHTML() • _GUICtrlListView_SaveTxt() • _GUICtrlListView_SaveXML() • _GUICtrlMenu_Recent() • _GUICtrlMenu_SetItemImage() • _GUICtrlTreeView_CreateArray() • _GUIDisable() • _GUIImageList_SetIconFromHandle() • _GUIRegisterMsg() • _GUISetIcon() • _Icon_Clear()/_Icon_Set() • _IdleTime() • _InetGet() • _InetGetGUI() • _InetGetProgress() • _IPDetails() • _IsFileOlder() • _IsGUID() • _IsHex() • _IsPalindrome() • _IsRegKey() • _IsStringRegExp() • _IsSystemDrive() • _IsUPX() • _IsValidType() • _IsWebColor() • _Language() • _Log() • _MicrosoftInternetConnectivity() • _MSDNDataType() • _PathFull/GetRelative/Split() • _PathSplitEx() • _PrintFromArray() • _ProgressSetMarquee() • _ReDim() • _RockPaperScissors()/_RockPaperScissorsLizardSpock() • _ScrollingCredits • _SelfDelete() • _SelfRename() • _SelfUpdate() • _SendTo() • _ShellAll() • _ShellFile() • _ShellFolder() • _SingletonHWID() • _SingletonPID() • _Startup() • _StringCompact() • _StringIsValid() • _StringRegExpMetaCharacters() • _StringReplaceWholeWord() • _StringStripChars() • _Temperature() • _TrialPeriod() • _UKToUSDate()/_USToUKDate() • _WinAPI_Create_CTL_CODE() • _WinAPI_CreateGUID() • _WMIDateStringToDate()/_DateToWMIDateString() • Au3 script parsing • AutoIt Search • AutoIt3 Portable • AutoIt3WrapperToPragma • AutoItWinGetTitle()/AutoItWinSetTitle() • Coding • DirToHTML5 • FileInstallr • FileReadLastChars() • GeoIP database • GUI - Only Close Button • GUI Examples • GUICtrlDeleteImage() • GUICtrlGetBkColor() • GUICtrlGetStyle() • GUIEvents • GUIGetBkColor() • Int_Parse() & Int_TryParse() • IsISBN() • LockFile() • Mapping CtrlIDs • OOP in AutoIt • ParseHeadersToSciTE() • PasswordValid • PasteBin • Posts Per Day • PreExpand • Protect Globals • Queue() • Resource Update • ResourcesEx • SciTE Jump • Settings INI • SHELLHOOK • Shunting-Yard • Signature Creator • Stack() • Stopwatch() • StringAddLF()/StringStripLF() • StringEOLToCRLF() • VSCROLL • WM_COPYDATA • More Examples... Updated: 22/04/2018 Link to comment Share on other sites More sharing options...
shai Posted June 12, 2011 Author Share Posted June 12, 2011 i only know the function in vb source code this is a functions: Public Sub mp_QueryStatus() Dim mp As PCHideLib.closer Dim bInstalled As Boolean mp = Getcloser() Dim lInstalled As Long Dim lRunning As Long If mp.GetServiceStatus(lInstalled, lRunning) = 0 Then bInstalled = False print.debug(Now & " - " & "no mp installed") Else If lInstalled = 1 Then bInstalled = True print.debug(Now & " - " & "mp installed") Else print.debug(Now & " - " & "no mp installed") End If If lRunning = 1 Then print.debug(Now & " - " & "mp is running") Else print.debug(Now & " - " & "mp is not running") End If End If End Sub Public Function Getcloser() As PCHideLib.closer Dim dt As New PCHideLib.closer Dim lSeed As Integer lSeed = dt.GetSeed dt.Initialize(CalculateAnswer(lSeed)) Getcloser = dt End Function and I want to translate them to autoit lang. Link to comment Share on other sites More sharing options...
Maffe811 Posted June 12, 2011 Share Posted June 12, 2011 I give up. Look at the helpfile... [font="helvetica, arial, sans-serif"]Hobby graphics artist, using gimp.Automating pc stuff, using AutoIt.Listening to music, using Grooveshark.[/font]Scripts:[spoiler]Simple ScreenshotSaves you alot of trouble when taking a screenshot!Don't remember what happened with this, but aperantly the exe is all i got.If you don't want to run it, simply don't._IsRun UDFIt figures out if the script has ben ran before based on the info in a ini file.If you don't want to use exactly what i wrote, you can use it as inspiration.[/spoiler] Link to comment Share on other sites More sharing options...
guinness Posted June 12, 2011 Share Posted June 12, 2011 (edited) When you searched the Forum with the keywords I mentioned before did you find this >> Edited June 12, 2011 by guinness UDF List: _AdapterConnections() • _AlwaysRun() • _AppMon() • _AppMonEx() • _ArrayFilter/_ArrayReduce • _BinaryBin() • _CheckMsgBox() • _CmdLineRaw() • _ContextMenu() • _ConvertLHWebColor()/_ConvertSHWebColor() • _DesktopDimensions() • _DisplayPassword() • _DotNet_Load()/_DotNet_Unload() • _Fibonacci() • _FileCompare() • _FileCompareContents() • _FileNameByHandle() • _FilePrefix/SRE() • _FindInFile() • _GetBackgroundColor()/_SetBackgroundColor() • _GetConrolID() • _GetCtrlClass() • _GetDirectoryFormat() • _GetDriveMediaType() • _GetFilename()/_GetFilenameExt() • _GetHardwareID() • _GetIP() • _GetIP_Country() • _GetOSLanguage() • _GetSavedSource() • _GetStringSize() • _GetSystemPaths() • _GetURLImage() • _GIFImage() • _GoogleWeather() • _GUICtrlCreateGroup() • _GUICtrlListBox_CreateArray() • _GUICtrlListView_CreateArray() • _GUICtrlListView_SaveCSV() • _GUICtrlListView_SaveHTML() • _GUICtrlListView_SaveTxt() • _GUICtrlListView_SaveXML() • _GUICtrlMenu_Recent() • _GUICtrlMenu_SetItemImage() • _GUICtrlTreeView_CreateArray() • _GUIDisable() • _GUIImageList_SetIconFromHandle() • _GUIRegisterMsg() • _GUISetIcon() • _Icon_Clear()/_Icon_Set() • _IdleTime() • _InetGet() • _InetGetGUI() • _InetGetProgress() • _IPDetails() • _IsFileOlder() • _IsGUID() • _IsHex() • _IsPalindrome() • _IsRegKey() • _IsStringRegExp() • _IsSystemDrive() • _IsUPX() • _IsValidType() • _IsWebColor() • _Language() • _Log() • _MicrosoftInternetConnectivity() • _MSDNDataType() • _PathFull/GetRelative/Split() • _PathSplitEx() • _PrintFromArray() • _ProgressSetMarquee() • _ReDim() • _RockPaperScissors()/_RockPaperScissorsLizardSpock() • _ScrollingCredits • _SelfDelete() • _SelfRename() • _SelfUpdate() • _SendTo() • _ShellAll() • _ShellFile() • _ShellFolder() • _SingletonHWID() • _SingletonPID() • _Startup() • _StringCompact() • _StringIsValid() • _StringRegExpMetaCharacters() • _StringReplaceWholeWord() • _StringStripChars() • _Temperature() • _TrialPeriod() • _UKToUSDate()/_USToUKDate() • _WinAPI_Create_CTL_CODE() • _WinAPI_CreateGUID() • _WMIDateStringToDate()/_DateToWMIDateString() • Au3 script parsing • AutoIt Search • AutoIt3 Portable • AutoIt3WrapperToPragma • AutoItWinGetTitle()/AutoItWinSetTitle() • Coding • DirToHTML5 • FileInstallr • FileReadLastChars() • GeoIP database • GUI - Only Close Button • GUI Examples • GUICtrlDeleteImage() • GUICtrlGetBkColor() • GUICtrlGetStyle() • GUIEvents • GUIGetBkColor() • Int_Parse() & Int_TryParse() • IsISBN() • LockFile() • Mapping CtrlIDs • OOP in AutoIt • ParseHeadersToSciTE() • PasswordValid • PasteBin • Posts Per Day • PreExpand • Protect Globals • Queue() • Resource Update • ResourcesEx • SciTE Jump • Settings INI • SHELLHOOK • Shunting-Yard • Signature Creator • Stack() • Stopwatch() • StringAddLF()/StringStripLF() • StringEOLToCRLF() • VSCROLL • WM_COPYDATA • More Examples... Updated: 22/04/2018 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