Help to generate QR Code (1 Viewer)

lookforsmt

Registered User.
Local time
Tomorrow, 02:32
Joined
Dec 26, 2011
Messages
672
HI! all, I am trying to find free QR code to print in Access, but i am not able to find one.
i have come across the below link, but unfortunate the report available in the attached db does not display any QR coded report. If anyone can assist me in this pls, thanks
Code:
https://access-programmers.co.uk/forums/showthread.php?t=287915
 

June7

AWF VIP
Local time
Today, 14:32
Joined
Mar 9, 2014
Messages
5,470
Are you able to get the code to create a QR image file? If so, how did you get the app to work? The report is set up with an Image control. Use Image control to display QR image. The Image control has ControlSource property that can be bound to an Attachment type field or can be an expression that refers to external file path. It appears code behind the report is supposed to save image from Excel sheet to external file and then load that file to Image control.
 
Last edited:

lookforsmt

Registered User.
Local time
Tomorrow, 02:32
Joined
Dec 26, 2011
Messages
672
HI!
i will try and answer the questions put

Are you able to get the code to create a QR image file? If so, how did you get the app to work? Where is the image saved?
I have only downloaded the db from the thread and saved it in my laptop. I tried clicking on generate by inputting some text, but got below error

"Run-time 462, The remote server machine does not exist or is unavailable"

I have saved the excel in the same folder of db
C:\Users\lookforsmt\Downloads\QR CODE FINAL NEW ECC CALC DROP BOX

The report is set up with an Image control. Use Image control to display QR image. The Image control has ControlSource property that can be bound to an Attachment type field or can be an expression that refers to external file path. It appears code behind the report is setting Image control to file path.

Is there a reference that i need to take care?

Thanks
 

lookforsmt

Registered User.
Local time
Tomorrow, 02:32
Joined
Dec 26, 2011
Messages
672
Thanks Jdraw, where can i can download the 2D Font Package free of cost
 

jdraw

Super Moderator
Staff member
Local time
Today, 18:32
Joined
Jan 23, 2006
Messages
15,379
I have no idea at the moment. I wasn't aware of what a QR code was--so I used Google and found a definition and then a link to usage with MS Access.
Google is your best choice at the moment.
 

lookforsmt

Registered User.
Local time
Tomorrow, 02:32
Joined
Dec 26, 2011
Messages
672
i was looking for help in the forum if there is a way to generate the QR code in Access. I guess the link shared initially looks like there is a way, i am trying to apply that in my project and if anyone can help me.
Thanks
 

arnelgp

..forever waiting... waiting for jellybean!
Local time
Tomorrow, 06:32
Joined
May 7, 2009
Messages
19,237
Zip your db and ill help you.
 

lookforsmt

Registered User.
Local time
Tomorrow, 02:32
Joined
Dec 26, 2011
Messages
672
Thanks Arnelgp Sir for your response, however, i had copied the same db from the link posted in post #1 which you had provided to one of the user in 2016.

Honestly i have not made any db. I am trying to take the QR code so i can apply that in my project.

i want to make a small inventory application for a small grocery/mini supermarket. Not really fancy but a small with minimum controls. But not sure how to go about it. I am searching through the net for a start.

QR codes was one of the idea to automate the inventory process.
If you can guide me with any sample if have come across.

Thanks
 

jdraw

Super Moderator
Staff member
Local time
Today, 18:32
Joined
Jan 23, 2006
Messages
15,379
Search the forum ( or go beyond with Google generally) and look for Inventory or Stock Management or Stock Control for more info on inventory and the underlying processes involved.

Try this in google
using qr codes with MS Access example

Inventory is not trivial. Do your analysis and get your business facts identified and tested.
Don't be too quick to jump into a physical database. Design is key.
You seemed fixed on QR code --and that may be the appropriate approach to coding, but there is a lot more to inventory.

Here is a 26 minute video by Software Matters that will give you more detail on developing such an inventory system.

Good luck
 

June7

AWF VIP
Local time
Today, 14:32
Joined
Mar 9, 2014
Messages
5,470
Sheet12 (PictureChart) of the worksheet has a path string of "C:\Users\arnelgp\Documents\QRCode4.jpeg" in cell A1. Changed that path and file type to bmp. After Excel is extracted and saved, I disable code that extracts, saves, deletes the Excel file. Code runs without error but no image is created.

