I should also add that there maybe a series of there-
"{15;84;97;32}SomeString{15;84;97;32}SomeString{15;84;97;32}SomeString "
each set of {} needs to be matched up the the following SomeString...
also Somestring may have a } inside of it... (it can't have a { because of what the code I am going to use this with actualy is.., I doubt anyone is going to be using the ESC char (char$27) in the purpose I am going to be using this for...
I think this may complicate is alot more.., I was thinking that we could first split using the "{" so you will have an array Str-
Code:
'(dim Str is above)
dim i as interger
redim str(0 to ubound(Split(WholeString,"{")))
for i = 0 to ubound(Split(WholeString,"{"))
str(i) = Split(WholeString,"{")(i)
next
'Is there an easier way to transfer arrays? been doing it like this....
k now you have the str array-
str(0) = ""
str(1) = "15;84;97;32}SomeString"
str(2) = "15;84;97;32}SomeString"
str(3) = "15;84;97;32}SomeString"
now split using "}" and I am stuck here since I need to keep SomeString entact.., and it may have a "}", how will I tell if..., wait hmm.., maybe I just figured it out...
Code:
'(dim Str2 is above)
for a = 1 to ubound(str)
dim i as interger
redim str2(1 to ubound(Split(str(a),"}")))
for i = 1 to ubound(Split(str(a),"}"))
str2(i) = Split(str(a),"{")(i)
if i >= 3 then
str(2) = str(2) + str(i)'this way it will add all the other ones together if there are any
end if
next
next
so now str2 arry-
str2(1) = 15;84;97;32
str2(2) = SomeString
Now one part I don't know how to do is erase the rest of the Str2(3 to whatever), I'll try redim Str2(1 to 2) to see if that works....
I just found out that I'll have to make somesort of other str2 thing since I can't have more than 1 of them.., I think I'll make a function to do this...
then I need to make another function that will do the spliting for the 15;84;97;32 I think i can do this....
is there anything I should change at all?
thanx again,
Byan