Popular Post BugFix Posted December 21, 2012 Popular Post Share Posted December 21, 2012 Inspired by i've made a little tool for simply QR-Code creation with all required stuff in the au3-file (dll included as binary string, because that, the au3 has 447kB and can not attached directly).By testing on my system the max. possible count of chars to encode are: $__QR_MAX_LEN = 3049. But on other systems it was round 2000 chars.Also on another computer the creation of QR-Code fails generally. But ist was the same system that i have (Win 7, 64 bit). I do not know the reason for this behavior.Would be interesting, how this script runs on other machines.You can store the QR-Image as *.png and/or *.bmp and/or copy it to clipboard.Here you can download QR_Creator.au3Have a look: JiBe, mLipok, Colduction and 2 others 5 Best Regards BugFix Link to comment Share on other sites More sharing options...
guinness Posted December 21, 2012 Share Posted December 21, 2012 I get an error on line 320 with $return[0] not actually being an array. 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...
BugFix Posted December 21, 2012 Author Share Posted December 21, 2012 I get an error on line 320 with $return[0] not actually being an array. OK, that means, that the dll-call has failed. I've added an failure handling that gives a message with the detected error from dll call. Also I've changed the dll using - instead file name, call with dll handle. Please try again. Best Regards BugFix Link to comment Share on other sites More sharing options...
guinness Posted December 21, 2012 Share Posted December 21, 2012 I worked it out the second I posted that bug report. Add the following to the top of the script. #AutoIt3Wrapper_UseX64=N Also you don't need #include-once as this isn't a UDF. 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...
BugFix Posted December 21, 2012 Author Share Posted December 21, 2012 Thanks for your efforts. I have included your advice now. Best Regards BugFix Link to comment Share on other sites More sharing options...
KaFu Posted December 21, 2012 Share Posted December 21, 2012 Looks really nice , downloaded your version and the source for the dll and took a look.... Maybe better use the unicode functions DllCall($hDll, "none", "GeneratePNGW", "wstr", $sPath & $_sImageName & ".png", "wstr", $_sText, "int", 4, "int", 2) GeneratePNGW(LPWSTR fileName, LPWSTR text, int Margin, int PixelSize, QRecLevel level); Did not find out though how to set last (optional) parameter TErrorCorretion which defaults to 0: Global Const $QR_ECLEVEL_L = 0 ; lowest Global Const $QR_ECLEVEL_M = 1 Global Const $QR_ECLEVEL_Q = 2 Global Const $QR_ECLEVEL_H = 3 ; highest Also there's a function called "DestroyBuffer", maybe a good idea to call before returning? No quite sure though ... DllCall($hDll, "none", "DestroyBuffer") at least does not crash the script ... ; qrencode.h - "Otherwise, all of non-alphanumeric characters are encoded as 8 bit data." ; http://en.wikipedia.org/wiki/QR_code#Storage ; max. characters = 2,953 ; possible characters, default encoding = ISO 8859-1 OS: Win10-22H2 - 64bit - German, AutoIt Version: 3.3.16.1, AutoIt Editor: SciTE, Website: https://funk.eu AMT - Auto-Movie-Thumbnailer (2024-Oct-13) BIC - Batch-Image-Cropper (2023-Apr-01) COP - Color Picker (2009-May-21) DCS - Dynamic Cursor Selector (2024-Oct-13) HMW - Hide my Windows (2024-Oct-19) HRC - HotKey Resolution Changer (2012-May-16) ICU - Icon Configuration Utility (2018-Sep-16) SMF - Search my Files (2024-Oct-20) - THE file info and duplicates search tool SSD - Set Sound Device (2017-Sep-16) Link to comment Share on other sites More sharing options...
BugFix Posted December 21, 2012 Author Share Posted December 21, 2012 Thanks for your reply. Now I have something to do during the Christmas season. Best Regards BugFix Link to comment Share on other sites More sharing options...
BugFix Posted December 23, 2012 Author Share Posted December 23, 2012 Here my results:The parameter for ErrorCorrectionLevel is only available in the quiricol64.dll. It makes no sense to me to use features that are not run under 32-bit. Therefore, I will omit this parameter.The function DestroyBuffer() is only needed for GetPNGW() / GetPNGA(). After call, the last parameter in this function contains the pointer to a buffer.(Thanks to Andy for his testing.) Best Regards BugFix Link to comment Share on other sites More sharing options...
joseLB Posted February 5, 2013 Share Posted February 5, 2013 Hi BugFix It´s working like a charm for me (win7 64 bits). It´s very fast..... thanks for sharing. But about reading qr-codes, do you hav any idea if it could be done in AU3? I mean, give it an image your software generated to interpret? I got a program, it reads perfectly your images (only do not read special chars like á, ã, etc.). But I think it´s a problem of that program. Thanks Jose Link to comment Share on other sites More sharing options...
BugFix Posted February 12, 2013 Author Share Posted February 12, 2013 Hi BugFixIt´s working like a charm for me (win7 64 bits). It´s very fast..... thanks for sharing.But about reading qr-codes, do you hav any idea if it could be done in AU3?I mean, give it an image your software generated to interpret?I got a program, it reads perfectly your images (only do not read special chars like á, ã, etc.). But I think it´s a problem of that program.ThanksJoseTake a look at this site: http://qrcode.sourceforge.jp/, may be that it helps. Best Regards BugFix Link to comment Share on other sites More sharing options...
wysocki Posted February 14, 2013 Share Posted February 14, 2013 This is pretty cool, but I'm trying to figure out just what to enter in the QR code. I got my phone to read plain text that I've created and to go to a web link by just entering the http:// stuff. But I've been looking for a while on the web for guidance about what goes into the code for other functions without much luck so far. Specifically, what's the syntax (as it relates to your script) for the various functions like what's needed to have it generate a vCard or meCard, or to automatically dial a phone number. Can you recommend any sites that have this kind of info? Link to comment Share on other sites More sharing options...
BrewManNH Posted February 14, 2013 Share Posted February 14, 2013 Try just entering a phone number for the code. My phone app prompts me to dial the phone number, when I scan a code with a phone number in it.Try this page for an examplehttp://yourfreeqrcode.com/phone.php If I posted any code, assume that code was written using the latest release version unless stated otherwise. Also, if it doesn't work on XP I can't help with that because I don't have access to XP, and I'm not going to.Give a programmer the correct code and he can do his work for a day. Teach a programmer to debug and he can do his work for a lifetime - by Chirag GudeHow to ask questions the smart way! I hereby grant any person the right to use any code I post, that I am the original author of, on the autoitscript.com forums, unless I've specifically stated otherwise in the code or the thread post. If you do use my code all I ask, as a courtesy, is to make note of where you got it from. Back up and restore Windows user files _Array.au3 - Modified array functions that include support for 2D arrays. - ColorChooser - An add-on for SciTE that pops up a color dialog so you can select and paste a color code into a script. - Customizable Splashscreen GUI w/Progress Bar - Create a custom "splash screen" GUI with a progress bar and custom label. - _FileGetProperty - Retrieve the properties of a file - SciTE Toolbar - A toolbar demo for use with the SciTE editor - GUIRegisterMsg demo - Demo script to show how to use the Windows messages to interact with controls and your GUI. - Latin Square password generator Link to comment Share on other sites More sharing options...
maddogmcree Posted April 25, 2013 Share Posted April 25, 2013 This is a way cool program but i have a question......... I don't have any experience what so ever with scripting but i could use the qr creator as a part of a filemaker database i am developing for the last 2 years to generate te qr code for phone numbers, can somebody tel me if the qr code generator accepts command line parameters? and so what is the syntax, I would like to generate the code from filemaker and paste it back into filemaker without an intermediate step so fully automated. And if it doesnt accept command line parameters maybe someone can adapt it so that is does. thank you for your effort. Sorry for my bad english ( im dutch so please foregive me ) Link to comment Share on other sites More sharing options...
BugFix Posted April 26, 2013 Author Share Posted April 26, 2013 As commandline tool try this version (not tested). #AutoIt3Wrapper_UseX64=N ; == Syntax: "QR_Creator_CmdLine.exe sOutputPath.type sText" ; == i.e.: '"C:\Program Files (x86)\QR_Creator_CmdLine.exe" "C:\Users\USER\QR_new.bmp" "Text to encode"' -- output type *.bmp or *.png If $CmdLine[0] <> 2 Then Exit OnAutoItExitRegister("_DelBinaryTempFiles") Global $sDllQR = @ScriptDir & "\quricol32.dll" _CreateDll() Func _CreateDll() Local $bData ; string with binary data from: quricol32.dll $bData &= "0x4D5A90000300000004000000FFFF0000B80000000000000.........." ;.... ;... Local $hFileOut = FileOpen($sDllQR, 2+8+16) FileWrite($hFileOut, Binary($bData)) FileClose($hFileOut) EndFunc Func _DelBinaryTempFiles() If FileExists($sDllQR) Then FileDelete($sDllQR) EndFunc Global $sPathOut = $CmdLine[1], $sType = StringRight($sPathOut, 3), $sText = $CmdLine[2] Global $hDll = DllOpen($sDllQR) If $sType = 'bmp' Then DllCall($hDll, "none", "GenerateBMPW", "str", $sPathOut, "str", $sText, "int", 4, "int", 2) Else DllCall($hDll, "none", "GeneratePNGW", "str", $sPathOut, "str", $sText, "int", 4, "int", 2) EndIf DllClose($hDll) Best Regards BugFix Link to comment Share on other sites More sharing options...
Damein Posted October 16, 2014 Share Posted October 16, 2014 I know this is a bit old. But I wanted to utilize QR in a program I'm going to attempt to create. Now the creation I can do through AutoIt through this script (Thanks for that!) But I would also like to be able to decode the same image in AutoIt. But I'm not sure how to do that ^^; Anyone got some tips or already done this? Thanks! Most recent sig. I made Quick Launcher W/ Profiles Topic Movie Database Topic & Website | LiveStreamer Pro Website | YouTube Stand-Alone Playlist Manager: Topic | Weather Desktop Widget: Topic | Flash Memory Game: Topic | Volume Control With Mouse / iTunes Hotkeys: Topic | Weather program: Topic | Paws & Tales radio drama podcast mini-player: Topic | Quick Math Calculations: Topic Link to comment Share on other sites More sharing options...
Adams Posted April 14, 2015 Share Posted April 14, 2015 from some time, an error occur: "_WinAPI_CopyImage, duplicate function name". What is changed? Now the function "_WinAPI_CopyImage" is in WinAPIGdi.au3, included in GDIPlus.au3, included in QR_Creator.au3. Before? Adams Link to comment Share on other sites More sharing options...
argumentum Posted April 15, 2015 Share Posted April 15, 2015 from some time, an error occur: "_WinAPI_CopyImage, duplicate function name". just delete the function "_WinAPI_CopyImage", the code is old. I you remove it, it will run just fine. Follow the link to my code contribution ( and other things too ). FAQ - Please Read Before Posting. Link to comment Share on other sites More sharing options...
GhostLine Posted April 17, 2015 Share Posted April 17, 2015 That's great ! I was looking for this for Eon Link to comment Share on other sites More sharing options...
Skysnake Posted September 1, 2017 Share Posted September 1, 2017 Works like a charm I found this scanner produced best results - including returning plain text https://www.scan.me/ Skysnake Why is the snake in the sky? Link to comment Share on other sites More sharing options...
nikink Posted September 27, 2017 Share Posted September 27, 2017 Is there a way to make the generated QR image bigger? If I take the current size and enlarge it, it gets quite blurry around the edges. 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