DropDownList remove blanks from string
-
Hello, I need to form string point_number + point_name and display it in my DropDownList as text. I have a string of blanks form rezul string like this: rez = point_number + blanks.substring(0,length(blanks) - length(point_number)) + point_name Unfortunatly I saw that in DropDownList the string is displayed with only 1 blank between number and name : (( Then I replace blanks to _ and everything was allright. What I need to change in DropDownList to force it display blanks? Thank you
-
Hello, I need to form string point_number + point_name and display it in my DropDownList as text. I have a string of blanks form rezul string like this: rez = point_number + blanks.substring(0,length(blanks) - length(point_number)) + point_name Unfortunatly I saw that in DropDownList the string is displayed with only 1 blank between number and name : (( Then I replace blanks to _ and everything was allright. What I need to change in DropDownList to force it display blanks? Thank you
If I am not mistaken this is because HTML removes any duplicate spaces. Try replacing spaces with & nbsp; to force them in there. -- modified at 17:05 Thursday 12th July, 2007
Darroll
-
If I am not mistaken this is because HTML removes any duplicate spaces. Try replacing spaces with & nbsp; to force them in there. -- modified at 17:05 Thursday 12th July, 2007
Darroll
Ok - I'll edit it for you. He needs to put
in.Please visit http://www.readytogiveup.com/ and do something special today. Deja View - the feeling that you've seen this post before.
-
Ok - I'll edit it for you. He needs to put
in.Please visit http://www.readytogiveup.com/ and do something special today. Deja View - the feeling that you've seen this post before.
Hello, Thank you for answers but I tryied to replace blanks with but it displayed like this 123 Name : (( Here is my code: On DropDownListDataBound for (int i = 0; i < DDListPoint.Items.Count; i++) { DDListPoint.Items[i].Text = DDListPoint.Items[i].Text.Replace(" ", " "); } When I should replace blanks? on the client side in Javascript? Thank you : )
-
Hello, Thank you for answers but I tryied to replace blanks with but it displayed like this 123 Name : (( Here is my code: On DropDownListDataBound for (int i = 0; i < DDListPoint.Items.Count; i++) { DDListPoint.Items[i].Text = DDListPoint.Items[i].Text.Replace(" ", " "); } When I should replace blanks? on the client side in Javascript? Thank you : )
-
Hello, I need to form string point_number + point_name and display it in my DropDownList as text. I have a string of blanks form rezul string like this: rez = point_number + blanks.substring(0,length(blanks) - length(point_number)) + point_name Unfortunatly I saw that in DropDownList the string is displayed with only 1 blank between number and name : (( Then I replace blanks to _ and everything was allright. What I need to change in DropDownList to force it display blanks? Thank you