Σάββατο 15 Οκτωβρίου 2022

Revision 10 Version 11 - QRCODE

I found https://github.com/wqweto/VbQRCodegen/blob/master/src/mdQRCodegen.bas from vbforums.com user wqweto. So I bound this module to M2000 code.

simple use (we use 6000 width in twips, and height automatic calculated from ratio W/H):

Img1=Image("http://www.vbforums.com")
Move 3000, 3000
Image img1, 6000

All graphic statements can be used in console (any layer), on printer layer, on user forms layer, on image control on user forms. 

The Img1 is a buffer object which hold emf file of the QRcode (we can save it)

Open "vbforumsQrcode.emf" for Output as #f
Put #f, Img1, 1
close #f

Also we can copy the image to clipboard as emf

Clipboard img1 as "emf"


This is from Help Image( statement in M2000 console

Img1=Image("http://www.vbforums.com")

// color  0 - 15 ή color(R, G, B) R, G, B: 0 - 255 or #FF0077 (html color)

Img1=Image("http://www.vbforums.com", color(255, 0, 128))

// Error tolerate level

 0 ' The QR Code can tolerate about  7% erroneous codewords

 1 ' The QR Code can tolerate about 15% erroneous codewords

 2 ' The QR Code can tolerate about 25% erroneous codewords

 3 ' The QR Code can tolerate about 30% erroneous codewords

Img1=Image("http://www.vbforums.com", color(255, 0, 128), 3)

Img1=Image("http://www.vbforums.com", , 3)




Δεν υπάρχουν σχόλια:

Δημοσίευση σχολίου

You can feel free to write any suggestion, or idea on the subject.