Jump to content

All Activity

This stream auto-updates     

  1. Past hour
  2. Hi Jos, I un-installed it again, downloaded a fresh version and re-installed it in Programs(x86). Still no luck. SciTE still works ok. I did however, navigate to the AutoIt3 folder and ran the Autoit3_x64.exe from there. When it prompted me for the ".au3" file to open I picked the script and it ran ok (?) Therefore, double-clicking on an ".au3" script seems to fail, but openning either SciTE or running Autoit3_x64.exe works!!! The Registry entries are still the same as above. Kind regards, Pete
  3. So you have a standard directory structure in program files(x86)\AutoIt\includes and it contains all files? Any security settings issue or something? Try running SciTE as Admin and test again, just to see if that changes anything. Jos
  4. Hi Jos... Yes. I downloaded the latest version from the official site and used the installer to install it. 🙂
  5. Hmmm, I don't have AutoUpdateIt, but I do have AU3Info, Aut2Exe and AutoIt. Look like you have some bad install, but I cannot be sure. Maybe someone else could help...
  6. Have you used the installer to install AutoIt3? Jos
  7. Hi Nine, many thanks for your quick response. 🙂 I don't have that entry. All I have is: HKEY_CURRENT_USER\Software\AutoIt v3\Aut2Exe HKEY_CURRENT_USER\Software\AutoIt v3\AutoUpdateIt
  8. Could you look at this key in regedit : HKEY_CURRENT_USER\Software\AutoIt v3\AutoIt - Include ?
  9. Hi Guys, Apparently the problem is "Citrix" as it uses a cut-down version of IE6 as an interface, which excludes certain functionality. AutoIT sends the correct command to Citrix, but as the IE6 has been stripped down it doesn't include that functionality any more. The workaround is to use send({LWINDOWN}{UP}{LWINUP}) which does the trick. Thanks to everyone who helped. Hopefully one day I will as knowledgable as you peeps 🙂
  10. Today
  11. Hi guys, I am still learning the ropes, so apologies if I have missed something obvious. Basically, the #include statement is not working for me (not even when I include the full pathname) e.g. #include <Date.au3> MsgBox(0,'',"The time is:" & _NowTime()) The above example returns the following error; #include <Date.au3> Error opening the file I tried removing/reinstalling Autoit3, but to no avail. I have tried installing AutoIt3 firstly in Programs & then when that didn't work, I un-installed it again and re-installed it in Programs(x86). Have also tried using both AutoIt3.exe and AutoIt3_x64.exe versions, but each time it is the same error. The only way that the above script (or any script) works is if I run it from within SciTE. Has anyone else encountered such problems? Many thanks, Pete
  12. I am curious if this code could work on 300,000 rows. I have Excell 2003, so I am limited to 65k rows. But the result is quite fast. Maybe you could try it : #include <Excel.au3> #include <MsgBoxConstants.au3> Local $oExcel = _Excel_Open() If @error Then Exit MsgBox($MB_SYSTEMMODAL, "", "Error creating the Excel application object.") Local $oWorkbook = _Excel_BookOpen($oExcel, "65000.xls") If @error Then Exit MsgBox($MB_SYSTEMMODAL, "", "Error opening Workbook") _Excel_RangeSort($oWorkbook, Default, Default, "A:A") If @error Then Exit MsgBox($MB_SYSTEMMODAL, "", "Error sorting data.") Local $iPrev = 1 Local $aResult = _Excel_RangeRead($oWorkbook, Default, "A:A") For $i = 2 to 10 $iFound = _ArraySearch ($aResult,$i,$iPrev-1,0,0,0,1,0) MakeCopy ($iPrev, $iFound, @ScriptDir & "\T" & $i-1 & ".xls") $iPrev = $iFound+1 Next MakeCopy ($iPrev, UBound ($aResult), @ScriptDir & "\T10.xls") Func MakeCopy ($iStart, $iEnd, $sName) Local $oRange = $oWorkbook.ActiveSheet.Range("A" & $iStart & ":N" & $iEnd) Local $oWB = _Excel_BookNew ($oExcel, 1) _Excel_RangeCopyPaste($oWB.ActiveSheet, $oRange, "A1") If @error Then Exit MsgBox($MB_SYSTEMMODAL, "", "Error copying cells." & "/" & @error) _Excel_BookSaveAs($oWB, $sName, $xlWorkbookNormal, True) If @error Then Exit MsgBox($MB_SYSTEMMODAL, "", "Error saving as" & "/" & @error) _Excel_BookClose ($oWB,False) EndFunc
  13. Sorry but I don't understand what you mean by " use Autoit's sql commands on top ". You just query the SQLite database with the SQLite.au3 UDF. Again if your source Excel file will change, the DB must be changed accordingly, so going thru SQLite isn't beneficial (details may muddy the border). But if the Excel file is given once for all, you can most probably benefit from the power of SQLite queries, including add-on functions if necessary. For instance, recent SQLite versions offer windowing features, full text table search (legacy feature), and a lot more. It all depends on the needs you have and the complexity of your queries. The nice thing is that SQLite doesn't need any installation nor maintenance, contrary to "heavy" client-server DB engines.
  14. Once its accessed via ADO, and extract it into a SQLite DB (as jchd said), would you then use Autoit's sql commands on top, or would you just access it via a SQLite and use sql commands?
  15. Macro BlockInput(bool) BlockInput_(bool) EndMacro BlockInput(1) Delay(3000) BlockInput(0) I fixed two functions. There it is not possible to get the size of the field to return data. Procedure.s DriveGetLabel(Drive$) Protected Label$ Label$=Space(#MAX_PATH+1) If Not GetVolumeInformation_(Drive$,Label$,#MAX_PATH+1,0,0,0,0,0) Procedure_Error = 1 ProcedureReturn "" EndIf ProcedureReturn Label$ EndProcedure MessageRequester("Disk label", DriveGetLabel("C:\")) Procedure.s DriveGetFileSystem(Drive$) Protected FileSystem$ FileSystem$=Space(#MAX_PATH+1) If GetVolumeInformation_(Drive$,0,0,0,0,0,@FileSystem$,#MAX_PATH+1) ProcedureReturn FileSystem$ Else Procedure_Error = 1 ProcedureReturn "1" EndIf EndProcedure MessageRequester("File system type", DriveGetFileSystem("C:\"))
  16. @jdelaney I'm traveling now and when I go back I'll do the tests, thanks for the tips.
  17. Updating the code I will try to simplify as much as possible the last functions
  18. What's New in Version 0.2019.04.19 fixed: GetProcessTimes() crashing on multi-user setup The code is in the downloads area.
  19. Internet search engine use https://docs.microsoft.com/en-us/windows/desktop/api/fileapi/nf-fileapi-getdrivetypea DRIVE_UNKNOWN = 0
  20. @AZJIO Hello friend the first example requires a correction ( Line 83:Constant not found : #DRIVE_UNKNOWN ) thank you
  21. Epicface, FrancescoDiMuro is quite right - please read the Forum rules - particularly the bit about not discussing game automation - before you post again. Thread locked. But welcome to the AutoIt forum - and see you soon with a legitimate question I hope. M23
  22. The good sense to read forum rules, since game automation is not allowed on these forums.
  23. If that's OK then you can get rid of the first column, since it's just a redundant decoration of the row number, i.e. the index thru the array. That will simplify code some more. If you want to save the simplified array while adding the "name #" prefix, you can do that while going thru the array for output. Also I still don't understand what you meant whith "A1Peter...": the A1, B2 C3 prefixes jump in your post but have no materialization in the code sample you supplied. That's why I ignored that sentence.
  24. I dug and created something like that. However, once he clicks the right one, then he does not repeat it anymore. What should I add?
  25. Element? Is it faster? I want to automate gaining things in the game. When she appears in this place, she wants to take her. There are 3 things. Two concern me, one does not concern me, so I have to use two colors.
  26. EnableExplicit Define ini$ ini$ = GetPathPart(ProgramFilename()) + GetFilePart(ProgramFilename(), #PB_FileSystem_NoExtension) + ".ini" Procedure.s IniRead(filename$, section$, key$, def$ = "") Protected res$ If OpenPreferences(filename$) If PreferenceGroup(section$) res$ = ReadPreferenceString(key$, def$) EndIf ClosePreferences() EndIf ProcedureReturn res$ EndProcedure Procedure IniWrite(filename$, section$, key$, value$) Protected res If FileSize(filename$) < 0 ; CreateFile(0, filename$) ; WriteString(0, #CRLF$) ; CloseFile(0) CreatePreferences(filename$) ClosePreferences() EndIf If OpenPreferences(filename$) PreferenceGroup(section$) res = WritePreferenceString(key$, value$) ClosePreferences() EndIf ProcedureReturn res EndProcedure Procedure IniDelete(filename$, section$, key$ = "") If OpenPreferences(filename$) If key$ = "" RemovePreferenceGroup(section$) Else If PreferenceGroup(section$) RemovePreferenceKey(key$) EndIf EndIf ClosePreferences() EndIf EndProcedure IniWrite(ini$, "Set", "KeyWin", "new_value") MessageRequester("Here it is", IniRead(ini$, "Set", "KeyWin", "Default value")) IniDelete(ini$, "Set", "KeyWin") IniDelete(ini$, "Set") ; EnableExplicit ; Define ini$ ; ini$ = GetPathPart(ProgramFilename()) + GetFilePart(ProgramFilename(), #PB_FileSystem_NoExtension) + ".ini" ; Make the ini-file was not empty Procedure IniReadSectionNames(filename$, List Groups.s()) If OpenPreferences(filename$) ExaminePreferenceGroups() While NextPreferenceGroup() AddElement(Groups()) Groups() = PreferenceGroupName() Wend ClosePreferences() EndIf EndProcedure NewList Groups.s() IniReadSectionNames(ini$, Groups()) Define List1.s ForEach Groups() List1 + Groups() + #CRLF$ Next MessageRequester("List", List1) Procedure IniReadSection(filename$, section$, Map key_value.s()) If OpenPreferences(filename$) If PreferenceGroup(section$) ExaminePreferenceKeys() While NextPreferenceKey() AddMapElement(key_value(), PreferenceKeyName()) key_value() = PreferenceKeyValue() ; key_value(PreferenceKeyName()) = PreferenceKeyValue() Wend EndIf ClosePreferences() EndIf EndProcedure NewMap key_value.s() IniReadSection(ini$, "Set", key_value()) Define Map1.s ForEach key_value() Map1 + MapKey(key_value()) + " = " + key_value() + #CRLF$ Next MessageRequester("Map", Map1)
  1. Load more activity
  • Create New...