Seshu Vinay
Seshu Vinay

Reputation: 13588

QR Code scanning android

I am using Zxing Barcode scanner app to scan bar codes using

Intent intent = new Intent("com.google.zxing.client.android.SCAN");
intent.putExtra("SCAN_MODE", "QR_CODE_MODE");

startActivityForResult(intent, 0);

It works fine. I could get the result in onActivityResult. No problem. I dont want QRCode to be displayed. I mean I don't want to let the end user know the qr code string. But in the history available in the original barcode scanner app, it is showing up the list of QR's scanned. So, how do i make the QRStringfrom my app invisible in History

Upvotes: 3

Views: 2560

Answers (1)

user370305
user370305

Reputation: 109237

"SAVE_HISTORY" from package com.google.zxing.client.android.Scan;

 /**
     * Setting this to false will not save scanned codes in the history.
     */
    public static final String SAVE_HISTORY = "SAVE_HISTORY";

Then something like,

intent.putExtra("SAVE_HISTORY", false);

Try this and let me know what happen..

Upvotes: 2

Related Questions