5 AnswersNew Answer
`double` type also has `TryParse` method you can use to safely convert a given string to `double` double num; bool res = double.TryParse("123.45", out num); When <res> equals to true it means the string can be and had been converted to double, the conversion result is saved into variable <num>.
Jayakrishna For example, I have textbox1 with an introduction to it of 1.75 and textbox2 with a number of 1.75, I want label1 to output their sum.
Clearly you could use Exeption Handling, more you find here: https://www.sololearn.com/learn/CSharp/2690/
What difficulty you are facing in sum,? As Ipang suggested, use TryParse, take 2 numbers like one for textbox1, and another for box2. double num_1, num_2; Assign values.. And display in label1=> as num_1+num_2;
int j=3; double i=j; Simply it possible, it is implicit convertion; since it lower type to double. No loss of data. But in higher to lower type convertion, there is need of type convertion.. Like, double i=3.5; int k=(int)i; // k=3