Quantcast
Channel: ABAP Development
Viewing all articles
Browse latest Browse all 948

Step by step to create QRCode in ABAP Webdynpro

$
0
0


Step1 Create a new form interface in tcode SFP

clipboard1.png

Click tab "Interface",add a new attribute QRCODE_INPUT with type string for Form Interface - Import. This attribute is used to hold the content input by end user which will be used to generate QR code. Activate the interface.

clipboard2.png

Step2 Create a new form template in tcode SFP


Specify the interface you created in step1 as its interface:

clipboard3.png

In Context tab, drag the attribute QRCODE_INPUT to form Context:

clipboard4.png

Click tab "Layout", drag a QR Code control from Adobe Form Designer Object Library:

clipboard5.png

Specify its data binding from context attribute which we drag from form interface in step2:

clipboard6.png

activate the form template.

 

 

Step3 Create a new ABAP webdynpro

It has one text edit which allows end user to input some string which will be used to generate the QR code, a button to trigger the PDF generation, and an interactive form element to display the rendered PDF with QRCode.

 

clipboard7.png

Select the interactive form element, maintain the template source with ZPF_GRCODE we created in step2, choose Yes to let framework to generate the necessary context for us:

clipboard6.png

Bind the text edit to the automatically generated context attribute:

clipboard7.png

Test

 

 

type some test string and click Generate button, the generated QR code is displayed in the interactive form element.

clipboard8.png

and I can use the QRCode scanner installed in my cellphone to parse the QRCode successfully.

clipboard9.png


Viewing all articles
Browse latest Browse all 948

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>