How would the workbook be used on its own to generate QR code? I see 6 command buttons in it. The only instructions I see are "COMPLETED CALCULATIONS. Go to Sheet 'QR Symbol' and click the COMMAND BUTTON on that sheet. Then scan the QR Code." on sheet Input. Why would I scan a code? I changed text in the textbox in Excel and clicked each button. I do see the pattern is changed on sheet QRSymbol but the image on sheet PictureChart is unchanged and no image in folder. Oh, and the above instruction on sheet Input is deleted.

I tried to view VBA code in the workbook but requires a password.
 
Last edited:

MrHans

Registered User
Local time
Tomorrow, 00:32
Joined
Jul 27, 2015
Messages
147
Last edited:

arnelgp

..forever waiting... waiting for jellybean!
Local time
Tomorrow, 06:32
Joined
May 7, 2009
Messages
19,237
I am sorry put the qrcode can only be generated in form and in print preview.
 

Attachments

  • xlQRCode.accdb
    836 KB · Views: 1,666

June7

AWF VIP
Local time
Today, 14:32
Joined
Mar 9, 2014
Messages
5,470
Is that file different from the one in other thread? Because it does not work, as described in my post 11.
 

arnelgp

..forever waiting... waiting for jellybean!
Local time
Tomorrow, 06:32
Joined
May 7, 2009
Messages
19,237
yes. It is saving the image now to the user's temp folder. See the code of qrgenerator.
 

June7

AWF VIP
Local time
Today, 14:32
Joined
Mar 9, 2014
Messages
5,470
Did you mean modQRGenerator module in Access? What should I see?

Nope, not working any different from the other. Code looks the same. I get same errors I got before the described edits. But now those edits don't do any good. Errors on .Sheets(12).qrtopic (CopyPicture method of Range class failed), I was able to get past that before, but not now. Undid the edits, still get same error.

Here is something weird. I added line to set Excel visible right after calling genPictPath() and then I don't get error. Also still don't get a QRcode file created.

About ready to give up.
 
Last edited:

isladogs

MVP / VIP
Local time
Today, 23:32
Joined
Jan 14, 2017
Messages
18,217
I've just tried each of the versions of xlQRCode.accdb in both this and the other thread reference in post #1.
I'm getting exactly the same errors as June7

I've checked & the Excel file QRCode.xlsm has been created in my Temp folder but the QR code isn't available in the Access form or report

The first time I get this:


The next time I get


On reopening I get error 70 - permission denied on the Kill (strFile) line. This happens because as the xlsm file isn't closed when Access is closed

I've changed all references to the Temp folder to use CurrentProject.Path instead so its easier to find the Excel file.
I've also updated cell A1 on Sheet(12) accordingly. No change - it still errors.

The odd thing is I remember trying this when it was originally posted & IIRC it used to work
 

Attachments

  • Capture1.PNG
    Capture1.PNG
    3 KB · Views: 2,840
  • Capture2.PNG
    Capture2.PNG
    2.5 KB · Views: 2,828

June7

AWF VIP
Local time
Today, 14:32
Joined
Mar 9, 2014
Messages
5,470
I find that the cells on sheet QRSymbol are changed according to the text I input on Access form. So I tried to develop code in Access that would run the two buttons in Excel that get to that point and then convert the cells to bitmap. Still errors on CopyPicture method.

.Sheets(2).Range("B2:V22").CopyPicture Appearance:=xlScreen, Format:=xlBitmap

If that worked, next step would be to figure out how to define the cell range because it changes depending on the input text.
 

arnelgp

..forever waiting... waiting for jellybean!
Local time
Tomorrow, 06:32
Joined
May 7, 2009
Messages
19,237
Im not getting errors. I am using A2016.
 

June7

AWF VIP
Local time
Today, 14:32
Joined
Mar 9, 2014
Messages
5,470
Well, I can get the CopyPicture method to work directly in Excel VBA but calling from Access bombs. I am using Office 2010. No way I am going to try recreating the QRcode creation procedure in the downloaded Excel.
 

Users who are viewing this thread

Top Bottom