How to concate various controls data into a TextBox
-
i have dropdownlist1,dropdownlist2,textbox1,button1,button2,dropdownlist3 here i am selecting an item from each dropdownlist, perform concatinating and i showed in textbox fine. but when i want to enlarge concatination means the selected item text will be overridden on the previous selecteditem text i want to prevent this.. finally i want the TextBox2 output as follows; exa: (ddl1) (ddl2) (txt1) (btn1) (ddl) (ddl2) (txt1) (ddl3) Month_no = 5 and Quarter_no = 3 group by(abc) means month_no = 5 and quater_no = 3 group by(abc) how to get this one......... help me out... Regards, Koti
-
i have dropdownlist1,dropdownlist2,textbox1,button1,button2,dropdownlist3 here i am selecting an item from each dropdownlist, perform concatinating and i showed in textbox fine. but when i want to enlarge concatination means the selected item text will be overridden on the previous selecteditem text i want to prevent this.. finally i want the TextBox2 output as follows; exa: (ddl1) (ddl2) (txt1) (btn1) (ddl) (ddl2) (txt1) (ddl3) Month_no = 5 and Quarter_no = 3 group by(abc) means month_no = 5 and quater_no = 3 group by(abc) how to get this one......... help me out... Regards, Koti
-
i have dropdownlist1,dropdownlist2,textbox1,button1,button2,dropdownlist3 here i am selecting an item from each dropdownlist, perform concatinating and i showed in textbox fine. but when i want to enlarge concatination means the selected item text will be overridden on the previous selecteditem text i want to prevent this.. finally i want the TextBox2 output as follows; exa: (ddl1) (ddl2) (txt1) (btn1) (ddl) (ddl2) (txt1) (ddl3) Month_no = 5 and Quarter_no = 3 group by(abc) means month_no = 5 and quater_no = 3 group by(abc) how to get this one......... help me out... Regards, Koti
use the string format
Month_no = string.Format("{0} {1} {2} {3} {4} {5} {6} ({7})", (ddl1),(ddl2),(txt1) (btn1),(ddl),(ddl2),(txt1),(ddl3));
happy coding... -
The answer is correct somehow ie if i change any dropdownlist value it is override the corresponding value bec i wrote common funcatio like textbox2.Text=ddl.selecteditem.text+ddl2.selecteditem.text+----------- how to avoid overriding let me know...... Regards, Koti.K