Click here to Skip to main content
16,017,881 members
Please Sign up or sign in to vote.
1.00/5 (1 vote)
See more:
I have one list box, i add data in list box through combobox,so how i calculate that data in list box and displayed in text box in C#.

My second questions is how i use second form or how i jump to second form to first form in C#
Posted
Updated 2-Jan-12 12:38pm
v2
Comments
Sergey Alexandrovich Kryukov 2-Jan-12 18:46pm    
Why? Not clear... what is "jump to second form"? what is "calculate that data"?
--SA

1 solution

Instead of adding the data directly to the list box consider placing the data in a datatable[^].

You can then bind the datatatble to the listbox. See: http://social.msdn.microsoft.com/Forums/is/csharpgeneral/thread/07d8321a-4b54-49b3-9bfe-94269affade8[^].

The calculations can probably be done using DataTable.Compute Method [^]
 
Share this answer
 
Comments
Espen Harlinn 2-Jan-12 19:02pm    
Neat solution, my 5
Wendelius 3-Jan-12 0:23am    
Thank you Espen :)

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900