fskilnik
asked on
String error
Hi there!
To use as part of a xml file, I need to create a dynamic string with something like that:
<set label='631' value='0' /><set label='689' value='3' /><set label='699' value='4' />
With the following code I was ALMOST able to do it...
-------------------------- ---------- ---------- --
Dim strSymbolsList
While ((Repeat1__numRows <> 0) AND (NOT rsQuantPercentiles.EOF))
strSymbolsList = strSymbolsList & "set label='" & rsQuantPercentiles.Fields. Item("User ID").Value & "' value='" & rsQuantPercentiles.Fields. Item("Norm alCDF").Va lue & "' />"
Repeat1__index=Repeat1__in dex+1
Repeat1__numRows=Repeat1__ numRows-1
RecordCounter = RecordCounter+1
rsQuantPercentiles.MoveNex t()
Wend
-------------------------- ---------- ---------- ---------- ---------- ---
This code would generate, in the corresponding example, the following:
set label='631' value='0' />set label='689' value='3' />set label='699' value='4' />
As it easily seen, the ONLY problem was with the < character, presented in bold above, but NOT in my code (of course)!
The easy modification that I guess should work is:
strSymbolsList = strSymbolsList & "<set label='" & rsQuantPercentiles.Fields. Item("User ID").Value & "' value='" & rsQuantPercentiles.Fields. Item("Norm alCDF").Va lue & "' />"
But with little modification the "Response.Write(strSymbols List)" gets nothing!
I cannot imagine why... how should I correct that, please?
Thanks!
To use as part of a xml file, I need to create a dynamic string with something like that:
<set label='631' value='0' /><set label='689' value='3' /><set label='699' value='4' />
With the following code I was ALMOST able to do it...
--------------------------
Dim strSymbolsList
While ((Repeat1__numRows <> 0) AND (NOT rsQuantPercentiles.EOF))
strSymbolsList = strSymbolsList & "set label='" & rsQuantPercentiles.Fields.
Repeat1__index=Repeat1__in
Repeat1__numRows=Repeat1__
RecordCounter = RecordCounter+1
rsQuantPercentiles.MoveNex
Wend
--------------------------
This code would generate, in the corresponding example, the following:
set label='631' value='0' />set label='689' value='3' />set label='699' value='4' />
As it easily seen, the ONLY problem was with the < character, presented in bold above, but NOT in my code (of course)!
The easy modification that I guess should work is:
strSymbolsList = strSymbolsList & "<set label='" & rsQuantPercentiles.Fields.
But with little modification the "Response.Write(strSymbols
I cannot imagine why... how should I correct that, please?
Thanks!
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
Thank you for coming again to rescue me from my ignorance!! :)
You are right! In the source code I see that I really got what I wanted...
Thanks a LOT!
Kind Regards,
fskilnik.