qr.flutter icon indicating copy to clipboard operation
qr.flutter copied to clipboard

not able to generate multiple textfiled to qr code generator please suggest

Open appsgamedev opened this issue 2 years ago • 7 comments

Is your feature request related to a problem? Please describe. A clear and concise description of what the problem is. Ex. I'm always frustrated when [...]

Describe the solution you'd like A clear and concise description of what you want to happen.

Describe alternatives you've considered A clear and concise description of any alternative solutions or features you've considered.

Additional context Add any other context or screenshots about the feature request here.

appsgamedev avatar May 12 '22 14:05 appsgamedev

What is the purpose here, to combine all the texts and create a qr?

aydemiromer avatar Jun 01 '22 09:06 aydemiromer

show this image = https://we.tl/t-plpmnNsJ4X https://www.the-qrcode-generator.com.

i want make this type multiple text-filed data in single QR code. my e commerce app use for delivery boy access multiple data by QR code.

If you want to do the same here, process all textfields with the same controller. Here, the structure is reset when switching to a different request, you can clear the controller in the selection.

aydemiromer avatar Jun 01 '22 09:06 aydemiromer

can you give me example demo code file please help.

late final TextEditingController _textController;

String qrText = ''; @override void initState() { super.initState(); _textController = TextEditingController(text: qrText); }

SizedBox _qr() { return SizedBox( height: context.height * 0.4, child: Center( child: QrImage( data: qrText, version: QrVersions.auto, size: 200, gapless: false, ), ), ); } Padding myTextFormFieldUrl() { return Padding( padding: const EdgeInsets.all(8.0), child: TextFormField( controller: _textController, onChanged: (value) => setState(() { qrText = value; }), decoration: InputDecoration( border: InputBorder.none, labelText: LocaleKeys.home_page_text_field_label_url.tr(), ), ), ); }

You can use one more time textform with controller

aydemiromer avatar Jun 01 '22 17:06 aydemiromer

Please suggest multiple text-filed data in single barcode.

This is a Stack Overflow question

lukepighetti avatar Jun 06 '22 17:06 lukepighetti