Scan almost any barcode type with this super fast barcode scanner air native extension
Switch branches/tags
Nothing to show
Clone or download
Latest commit 2742e55 Dec 4, 2018
Type Name Latest commit message Commit time
Failed to load latest commit information.
AIR V3.4.7 Nov 18, 2018
barcodes added V3.0.0 Dec 29, 2015 V3.4.7 Nov 18, 2018 Update Dec 4, 2018 V3.4.6 Sep 26, 2018

Barcode ANE V3.4.7 (Android+iOS)

This ANE enables AS3 AIR developers, to easily use the native camera on device and scan for almost all different barcodes and get the result to their AIR project.

Supported barcodes:

  • UPCE
  • CODE39
  • EAN13
  • EAN8
  • CODE128
  • PDF417
  • QR
  • ITF14


find the latest asdoc for this ANE here.

Download demo ANE

AIR Usage

For the complete AS3 code usage, see the demo project here.

import com.myflashlab.air.extensions.barcode.*;

var _ex:Barcode = new Barcode();
_ex.addEventListener(BarcodeEvent.RESULT, onResult);
_ex.addEventListener(BarcodeEvent.CANCEL, onCancel);

if(_ex.os == Barcode.ANDROID)
	// to speed up the launch time on Android, you may call the warmup method when
	// it is appropriate in your application. This may be needed if you are using the
	// full version of AndroidSupport dependency.
	// the first time you call the warmup method, your app will freeze for a few seconds...

if (_ex.isSupported())
	trace("Please wait...");

	// to read only the selected barcode types. use an array to read one or more barcodes
    //[Barcode.QR], File.applicationDirectory.resolvePath("com_doitflash_barcode_beep.mp3"), true, "Cancel");
	// to read all barcodes supported by the extension. read documentations to know which barcodes are supported., File.applicationDirectory.resolvePath("com_doitflash_barcode_beep.mp3"), true, "Cancel");
	trace("isSupported: ", _ex.isSupported());

function onCancel(e:BarcodeEvent):void
    trace("scan canceled")

function onResult(e:BarcodeEvent):void
    trace("type is: ", e.param.type)
	trace("data is: ",;

AIR .xml manifest

<manifest android:installLocation="auto">
	<!--You surely need permission to use the camera, right?-->
	<uses-permission android:name="android.permission.CAMERA" />
	<uses-feature android:name="" />
	<uses-feature android:name="" android:required="false" />
	<uses-feature android:name="android.hardware.screen.landscape" />
	<!--If you wish to use the vibration when a barcode is detected, you need to set the permission like below-->
	<uses-permission android:name="android.permission.VIBRATE"/>
	<!--Android 15 or higher can support this ANE-->
	<uses-sdk android:minSdkVersion="15" />
	<!--The new Permission thing on Android works ONLY if you are targetting Android SDK 23 or higher-->
	<uses-sdk android:targetSdkVersion="26"/>
	<!--Zxing lib requires you to set this screen supports-->
	<supports-screens 	android:anyDensity="true" 
						android:xlargeScreens="true" />
				<action android:name="android.intent.action.MAIN" />
				<category android:name="android.intent.category.LAUNCHER" />
				<action android:name="android.intent.action.VIEW" />
				<category android:name="android.intent.category.BROWSABLE" />
				<category android:name="android.intent.category.DEFAULT" />
		<!--Main activity for detecting barcodes-->
		<activity 	android:name="" 
					android:windowSoftInputMode="stateAlwaysHidden" />
		<!--bridge activity between Native Android and Adobe Air-->
		<activity 	android:name="com.doitflash.barcode.utils.ExBridge" 
					android:theme="@style/Theme.Transparent" />

	<!--iOS 8.0 or higher can support this ANE-->
	<!--A new feature for iOS 10 submissions requires you to add the 'purpose string' to your app when accessing a user's private data-->
	<string>My description about why I need this feature in my app</string>

Embedding the ANE:

	<!-- -->
	<!-- -->


  • This ANE is dependent on permissionCheck. Download it from here.
  • AIR SDK 30+
  • Android 15+
  • iOS 8.0+


Below are the list of Permissions this ANE might require. Check out the demo project available at this repository to see how we have used the PermissionCheck ANE to ask for the permissions.

Necessary Optional

Commercial Version

Barcode code scanner ANE


How to embed ANEs into FlashBuilder, FlashCC and FlashDevelop


Nov 17, 2018 - V3.4.7

  • Works with OverrideAir ANE V5.6.1 or higher
  • Works with ANELAB V1.1.26 or higher

Sep 10, 2018 - 3.4.6

  • Removed androidSupport dependeny.

Feb 7, 2018 - 3.4.5

Dec 15, 2017 - 3.4.4

Aug 24, 2017 - 3.4.0

  • Updated to the latest version of zxing library.
  • Added method warmup() for Android to speedup the camera launch time if you are using the full version of the androidSupport

Mar 17, 2017 - 3.3.0

  • Fixed issue 34
  • Updated with the new OverrideAir ANE.
  • Even if you are building for iOS only, you still need to add the OverrideAir dependency.

Nov 11, 2016 - 3.2.0

  • Optimized for Android manual permissions if you are targeting AIR SDK 24+
  • From now on, this ANE will depend on androidSupport.ane and overrideAir.ane on the Android side

Mar 28, 2016 - 3.1.1

  • Fixed a bug related to wrongly showing a broken menu on Android devices with a hardware menu key.

Jan 20, 2016 - 3.1.0

Dec 29, 2015 - 3.0.0

  • added optional beep sound and vibration when a barcode is detected
  • Added support for almost all barcodes including: UPCE, CODE39, EAN13, EAN8, CODE128, PDF417, QR, AZTEC, ITF14, DATAMATRIX

Dec 20, 2015 - 2.9.1

  • minor bug fixes

Nov 02, 2015 - V2.9

  • doitflash devs merged into MyFLashLab Team.

May 16, 2015 - V2.1

  • removed android-support-v4.jar dependency

Jan 28, 2015 - V2.0

  • added support for iOS devices including 64-bit arch

Mar 03, 2013 - V1.1

  • there was a bug when compiling with Flex SDK 4.6 which is now fixed

Jan 31, 2013 - V1.0

  • beginning of the journey!