Page 2 of 2 FirstFirst 12
Results 41 to 70 of 70

Thread: [VB6/VBA] QR Code generator library

  1. #41

    Thread Starter
    PowerPoster wqweto's Avatar
    Join Date
    May 2011
    Location
    Sofia, Bulgaria
    Posts
    5,227

    Re: [VB6/VBA] QR Code generator library

    The bitmap produced *is* a DIB actually. No idea what's going on, probably some incompatibility that I cannot debug as I don't have Office 2000.

    If someone fixes this problem they are free to send a Pull Request to the repo, it will be merged immediately.

    cheers,
    </wqw>

  2. #42
    PowerPoster
    Join Date
    Jan 2020
    Posts
    3,783

    Re: [VB6/VBA] QR Code generator library

    put text to get qrocde err,why?
    Code:
    text1.text="http://www.baidu.com/34134123412341234341234123412341341341343313123131313k1k3k1k3k1k3k1k3k1k3k1k31k13k13k1"

  3. #43

  4. #44
    New Member
    Join Date
    Nov 2022
    Posts
    2

    Re: [VB6/VBA] QR Code generator library

    Border:

    In nayuki's live demo, there is an option to set the border (width) - measured in QR code 'bits' as the unit.
    I've looked through your implementation for 'border'. But can't find any reference or setting.

    Can you give me any hints as to passing a parameter to set the border width.
    Thx, Alan

  5. #45

    Thread Starter
    PowerPoster wqweto's Avatar
    Join Date
    May 2011
    Location
    Sofia, Bulgaria
    Posts
    5,227

    Re: [VB6/VBA] QR Code generator library

    Quote Originally Posted by Alan Lamb View Post
    Border:

    In nayuki's live demo, there is an option to set the border (width) - measured in QR code 'bits' as the unit.
    I've looked through your implementation for 'border'. But can't find any reference or setting.

    Can you give me any hints as to passing a parameter to set the border width.
    Thx, Alan
    No, this is not implemented. You have to manually place the QR Code so that there is enough margin as you deem proper.

    Most scanners are able to read QR Codes (and barcodes) with no margins at all so the standard requirements for empty borders around the image are optional in practice and mostly not heeded by anyone printing QR Codes/barcodes on paper.

    cheers,
    </wqw>

  6. #46
    New Member
    Join Date
    Nov 2023
    Posts
    5

    Re: [VB6/VBA] QR Code generator library

    Hi,
    I have a little problem with this QR code generator library. I'm using Access 2016 (I think it's use VB 7.1) and can not compile the code, always show this error message: Compile error: User-definied type not definied.
    What can I do?
    Attachment 189235

  7. #47

    Thread Starter
    PowerPoster wqweto's Avatar
    Join Date
    May 2011
    Location
    Sofia, Bulgaria
    Posts
    5,227

    Re: [VB6/VBA] QR Code generator library

    Quote Originally Posted by Scannia View Post
    What can I do?
    Hi,

    You can start by sharing some more info about this error.

    Which line number is this error at? Is you Office installation 32-bit or 64-bit version?

    cheers,
    </wqw>

  8. #48
    New Member
    Join Date
    Nov 2023
    Posts
    5

    Re: [VB6/VBA] QR Code generator library

    Quote Originally Posted by wqweto View Post
    Hi,

    You can start by sharing some more info about this error.

    Which line number is this error at? Is you Office installation 32-bit or 64-bit version?

    cheers,
    </wqw>
    Access 2016 64 bit version, on Windows 10 22H2.
    As you see on the attached screenshot, the Editor select from the line 169 to 177 the Public Function QRCodegenBarcode() segment.
    Name:  Error.jpg
