LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Urgent help - String operation

Dear People,

I have the following difficulty. I have a few Mega Byte long string, constructed like this:
.............
..............
100000001
1003ff001
1010013ff
1000003ff
1023fe001
102000000
1010013fd
0ff0033fc
0ff002001
001001001
...................
..................
but sometimes the string I get has empty line in between the rows, like:

................
.................
100000001
1003ff001

1010013ff
1000003ff

1023fe001
102000000
1010013fd

0ff0033fc
0ff002001
001001001
...............
.................

Now,I simply want to cut those emty rows so the string should contain no blank rows and gets a form like the first case.

I need urgent help!

Best Regards
john


Message Edited by J.Dred on 12-07-2007 07:53 PM

Message Edited by J.Dred on 12-07-2007 07:54 PM
0 Kudos
Message 1 of 5
(3,398 Views)
If you have only single empty lines, you could just do a global replace of "\n\n" with "\n" (\-codes display).
 
Modify for your exact line delimiter. "Search and replace string" is in the string palette. 🙂
0 Kudos
Message 2 of 5
(3,393 Views)

Dear Altenbach,

here is the vi, as you suggested. But not functioning 😞 😞 😞

I definetely have to solve this problem.

thank you very much

0 Kudos
Message 3 of 5
(3,359 Views)
code display is differend from normal display.
Switch to code display and then enter "\n"
Also you can place a "String Constand" and press ENTER. (in normal display). Then if you switch to code display it will automatic change to "\n".
Write some strings and change it to code display to understant the differences. "Code", display all ASCII characters
Message 4 of 5
(3,350 Views)


altenbach wrote:
If you have only single empty lines, you could just do a global replace of "\n\n" with "\n" (\-codes display).

Pnt is correct. Read my instructions again. 😄
0 Kudos
Message 5 of 5
(3,223 Views)