Click here to Skip to main content
11,408,708 members (62,858 online)
Rate this: bad
good
Please Sign up or sign in to vote.
I am getting a value like this:
"RE000022000500200Ì 0.00 0.1 0.129.8#####-  97-   2#####-   1#####   960.504.00 0: 00.000.00 8: 013:52 0: 021:52############2.00.0   "

I want a value like this after doing some processing on above data can you You please what should be the logic to remove "Ì"

0x0043d690 "RE000022000500200 0.00 0.1 0.129.8#####-  97-   2#####-   1#####   960.504.00 0: 00.000.00 8: 013:52 0: 021:52############2.00.0   "
Posted 15-Oct-12 23:26pm
Comments
Marius Bancila at 16-Oct-12 7:39am
   
Is this data provided as text or binary? Because that Ì could be some actual data incorrectly displayed as a character, even if it is not intended so.
Rate this: bad
good
Please Sign up or sign in to vote.

Solution 1

You could use std::find/[^] to locate occurences of 'Ì', and then remove it with an appropriate function: if the data type is std::string, then use string::erase[^], otherwise use a simple loop to shift the rest of the string one position to the left.
  Permalink  
Rate this: bad
good
Please Sign up or sign in to vote.

Solution 2

You already have all the required information to process this data which you posted into your question on StackOverflow[^]. You really should be processing this by selecting the different fields in the structure that the data is presented in, rather than trying to process it as a simple string of characters.
  Permalink  

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

  Print Answers RSS
0 OriginalGriff 390
1 Sergey Alexandrovich Kryukov 284
2 Maciej Los 155
3 Peter Leow 140
4 PIEBALDconsult 130
0 Sergey Alexandrovich Kryukov 8,626
1 OriginalGriff 6,855
2 Maciej Los 3,322
3 Abhinav S 3,238
4 Peter Leow 3,034


Advertise | Privacy | Mobile
Web01 | 2.8.150414.5 | Last Updated 16 Oct 2012
Copyright © CodeProject, 1999-2015
All Rights Reserved. Terms of Service
Layout: fixed | fluid

CodeProject, 503-250 Ferrand Drive Toronto Ontario, M3C 3G8 Canada +1 416-849-8900 x 100