Views: 655
Size:  36.3 KB

  9. #49

    Thread Starter
    PowerPoster wqweto's Avatar
    Join Date
    May 2011
    Location
    Sofia, Bulgaria
    Posts
    5,227

    Re: [VB6/VBA] QR Code generator library

    Weird! Your project is probably missing reference to "OLE Automation".

    Open Tools->References and make sure "OLE Automation" is checked in the available references list.

    cheers,
    </wqw>

  10. #50
    New Member
    Join Date
    Nov 2023
    Posts
    5

    Re: [VB6/VBA] QR Code generator library

    Quote Originally Posted by wqweto View Post
    Weird! Your project is probably missing reference to "OLE Automation".

    Open Tools->References and make sure "OLE Automation" is checked in the available references list.

    cheers,
    </wqw>
    Yes, this OLE Automation was missing.
    Thank you!

  11. #51
    New Member
    Join Date
    Dec 2023
    Posts
    4

    Re: [VB6/VBA] QR Code generator library

    i have a problem in spain with special characters like ñ Ñ á é í ó ú ... I think i have to change utf-8 page, here

    Private Function pvToUtf8Array(sText As String) As Byte()
    Const CP_UTF8 As Long = 65001

    but i don't know the number

  12. #52

    Thread Starter
    PowerPoster wqweto's Avatar
    Join Date
    May 2011
    Location
    Sofia, Bulgaria
    Posts
    5,227

    Re: [VB6/VBA] QR Code generator library

    Can you upload/post here a generated QR barcode which contains problematic spanish special symbols?

  13. #53
    Addicted Member gilman's Avatar
    Join Date
    Jan 2017
    Location
    Bilbao
    Posts
    179

    Re: [VB6/VBA] QR Code generator library

    Quote Originally Posted by imasred View Post
    i have a problem in spain with special characters like ñ Ñ á é í ó ú ... I think i have to change utf-8 page, here

    Private Function pvToUtf8Array(sText As String) As Byte()
    Const CP_UTF8 As Long = 65001

    but i don't know the number
    I try using spanish chars, and works fine.

  14. #54
    New Member
    Join Date
    Dec 2023
    Posts
    4

    Re: [VB6/VBA] QR Code generator library

    Quote Originally Posted by wqweto View Post
    Can you upload/post here a generated QR barcode which contains problematic spanish special symbols?
    I think it is a problem with the regional configuration of my Windows. I'm trying to upload an image.


    I edit the post, sorry. My windows regional settings are ok, because all keys of my keyboard work correctly and I can type things like "camión español"
    Attached Images Attached Images  
    Last edited by imasred; Jan 8th, 2024 at 01:22 PM.

  15. #55
    PowerPoster techgnome's Avatar
    Join Date
    May 2002
    Posts
    34,563

    Re: [VB6/VBA] QR Code generator library

    When I san the code, I get "camión español" ... so something is working...

    -tg
    * I don't respond to private (PM) requests for help. It's not conducive to the general learning of others.*
    * I also don't respond to friend requests. Save a few bits and don't bother. I'll just end up rejecting anyways.*
    * How to get EFFECTIVE help: The Hitchhiker's Guide to Getting Help at VBF - Removing eels from your hovercraft *
    * How to Use Parameters * Create Disconnected ADO Recordset Clones * Set your VB6 ActiveX Compatibility * Get rid of those pesky VB Line Numbers * I swear I saved my data, where'd it run off to??? *

  16. #56
    New Member
    Join Date
    Dec 2023
    Posts
    4

    Red face Re: [VB6/VBA] QR Code generator library

    Quote Originally Posted by techgnome View Post
    When I san the code, I get "camión español" ... so something is working...

    -tg
    the problem was my phone. Sorry.
    Attached Images Attached Images  

  17. #57
    PowerPoster techgnome's Avatar
    Join Date
    May 2002
    Posts
    34,563

    Re: [VB6/VBA] QR Code generator library

    Font issue? That's ... wow... would not expect that to happen...

    -tg
    * I don't respond to private (PM) requests for help. It's not conducive to the general learning of others.*
    * I also don't respond to friend requests. Save a few bits and don't bother. I'll just end up rejecting anyways.*
    * How to get EFFECTIVE help: The Hitchhiker's Guide to Getting Help at VBF - Removing eels from your hovercraft *
    * How to Use Parameters * Create Disconnected ADO Recordset Clones * Set your VB6 ActiveX Compatibility * Get rid of those pesky VB Line Numbers * I swear I saved my data, where'd it run off to??? *

  18. #58
    New Member
    Join Date
    Dec 2023
    Posts
    4

    Re: [VB6/VBA] QR Code generator library

    Quote Originally Posted by techgnome View Post
    Font issue? That's ... wow... would not expect that to happen...

    -tg
    i don't know. I used the default QR reader from my new Xiaomi Redmi 12 and reads wrongly. But with any other free they read perfectly

    ... thank you

  19. #59
    Fanatic Member
    Join Date
    Aug 2016
    Posts
    608

    Re: [VB6/VBA] QR Code generator library

    Quote Originally Posted by imasred View Post
    i don't know. I used the default QR reader from my new Xiaomi Redmi 12 and reads wrongly. But with any other free they read perfectly

    ... thank you
    handphone also got Language setting, you try to change to prefer one.

  20. #60

    Thread Starter
    PowerPoster wqweto's Avatar
    Join Date
    May 2011
    Location
    Sofia, Bulgaria
    Posts
    5,227

    Re: [VB6/VBA] QR Code generator library

    Quote Originally Posted by imasred View Post
    the problem was my phone. Sorry.
    The QR reader you are using does not recognize UTF-8 encoding and switches to some crazy japanese kanji or whatever encoding QR code originally used. The fun fact is that QR codes *predate* UTF-8 so these cannot possible originally use UTF-8 and solve most of their enconding issue so they had to mess up with encoding which ended not so good and most reader implementations are needlessly complicated. Nowadays most everyone silently assumes input stream is proper UTF-8 encoded text unless explicitly configured to use kanji chartacter sets and whatever.

    Well, at least now you seen some kanji japanese letters which is got in place of spanish special characters :-)) This is not so common to see, an ordinary Unicode mess up ends up in some form of Chineese only :-))

    The problem is in the configuration of your phone's QR code reader, not in your phone per se. You can fix it but switching a setting to always use UTF-8 most probably, unfotunately specifics of where and what are not available here. . .

    cheers,
    </wqw>

  21. #61
    New Member
    Join Date
    Nov 2023
    Posts
    5

    Re: [VB6/VBA] QR Code generator library

    Hi,
    Is it possible to generate Datamatrix code with this program?

    thank you

  22. #62
    Addicted Member gilman's Avatar
    Join Date
    Jan 2017
    Location
    Bilbao
    Posts
    179

    Re: [VB6/VBA] QR Code generator library

    Quote Originally Posted by Scannia View Post
    Hi,
    Is it possible to generate Datamatrix code with this program?

    thank you
    I think this project only creates QR Codes, to create other type of BarCodes you can try the attached project, thats creates more code bars types, including DataMatrix.
    Attached Files Attached Files

  23. #63

    Thread Starter
    PowerPoster wqweto's Avatar
    Join Date
    May 2011
    Location
    Sofia, Bulgaria
    Posts
    5,227

    Re: [VB6/VBA] QR Code generator library

    Quote Originally Posted by gilman View Post
    I think this project only creates QR Codes, to create other type of BarCodes you can try the attached project, thats creates more code bars types, including DataMatrix.
    Btw, this sample uses ZXing library as an external dependacy which is a Java behemoth. The library can appraently produce QR Codes too among many other formats *and* its primary target is actually scanning barcodes it seems.

    cheers,
    </wqw>

  24. #64
    Addicted Member gilman's Avatar
    Join Date
    Jan 2017
    Location
    Bilbao
    Posts
    179

    Re: [VB6/VBA] QR Code generator library

    Quote Originally Posted by wqweto View Post
    Btw, this sample uses ZXing library as an external dependacy which is a Java behemoth. The library can appraently produce QR Codes too among many other formats *and* its primary target is actually scanning barcodes it seems.

    cheers,
    </wqw>
    Yes, and the sample also allows scan barcodes from files

  25. #65

    Thread Starter
    PowerPoster wqweto's Avatar
    Join Date
    May 2011
    Location
    Sofia, Bulgaria
    Posts
    5,227

    Re: [VB6/VBA] QR Code generator library

    Quote Originally Posted by gilman View Post
    Yes, and the sample also allows scan barcodes from files​
    Honestly hope that no one in his right mind decides it's a good idea to use a Java library for about anything and tirelessly search for replacement using *any* other technology (even .Net).

    This thread is about being and staying lean, using less code, particularly with small VBx modules, with no dependencies to produce usable and performant solutions.

    cheers,
    </wqw>

  26. #66
    Fanatic Member
    Join Date
    Jan 2015
    Posts
    599

    Re: [VB6/VBA] QR Code generator library

    I just posted in the codebank code Barcode & QRCode reader using ZXing

  27. #67
    New Member
    Join Date
    Nov 2023
    Posts
    5

    Re: [VB6/VBA] QR Code generator library

    Quote Originally Posted by gilman View Post
    I think this project only creates QR Codes, to create other type of BarCodes you can try the attached project, thats creates more code bars types, including DataMatrix.
    Thanks, but I can't use it in my Access 2016 database and yes, it's too big for me.

    I need searching another solution, which is "simple" VB6 code without any external DLL, ActiveX, etc.

    Thanks!

  28. #68
    New Member
    Join Date
    Mar 2024
    Posts
    5

    Re: [VB6/VBA] QR Code generator library

    hey all. beginner here. Tried to save the generated QRcode into a file
    SavePicture Image1.Picture, "c:\share\1.bmp"

    but when opened, the error says "file format not supported"? The file size saved is about 28kB though

    any help?

  29. #69

    Thread Starter
    PowerPoster wqweto's Avatar
    Join Date
    May 2011
    Location
    Sofia, Bulgaria
    Posts
    5,227

    Re: [VB6/VBA] QR Code generator library

    The QR barcode image is generated to a vector picture.

    Try using C:\Share\1.emf or 1.wmf for target filename.

  30. #70
    New Member
    Join Date
    Mar 2024
    Posts
    5

    Re: [VB6/VBA] QR Code generator library

    ok great. It's working now with 1.emf extension. Thanks so much!

Page 2 of 2 FirstFirst 12

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width