Scott Posted May 8, 2023 Share Posted May 8, 2023 Hello, I am trying to create a QR Code for the back of a business card that will create contact information for an iPhone or Android. The built in rules do not carry enough information, leaving out title and department for example. I can colorize a MeCard output, but I cannot customize the fields, so it will not produce the title and some other stuff the client wants. When I try VCard, I cannot colorize the barcode, but I can get the fields I need. Here is my code... // vCard format // http://en.wikipedia.org/wiki/VCard // Note that support for vCard may be more limited than for MECARD, // and that vCard requires more data to be encoded, resulting in a denser barcode. var foreColor = "Red"; // this is not working var info = { N: Field("LastName") + ';' + Field("FirstName") + ';' + Field("MiddleName") + ';;', FN: Field("FirstName") + ' ' + Field("MiddleName") + ' ' + Field("LastName"), DEPT: Field("Dept"), ORG: Field("Company"), TITLE: Field("Title"), "EMAIL;type=INTERNET;type=WORK": Field("Email"), "TEL;type=CELL": Field("Cell"), "TEL;type=WORK": Field("Phone1"), "ADR;type=WORK": ";;" + Field("Address1") + ';' + Field("City") + ';' + Field("State") + ';' + Field("ZIP"), "URL;type=WORK": Field("Website"), } var result = ["BEGIN:VCARD", "VERSION:3.0"]; for (var label in info) { if (info[label]) result.push(label + ":" + info[label]); } result.push("END:VCARD"); return MakeQRBarcodeGraphic(result.join(Chr(13) + Chr(10)), foreColor); Can anyone help? Quote Link to comment Share on other sites More sharing options...
Dan Korn Posted May 10, 2023 Share Posted May 10, 2023 Change the last line to: return MakeQRBarcodeGraphicColor(result.join(Chr(13) + Chr(10)), foreColor); You must be on an older version of FusionPro. As of FusionPro VDP version 10, the QR VCard Form (XML Template) rule supports colors. Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.