Jump to content

SirWayNe

Members
  • Posts

    15
  • Joined

  • Last visited

Everything posted by SirWayNe

  1. Hey, thank you for the fast answer, it is working as intended now. This Function uses the name of the icon rather then the ordinal number. this has to be kept in mind, when using the Icon Selector from examples in AU3 Installation. Greetings.
  2. Hey, TLDR; Take Image from dll File, rotate as needed, Put into Button Control I want to use Icons from shell32 and Put them into Buttons as Images. So far so easy, Buttons are created with Style BS_ICON and the Image ist set via guictrlsetimage with specific identifier. But the Idea is to use arrows or other Icons from the shell32.dll or different files, but rotating them as needed for the Button controls. Since the Rotation has to be done at runtime, creating the icons in advance wont work. I got a bit lost, using GDI Plus in this. Every attemp i tried, failed in No Icon displayed. But i am not used to GDI Plus at all, that might be the Problem here. When i have access to the current source, i will add this to the topic. Any ideas so far how to solve this? Greetings.
  3. Hey its me again I just had another issue with your currently well working Script. I uploaded a Foto that shows the Issue. Its with my ID 924-927. The Array on the left side is created by your Function, _XLSXReadToArray. Hope you can help me again, because i am using your Script to apply different languages to my Script. Greetings, SirWayNe Language_AudioParser.xlsx
  4. Yep, that looks fine now. Thanks for fast Reply finally i can use my LanguageFile in a proper way. You will be given Credits for your awesome work
  5. Hi DXRW4E, first of all: thx for sharing, looks nice, but i got several reading errors using your script. $aScriptLanguageFile = _XLSXReadToArray($sScriptLanguageFile) MsgBox("",@extended,@error) _ArrayDisplay($aScriptLanguageFile) This code shows the way i use your Script, and it fills the given array improperly. i will attach the .xlsx File on this post. I am using Microsoft Office 2007 with updates applied. I got reading i.e. Errors on Line 476. It does not Exist in the array and other Array entries got different Values then it should be. Hope you can help me, because i really want to use a .xlsx File for different Languages instead of using different .txt Files..... Greetings SirWayNe Language.xlsx
  6. I found this Example, i try to use this one, since i can determine the file format. I try to use .xlsx then. Thx for fast reply
  7. I want to read the complete Worksheet into an array line by line. I do not want to replace or write any Data into the Excel Sheet.
  8. Hi there, i am using an Excel Sheet to read from with the UDF _Excel in AutoIt. But this UDF doesnt work on Computers, that dont have Microsoft Office (Excel) installed. Thats why im searching for a dll that i can include into my script to prevent those error messages. Can you help me on this Situation? Greetings SirWayNe
  9. I fixed some Functions, it should work properly now: #cs Datentypen Variable: AudioGenie.dll AutoItV3 Int16 short Int32 DWORD UInt32 DWORD -> _StringtoInt($var) Float float BSTR wstr LPCWSTR wstr Pointer ptr #ce #cs AUDIOAnalyzeW Return Value Beschreibung 0 unbekannt 1 MP3 2 WMA 3 MONKEY 4 FLAC 5 WAV 6 OGG Vorbis 7 MPP 8 AAC 9 MP4/M4A 10 TTA 11 wavpack #ce Func _AudioGenieInit() FileInstall("0-IncludeAudioGenie3.dll","AudioGenie3.dll",1) $hScriptAudioGenie = DllOpen("AudioGenie3.dll") Return @error EndFunc Func _AudioGenieReadFile($file) $aScriptAudioFile = DllCall($hScriptAudioGenie,"WORD","AUDIOAnalyzeFileW","wstr",$file) Return @error EndFunc Func _AudioGenieReadTag($tag,$ext = "") Local $field[1] If Not $tag Then Return SetError(1,0,1) Switch $tag ; ID3V1 auslesen Case "Title" $field = DllCall($hScriptAudioGenie,"wstr","ID3V1GetTitleW") Case "Artist" $field = DllCall($hScriptAudioGenie,"wstr","ID3V1GetArtistW") Case "Album" $field = DllCall($hScriptAudioGenie,"wstr","ID3V1GetAlbumW") Case "Track" $field = DllCall($hScriptAudioGenie,"wstr","ID3V1GetTrackW") Case "Genre" $field = DllCall($hScriptAudioGenie,"wstr","ID3V1GetGenreW") Case "Year" $field = DllCall($hScriptAudioGenie,"wstr","ID3V1GetYearW") ; ID3V2 auslesen Case "APIC"; Cover ; -1 bei gefundenem Tag ; 0 bei nicht gefundenen Tag If $ext = "" Then Return SetError(1,0,1) $field = DllCall($hScriptAudioGenie,"short","ID3V2GetPictureFileW","wstr",$ext,"WORD","1") If $field[0] = -1 Then $field[0] = $ext Case Else; alle anderen ID3V2 Tags werden über $tag ausgelesen $field = DllCall($hScriptAudioGenie,"wstr","ID3V2GetTextFrameW","DWORD",_StringToInt($tag)) If @error Then ConsoleWrite("Error Read " & $tag & @error & @CRLF) EndSwitch If IsArray($field) = 1 Then Return $field[0] Else Return $field EndIf EndFunc Func _AudioGenieSaveV1() Local $i = DllCall($hScriptAudioGenie,"short","ID3V1SaveChangesW") If @error Then ConsoleWrite("Error Save V1 " & @error & @CRLF) If $i = 0 Then ConsoleWrite("Error Save V1 " & $i & @CRLF) EndFunc Func _AudioGenieSaveV2() Local $i = DllCall($hScriptAudioGenie,"short","ID3V2SaveChangesW") If @error Then ConsoleWrite("Error Save V2 " & $i[0] & @CRLF) If $i = 0 Then ConsoleWrite("Error Save V2 " & $i & @CRLF) Return @error EndFunc Func _AudioGenieSaveTag($tag,$field) $tag = StringStripWS(StringStripCR($tag),3) $field = StringStripWS(StringStripCR($field),3) If Not $tag Then Return SetError(1,0,1) If Not $field Then Return SetError(2,0,1) Switch $tag ; ID3V1 Tags speichern Case "Title" DllCall($hScriptAudioGenie,"none","ID3V1SetTitleW","wstr",$field) If @error Then ConsoleWrite("Error " & $tag & @error & @CRLF) Case "Artist" DllCall($hScriptAudioGenie,"none","ID3V1SetArtistW","wstr",$field) If @error Then ConsoleWrite("Error " & $tag & @error & @CRLF) Case "Album" DllCall($hScriptAudioGenie,"none","ID3V1SetAlbumW","wstr",$field) If @error Then ConsoleWrite("Error " & $tag & @error & @CRLF) Case "Track" DllCall($hScriptAudioGenie,"none","ID3V1SetTrackW","wstr",$field) If @error Then ConsoleWrite("Error " & $tag & @error & @CRLF & $field) Case "Genre"; -> String führt zu Fehler, evtl die ID speichern mit ID3V1SetGenreIDW DllCall($hScriptAudioGenie,"none","ID3V1SetGenreW","wstr",$field) If @error Then ConsoleWrite("Error " & $tag & @error & @CRLF) Case "Year" DllCall($hScriptAudioGenie,"none","ID3V1SetYearW","wstr",$field) If @error Then ConsoleWrite("Error " & $tag & @error & @CRLF) ; ID3V2 Tags speichern Case "APIC" DllCall($hScriptAudioGenie,"short","ID3V2AddPictureFileW","wstr",$field,"wstr","","WORD","03","WORD","0") If @error Then ConsoleWrite("Error " & $tag & @error & @CRLF) Case Else; alle anderen Tags werden über $tag gespeichert DllCall($hScriptAudioGenie,"wstr","ID3V2SetTextFrameW","DWORD",_StringToInt($tag),"wstr",$field) If @error Then ConsoleWrite("Error " & $tag & @error & @CRLF) EndSwitch EndFunc Func _AudioGenieSaveTagGetGenreID($field) If $field = "" Then Return SetError(1,0,1) Local $array[148] = ["Blues","Classic Rock","Country","Dance","Disco","Funk", _ "Grunge","Hip-Hop","Jazz","Metal","New Age","Oldies","Other","Pop","R&B", _ "Rap","Reggae","Rock","Techno","Industrial","Alternative","Ska","Death Metal", _ "Pranks","Soundtrack","Euro-Techno","Ambient","Trip-Hop","Vocal","Jazz+Funk", _ "Fusion","Trance","Classical","Instrumental","Acid","House","Game","Sound Clip", _ "Gospel","Noise","AlternRock","Bass","Soul","Punk","Space","Meditative", _ "Instrumental Pop","Instrumental Rock","Ethnic","Gothic","Darkwave", _ "Techno-Industrial","Electronic","Pop-Folk","Eurodance","Dream","Southern Rock", _ "Comedy","Cult","Gangsta","Top","Christian Rap","Pop & Funk","Jungle", _ "Native American","Cabaret","New Wave","Psychedelic","Rave","Showtunes","Trailer", _ "Lo-Fi","Tribal","Acid Punk","Acid Jazz","Polka","Retro","Musical","Rock & Roll", _ "Hard Rock","Folk","Folk-Rock","National Folk","Swing","Fast Fusion","Bebob", _ "Latin","Revival","Celtic","Bluegrass","Avantgarde","Gothic Rock","Progressive Rock", _ "Psychedelic Rock","Symphonic Rock","Slow Rock","Big Band","Chorus","Easy Listening", _ "Acoustic","Humour","Speech","Chanson","Opera","Chamber Music","Sonata","Symphony", _ "Booty Bass","Primus","Porn Groove","Satire","Slow Jam","Club","Tango","Samba", _ "Folklore","Ballad","Power Ballad","Rhythmic Soul","Freestyle","Duet","Punk Rock", _ "Drum Solo","A capella","Euro-House","Dance Hall","Goa","Drum & Bass","Club-House", _ "Hardcore","Terror","Indie","BritPop","Negerpunk","Polsk Punk","Beat", _ "Christian Gangsta Rap","Heavy Metal","Black Metal","Crossover","Contemporary Christian", _ "Christian Rock","Merengue","Salsa","Trash Metal","Anime","JPop","Synthpop"] Local $int = _ArraySearch($array,$field,0,0,1) If $int = -1 Then Return SetError(2,0,1) $int += 1 Return $int EndFunc Func _AudioGenieReadBitrate() Local $result = DllCall($hScriptAudioGenie,"BOOL","AUDIOGetBitrateW") Return $result[0] EndFunc Func _AudioGenieReadSamplerate() Local $result = DllCall($hScriptAudioGenie,"BOOL","AUDIOGetSampleRateW") Return $result[0] EndFunc Func _AudioGenieReadChannel() Local $result = DllCall($hScriptAudioGenie,"wstr","AUDIOGetChannelModeW") Return $result[0] EndFunc Func _AudioGenieReadVersion() Local $result = DllCall($hScriptAudioGenie,"wstr","AUDIOGetVersionW") Return $result[0] EndFunc Func _AudioGenieReadDuration() Local $result = DllCall($hScriptAudioGenie,"float","AUDIOGetDurationW") $return = Floor($result[0]) Return $return EndFunc
  10. This is what i got so far. Functions to Include it into my Script, only the beginning and quite not fully tested. Global $hScriptAudioGenie; Handle für die AudioGenie3.dll Global $aScriptAudioFile; Array für AudioGenie3.dll. Return der DLLCall: [0]: Typ. [1]: Ort. And the Code: #cs Datentypen Variable: AudioGenie.dll AutoItV3 Int16 short Int32 DWORD UInt32 DWORD _StringtoInt($var) Float float BSTR wstr LPCWSTR wstr Pointer ?? #ce #cs AUDIOAnalyzeW Return Value Beschreibung 0 unbekannt 1 MP3 2 WMA 3 MONKEY 4 FLAC 5 WAV 6 OGG Vorbis 7 MPP 8 AAC 9 MP4/M4A 10 TTA 11 wavpack #ce Func _AudioGenieInit() FileInstall("0-Include\AudioGenie3.dll","AudioGenie3.dll",1) $hScriptAudioGenie = DllOpen("AudioGenie3.dll") Return @error EndFunc Func _AudioGenieReadFile($file) $aScriptAudioFile = DllCall($hScriptAudioGenie,"WORD","AUDIOAnalyzeFileW","wstr",$file) Return @error EndFunc Func _AudioGenieReadTag($tag,$ext = "") Local $field[1] If Not $tag Then Return SetError(1,0,1) Switch $tag ; ID3V1 auslesen Case "Title" $field = DllCall($hScriptAudioGenie,"wstr","ID3V1GetTitleW") Case "Artist" $field = DllCall($hScriptAudioGenie,"wstr","ID3V1GetArtistW") Case "Album" $field = DllCall($hScriptAudioGenie,"wstr","ID3V1GetArtistW") Case "Track" $field = DllCall($hScriptAudioGenie,"wstr","ID3V1GetTrackW") Case "Genre" $field = DllCall($hScriptAudioGenie,"wstr","ID3V1GetGenreW") Case "Year" $field = DllCall($hScriptAudioGenie,"wstr","ID3V1GetYearW") ; ID3V2 auslesen Case "APIC"; Cover ; -1 bei gefundenem Tag ; 0 bei nicht gefundenen Tag If $ext = "" Then Return SetError(1,0,1) $field = DllCall($hScriptAudioGenie,"short","ID3V2GetPictureFileW","wstr",$ext,"WORD","1") If $field[0] = -1 Then $field[0] = $ext Case Else; alle anderen ID3V2 Tags werden über $tag ausgelesen $field = DllCall($hScriptAudioGenie,"wstr","ID3V2GetTextFrameW","DWORD",_StringToInt($tag)) EndSwitch If IsArray($field) = 1 Then Return $field[0] Else Return $field EndIf EndFunc Func _AudioGenieSaveV1() Local $i = DllCall($hScriptAudioGenie,"short","ID3V1SaveChangesW") ConsoleWrite("Error Save " & @error & @CRLF) EndFunc Func _AudioGenieSaveV2() Local $i = DllCall($hScriptAudioGenie,"short","ID3V2SaveChangesW") ConsoleWrite("Error Save " & $i[0] & @CRLF) Return @error EndFunc Func _AudioGenieSaveTag($tag,$field,$ext = "") $tag = StringStripWS(StringStripCR($tag),3) $field = StringStripWS(StringStripCR($field),3) If Not $tag Then Return SetError(1,0,1) If Not $field Then Return SetError(2,0,1) Switch $tag ; ID3V1 Tags speichern Case "Title" DllCall($hScriptAudioGenie,"none","ID3V1SetTitleW","wstr",$field) ConsoleWrite("Error " & $tag & @error & @CRLF) Case "Artist" DllCall($hScriptAudioGenie,"none","ID3V1SetArtistW","wstr",$field) ConsoleWrite("Error " & $tag & @error & @CRLF) Case "Album" DllCall($hScriptAudioGenie,"none","ID3V1SetAlbumW","wstr",$field) ConsoleWrite("Error " & $tag & @error & @CRLF) Case "Track" DllCall($hScriptAudioGenie,"none","ID3V1SetTrackW","wstr",$field) ConsoleWrite("Error " & $tag & @error & @CRLF & $field) Case "Genre"; -> String führt zu Fehler, evtl die ID speichern mit ID3V1SetGenreIDW ;~ DllCall($hScriptAudioGenie,"wstr","ID3V1SetGenreW","wstr",$field) If $field = "" Then Return DllCall($hScriptAudioGenie,"none","ID3V1SetGenreW","wstr",$field) ConsoleWrite("Error " & $tag & @error & @CRLF) Case "Year" DllCall($hScriptAudioGenie,"none","ID3V1SetYearW","wstr",$field) ConsoleWrite("Error " & $tag & @error & @CRLF) ; ID3V2 Tags speichern Case "APIC" If $ext = "" Then Return SetError(3,2,1) $field = DllCall($hScriptAudioGenie,"short","ID3V2AddPictureFileW","wstr",$ext,"wstr","","WORD","03","WORD","0") If $field[0] = -1 Then $field[0] = $ext Case Else; alle anderen Tags werden über $tag gespeichert $field = DllCall($hScriptAudioGenie,"wstr","ID3V2SetTextFrameW","DWORD",_StringToInt($tag),"wstr",$field) EndSwitch If Isarray($field) = 1 Then Return $field[0] Else Return $field EndIf EndFunc Func _AudioGenieSaveTagGetGenreID($field) If $field = "" Then Return SetError(1,0,1) Local $array[148] = ["Blues","Classic Rock","Country","Dance","Disco","Funk","Grunge","Hip-Hop","Jazz","Metal","New Age","Oldies","Other","Pop","R&B","Rap","Reggae","Rock","Techno","Industrial","Alternative","Ska","Death Metal","Pranks","Soundtrack","Euro-Techno","Ambient","Trip-Hop","Vocal","Jazz+Funk","Fusion","Trance","Classical","Instrumental","Acid","House","Game","Sound Clip","Gospel","Noise","AlternRock","Bass","Soul","Punk","Space","Meditative","Instrumental Pop","Instrumental Rock","Ethnic","Gothic","Darkwave","Techno-Industrial","Electronic","Pop-Folk","Eurodance","Dream","Southern Rock","Comedy","Cult","Gangsta","Top","Christian Rap","Pop & Funk","Jungle","Native American","Cabaret","New Wave","Psychedelic","Rave","Showtunes","Trailer","Lo-Fi","Tribal","Acid Punk","Acid Jazz","Polka","Retro","Musical","Rock & Roll","Hard Rock","Folk","Folk-Rock","National Folk","Swing","Fast Fusion","Bebob","Latin","Revival","Celtic","Bluegrass","Avantgarde","Gothic Rock","Progressive Rock","Psychedelic Rock","Symphonic Rock","Slow Rock","Big Band","Chorus","Easy Listening","Acoustic","Humour","Speech","Chanson","Opera","Chamber Music","Sonata","Symphony","Booty Bass","Primus","Porn Groove","Satire","Slow Jam","Club","Tango","Samba","Folklore","Ballad","Power Ballad","Rhythmic Soul","Freestyle","Duet","Punk Rock","Drum Solo","A capella","Euro-House","Dance Hall","Goa","Drum & Bass","Club-House","Hardcore","Terror","Indie","BritPop","Negerpunk","Polsk Punk","Beat","Christian Gangsta Rap","Heavy Metal","Black Metal","Crossover","Contemporary Christian","Christian Rock","Merengue","Salsa","Trash Metal","Anime","JPop","Synthpop"] Local $int = _ArraySearch($array,$field,0,0,1) If $int = -1 Then Return SetError(2,0,1) $int += 1 Return $int EndFunc Func _AudioGenieReadBitrate() Local $result = DllCall($hScriptAudioGenie,"BOOL","AUDIOGetBitrateW") Return $result[0] EndFunc Func _AudioGenieReadSamplerate() Local $result = DllCall($hScriptAudioGenie,"BOOL","AUDIOGetSampleRateW") Return $result[0] EndFunc Func _AudioGenieReadChannel() Local $result = DllCall($hScriptAudioGenie,"wstr","AUDIOGetChannelModeW") Return $result[0] EndFunc Func _AudioGenieReadVersion() Local $result = DllCall($hScriptAudioGenie,"wstr","AUDIOGetVersionW") Return $result[0] EndFunc Func _AudioGenieReadDuration() Local $result = DllCall($hScriptAudioGenie,"float","AUDIOGetDurationW") $return = Floor($result[0]) Return $return EndFunc
  11. Oh... bless me. That really made a difference. i changed it into "none" from "wstr" and it went pretty fast to success. Thanks for helping me out here. Gotta read more careful on the Docs (audiograbber and autoit) So the Function DllCall is expecting a return value that isnt provided by (ID3V1SetTitleW) and crashes? Greetings SirWayNe.
  12. I am referring to change the Track. I can change the Title the way i want it to be, because i am using the String like DllCall($dll,"wstr","ID3V1SetTitleW","wstr","SomeArtist") -> works And for the Title i use a Number like this: DllCall($dll,"wstr","ID3V1SetTitleW","wstr","3") -> does not work DllCall($dll,"wstr","ID3V1SetTitleW","wstr","SomeString") -> doesnt crash AutoIt, but wont save it to the Audio File, Audio FIle only takes a number 0-255 (Read on ID3V1 Tags, Track takes 2 bytes in total = 255) same Parameter type: wstr.
  13. Im sorry. providing this link with Docs now http://sourceforge.net/projects/audiogenie/files/V2.0.4.0/doc/
  14. Hey, AutoIt Version: 3.3.8.1 i am using AudioGenie3.dll to get some information about my audio files, currently *.mp3. http://sourceforge.net/projects/audiogenie/ Im getting used to use DllCall and in using different variable types, but i cannot solve this problem: Local $test = "3" Local $test2 = "chemicals1" Local $dll = DllOpen("AudioGenie3.dll") If @error Then ConsoleWrite("DllOpen - " & $dll & " - Error: " & @error & @CRLF) Local $file = "9 - Chemicals.mp3" ; Set Current File, used in later Functions by AudioGenie3.dll $aAudioFile = DllCall($dll,"WORD","AUDIOAnalyzeFileW","wstr",$file) If @error Then ConsoleWrite("Error - Analyze - " & @error & @CRLF) ; Set V1 Track DllCall($dll,"wstr","ID3V1SetTrackW","wstr",$test) If @error Then ConsoleWrite("Error - V1SetTrack - " & @error & @CRLF) ; Set V1 Title DllCall($dll,"wstr","ID3V1SetTitleW","wstr",$test2) If @error Then ConsoleWrite("Error - V1SetTitle - " & @error & @CRLF) ; Check File if Saving worked Local $field1 = DllCall($dll,"wstr","ID3V1GetTitleW") Local $field2 = DllCall($dll,"wstr","ID3V1GetTrackW") ConsoleWrite("Title: " & $field1[0] & @CRLF) ConsoleWrite("Track: " & $field2[0] & @CRLF) ; close Dll DllClose($dll) I can set the Title to everything i want. But if i want to only set it to a number like: Local $test = "3" then AutoIt crashes and exits with exitcode 1073741819. It seems like DllCall cannot deal with the combination of "wstr" and "3". The Function in AudioGenie3.dll needs this Parameter: ID3V1SetTrackW(LPCWSTR myTrack) Can anyone explain that problem to me and maybe solve it? Greetings SirWayNe
×
×
  • Create New...