Hex to ascii

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • AmmanKhan
    New Member
    • Oct 2013
    • 2

    Hex to ascii

    I have data in hex form when i convert in C# windows form it give
    Name
    Mobile
    CNIC
    R-ID

    Name:Wajahat Abbas
    35 37 20 36 31 20 36 41 20 36 31 20 36 38 20 36 31 20 37 34 20 32 30 20 34 31 20 36 32 20 36 32 20 36 31 20 37 33 20 30 30 20 30 30 20 30 30 20

    Cellno:03455172 815
    33 30 20 33 33 20 33 34 20 33 35 20 33 35 20 33 31 20 33 37 20 33 32 20 33 38 20 33 31 20 33 35 20 30 30 20 30 30 20 30 30 20 30 30 20 30 30

    CNIC:61101-0310105-1
    33 36 20 33 31 20 33 31 20 33 30 20 33 31 20 32 44 20 33 30 20 33 33 20 33 31 20 33 30 20 33 31 20 33 30 20 33 35 20 32 44 20 33 31 20 30 30

    ID:T-000039
    35 34 20 32 44 20 33 30 20 33 30 20 33 30 20 33 30 20 33 33 20 33 39 20 30 30 20 30 30 20 30 30 20 30 30 20 30 30 20 30 30 20 30 30 20 30 30

    All data present in 16 bytes for e.g name = 16 bytes , cell = 16 bytes ...
    If i want to convert it in hexa how can i get the bytes for e.g i want to pick the data
    from 1 to 16 is for NAME, then 17 to 32 is fir CELL .... and so on
    Guide me in a code how i get this bytes in sequence so that i can add the data in database.
    Thanks
Working...