Forum Discussion

JulieMeeker's avatar
JulieMeeker
Qrew Trainee
2 years ago

Generating QR Code with URL to record

I am trying to generate a QR code that will open a record in Quickbase.  I have a Formula URL field that generates the URL:

URLRoot() & "db/" & [_DBID_ASSETS] & "?a=dr&key=" & URLEncode([Cart ID#])

I have a Formula Rich Text field that generates the QR Code:

"<img src=\"http://chart.apis.google.com/chart?cht=qr&chs=100x100&chl="&[Record URL]
& "\"\"/>"

When I scan the QR Code it is dropping off the &key= part of the URL.  Is there something wrong with my Rich Text Formula?
The URL field works perfectly!

------------------------------
Julie Meeker
------------------------------

5 Replies

  • I'm using this syntax

    var text URL = URLRoot() & "db/" & [_DBID_ASSETS] & "?a=dr&key=" & URLEncode([Cart ID#]);

    "<img src='http://chart.googleapis.com/chart?cht=qr&chs=240x240&chl="
    & URLEncode($URL)& "'>"

    ------------------------------
    Mark Shnier (Your Quickbase Coach)
    mark.shnier@gmail.com
    ------------------------------
    • JulieMeeker's avatar
      JulieMeeker
      Qrew Trainee
      As always Mark, this worked perfectly!  You are amazing!

      ------------------------------
      Julie Meeker
      ------------------------------
    • BaileyDesormeau's avatar
      BaileyDesormeau
      Qrew Member

      Hi Mark,

      I am trying to have a qr code generated and scannable. Right now when I put the QR code field in the main form it is showing as broken. Here is my formula rich text: 

      var text URL = URLRoot() & "db/" & Dbid() & "?a=dr&rid=" & [BOL ID#];

      "<img src=\"https://chart.googleapis.com/chart?cht=qr&chs=240x240&chl="
      & URLEncode($URL)
      & "\"\"/>"

      Also here is a snippet of what the field looks like in a form, shouldn't the qr code be visible here?

      Thanks so much,
      Bailey Desormeaux

      • MikeTamoush's avatar
        MikeTamoush
        Qrew Commander

        Is BOL ID# your key field? If you switched the key field from [Record iD#], you will need to use the syntax Mark posted ("...&key=" & URLEncode([BOL ID#]))