Hello,

The Split function baheves strange for me.
I receive data fon an equipment throu RS232 and I need to extract the
information from a string.

The data groups are separated by 4 chr(10) character (originally it was 2
CrLf but when reading in Gambas it became 4 chr(10) - this is also strange).

So I take the string and I use Split(myString, chr(10) & chr(10) & chr(10) &
chr(10)).
The result is the same what as I use Split(myString, chr(10)), so the first
character only:
0. item is one data
1,2,3. item empty
4. item data
5, 6, 7. empty
etc.

To solve the problem I used Replace function to replace the 4 chr(10) with
only one character and the Split function on the redefined string - so
finally my code works.

Please let me know if this is a bug, a normal behaviour or I have made a
mistake when using the Split function.

Regards, Robi
-- 
View this message in context: 
http://old.nabble.com/Split-tp26463657p26463657.html
Sent from the gambas-user mailing list archive at Nabble.com.


------------------------------------------------------------------------------
Let Crystal Reports handle the reporting - Free Crystal Reports 2008 30-Day 
trial. Simplify your report design, integration and deployment - and focus on 
what you do best, core application coding. Discover what's new with
Crystal Reports now.  http://p.sf.net/sfu/bobj-july
_______________________________________________
Gambas-user mailing list
Gambas-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/gambas-user

Reply via email to