-1

I want to read only the last ten characters from the barcode input in the windows form application. how to do that please help me.?

I developed a windows form application using c# which shows the barcode input in the textbox and in the label.

ProgrammingLlama
  • 36,677
  • 7
  • 67
  • 86

1 Answers1

0

Barcode Scanner automatically scans the code. Once you get the code in textbox use substring to get last 10 digits of the code.

Suhel Patel
  • 278
  • 1
  • 12
  • How to use substring in c# and can you provide the code for a windows form application, such that when the end user put the cursor in a textbox and scan the code using scanner he should see only last ten charcters of the barcode data. Please help me – user11732309 Jul 03 '19 at 06:44
  • Fetch textbox data into some string, then perform substring and assign that to textbox again. `String TextBox = "ABC1234569871"; TextBox = TextBox.Substring(TextBox.Length-10); ` – Suhel Patel Jul 03 '19 at 06:50
  • Can you please explain me in detail, now i have to create a windows form application with a textbox then connect the scanner and reads the data in that textbox then how could i get last ten charcters from that data? – user11732309 Jul 03 '19 at 08:38