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 4016668
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 20, 20262026-05-20T09:46:05+00:00 2026-05-20T09:46:05+00:00

I am writing a Delphi application that can read different barcodes, to enter data

  • 0

I am writing a Delphi application that can read different barcodes, to enter data into different fields on the same form/page.

Because the same “id” can be used for multiple items (e.g. id 123 could be for parts, material, employee, etc), I need to find a way to:

  1. Incorporate the appropriate tag/field into the barcode itself, in any format (e.g. userid=123 or partid=123),
  2. parse this barcode info into a relevant field/value pair in order to insert the data in the right application textbox/select/radio button/etc.

It’s similar to the pairs used in the web URLs where the parser splits pairs into field-value.

Best Regards,

  • 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-05-20T09:46:06+00:00Added an answer on May 20, 2026 at 9:46 am

    The “barcode” is mostly irrelevant. You want to pack a name=value pair into as little space as possible, and later separate the “name” and “value” parts. The “barcode” part is only relevant because it imposes some limitations. Example: Depending on the kind of barcode you use, you may only use digits, and not too many of them. So you can’t use an “=” sign.

    Here’s one possible implementation: Assign numbers to all your “names”; Let’s say “part number” is 1, “material” is 2, “employee” is 3. Simply prefix the text you put into the barcode with the number!

    Encoding is done like this:

    Barcode.code := '1' + PartNumber;
    Barcode.code := '2' + MaterialNumber;
    

    Decoding is just as easy:

    case BarcodeText[1] of
      '1': PartNumber := Copy(BarcodeText,2,MaxInt);
      '2': MaterialNumber := Copy(BarcodeText,2,MaxInt);
    end;
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I am writing a Delphi application that allows a user to connect to an
I'm migrating an old Delphi application that I wrote into C#. The application is
I'm writing an application in Delphi which uses an SQLite3 database. I'd like to
Writing a JSP page, what exactly does the <c:out> do? I've noticed that the
I'm writing an application which can copy files on a network share. Usually the
I'm writing a client-server win32 application in Delphi 7 and in a section i
I'm writing an application in Delphi 2010, and I'd like to provide the option
I've encountered a problem while writing code in Delphi. Namely I can't get acces
Am writing an application for iphone to read a text file using NSData. NSFileHandle
I'm writing a Delphi expert. I need to be able to write a value

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.