Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8629261
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 12, 20262026-06-12T08:45:29+00:00 2026-06-12T08:45:29+00:00

I’m using EMDK 2.5 (VS2008 and VC# and .NetCF3.5) Barcode2 class from the library

  • 0

I’m using EMDK 2.5 (VS2008 and VC# and .NetCF3.5) Barcode2 class from the library to write a sample application to scan bar codes. I followed the samples available in EMDK namely CS_Barcode2Sample1 project.Every time I hardware trigger the scan the notification “E_SCN_READINCOMPATIBLE” is thrown and not able to retrieve the scanned data. The documentation doesn’t say much about the cause of E_SCN_READINCOMPATIBLE notification and no luck from Google search. I tried several options including making use of Symbol.Barcode and the outcome is same.
I also tried EMDK 2.3 but the result is same.

I’ve pasted the whole code here….

public partial class Form1 : Form
    {
        private Barcode2 myBarcode2 = null;

        public Form1()
        {
            InitializeComponent();
            InitBarcode();
        }

        public bool InitBarcode()
        {
            // If the Barcode2 object is already initialized then fail the initialization.
            if (myBarcode2 != null)
            {
                return false;
            }
            else // Else initialize the reader.
            {
                try
                {

                    Symbol.Barcode2.Device[] AvailableDevices = Symbol.Barcode2.Devices.SupportedDevices;
                    if (AvailableDevices.Length == 0)
                    {
                        return false;
                    }

                    if (AvailableDevices.Length == 1)
                    {
                        //get the first available scanner in the list
                        Symbol.Barcode2.Device MyDevice = AvailableDevices[0];
                        // Create the reader, based on selected device.
                        myBarcode2 = new Barcode2(MyDevice);

                        // Attach a scan notification handler.
                        //this.myScanNotifyHandler = new Barcode2.OnScanHandler(myBarcode2_ScanNotify);
                        myBarcode2.OnScan += myBarcode2_ScanNotify;

                        // Attach a status notification handler.
                        //this.myStatusNotifyHandler = new Barcode2.OnStatusHandler(myBarcode2_StatusNotify);
                        myBarcode2.OnStatus += myBarcode2_StatusNotify;
                        myBarcode2.Config.TriggerMode = TRIGGERMODES.HARD;

                        // Submit a scan.
                        myBarcode2.Scan(5000);
                      }
                }
                catch (OperationFailureException ex)
                {
                    MessageBox.Show("Exception Raised 1");
                    return false;
                }
                catch (InvalidRequestException ex)
                {
                    MessageBox.Show("Exception Raised 2");
                    return false;
                }
                catch (InvalidIndexerException ex)
                {
                    MessageBox.Show("Exception Raised 3");
                    return false;
                }
            }
            return false;
        }

        private void myBarcode2_ScanNotify(ScanDataCollection scanDataCollection)
        {
            // Checks if the BeginInvoke method is required because the OnScan delegate is called by a different thread
            if (this.InvokeRequired)
            {
                // Executes the OnScan delegate asynchronously on the main thread
                this.BeginInvoke(new Barcode2.OnScanHandler(myBarcode2_ScanNotify), new object[] { scanDataCollection });
            }
            else
            {
                // Get ScanData
                ScanData scanData = scanDataCollection.GetFirst;

                int i;
                switch (scanData.Result)
                {
                    case Symbol.Barcode2.Results.SUCCESS:
                        String str = scanData.Text;
                        myBarcode2.Config.TriggerMode = TRIGGERMODES.HARD;
                        myBarcode2.Scan(5000);
                        break;

                    case Symbol.Barcode2.Results.E_SCN_READTIMEOUT:
                        break;

                    case Symbol.Barcode2.Results.CANCELED:
                        break;

                    case Symbol.Barcode2.Results.E_SCN_DEVICEFAILURE:
                        i = 93;
                        break;

                    default:
                        if (scanData.Result == Symbol.Barcode2.Results.E_SCN_READINCOMPATIBLE)
                        {
                            // If the failure is E_SCN_READINCOMPATIBLE, exit the application.
                            MessageBox.Show("Fatal Error");
                            this.Close();
                            return;
                        }
                        break;
                }
            }
        }

        private void myBarcode2_StatusNotify(StatusData statusData)
        {
            // Checks if the Invoke method is required because the OnStatus delegate is called by a different thread
            if (this.InvokeRequired)
            {
                // Executes the OnStatus delegate on the main thread
                this.Invoke(new Barcode2.OnStatusHandler(myBarcode2_StatusNotify), new object[] { statusData });
            }
            else
            {
                int i;
                switch (statusData.State)
                {
                    case States.IDLE:
                        break;

                    case States.READY:
                        break;

                    default:
                        break;
                }
            }
        }
    }
}
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-12T08:45:30+00:00Added an answer on June 12, 2026 at 8:45 am

    I’ve went thru this recently also, as I observed, it probably due to the scanner device is occupied by other application, where the scan request has been queued already, you can go to memory management, and kill the suspect app, and try your app again.

    Refer to the Symbol FAQ

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I'm new to using the Perl treebuilder module for HTML parsing and can't figure
That's pretty much it. I'm using Nokogiri to scrape a web page what has
link Im having trouble converting the html entites into html characters, (&# 8217;) i
For some reason, after submitting a string like this Jack’s Spindle from a text
I am reading a book about Javascript and jQuery and using one of the
I have a string like this: La Torre Eiffel paragonata all’Everest What PHP function
I'm using v2.0 of ClassTextile.php, with the following call: $testimonial_text = $textile->TextileRestricted($_POST['testimonial']); ... and
I am doing a simple coin flipping experiment for class that involves flipping a
We're building an app, our first using Rails 3, and we're having to build
I'm parsing an RSS feed that has an ’ in it. SimpleXML turns this

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.