Hi guys Ive been trying different ways in which one can add to a list and save up on lines of coding at the same time. Failing miserably however :(
What i am trying to do is have a feature where the user inputs 2 values via textboxes and then the system multiplies those values and adds random values to a list.
so if the values entered were 2 and 4 then the system should produce 8 random numbers and add them to a list.
Thanks guys!
Loading
VulpesPosted Jan 7, 2012, 8:06 AM
VulpesPosted Jan 7, 2012, 1:54 PM
JohnPosted Jan 7, 2012, 1:12 PM
Sam HobbsPosted Jan 7, 2012, 12:33 PM
Sam HobbsPosted Jan 7, 2012, 6:12 AM
Krishna GaradPosted Jan 7, 2012, 12:49 AM
on global level declare the list
List
in event where you want to multiply the values write
double val1=Convert.ToDouble(txtval1.text);
double val2=Convert.ToDouble(txtval2.Text);
double result=val1*val2;
lst.Add(result);