in textbox i use default value as (14.5/100) i never give the value in run time
i need to multiply the value with next textbox . given value in source code .
need to multiply the default value in source code
my design is
a | |
b | |
a+b | |
mul | AutoPostBack="True"> |
multl |
my coding is
using System;
using System.Collections;
using System.Configuration;
using System.Data;
using System.Linq;
using System.Web;
using System.Web.Security;
using System.Web.UI;
using System.Web.UI.HtmlControls;
using System.Web.UI.WebControls;
using System.Web.UI.WebControls.WebParts;
using System.Xml.Linq;
using System.Data.SqlClient;
public partial class math : System.Web.UI.Page
{
REMO sel = new REMO();
protected void Page_Load(object sender, EventArgs e)
{
}
protected void Button1_Click(object sender, EventArgs e)
{
// float c= float.Parse(TextBox1.Text) + float.Parse(TextBox2.Text);
//TextBox3.Text = Convert.ToString(c);
//float s = c * float.Parse(TextBox4.Text);
//float s = ((c * float.Parse(TextBox4.Text)));
//TextBox5.Text = Convert.ToString(s);
}
protected void TextBox4_TextChanged(object sender, EventArgs e)
{
double guna = int.Parse(TextBox3.Text) * (14.5 / 100);
TextBox5.Text = Convert.ToString(guna);
}
protected void TextBox2_TextChanged(object sender, EventArgs e)
{
float c = float.Parse(TextBox1.Text) + float.Parse(TextBox2.Text);
TextBox3.Text = Convert.ToString(c);
}
}
textbox3* textbox4 as default value (14.5/100) =textbox5
in run time i given the value as 14.5/100 my coding is working but. i need textbox4 value as default text as 14.5/100 used in source code. multiply with textbox3. and need to show the output in textbox5
15 Replies
Know the answer? Post it — somebody with the same question will find it here.
Sign in to answer this question
It is the same account you read, post and publish with — and you will come straight back to this page.

Iftikar HussainPosted Aug 20, 2013, 4:09 AM
Regards,
Iftikar
selvi subramanianPosted Aug 20, 2013, 4:07 AM
selvi subramanianPosted Aug 20, 2013, 3:59 AM
Sanjeeb LenkaPosted Aug 20, 2013, 3:55 AM
selvi subramanianPosted Aug 20, 2013, 3:54 AM
selvi subramanianPosted Aug 20, 2013, 3:43 AM
Iftikar HussainPosted Aug 20, 2013, 3:42 AM
Sanjeeb LenkaPosted Aug 20, 2013, 3:39 AM
selvi subramanianPosted Aug 20, 2013, 3:32 AM
textbox1+textbox2=textbox3
now i give 14.5/100 in source code as text =(14.5/100)
refer my above code.
i need to show the multiply value in textbox5....
Sanjeeb LenkaPosted Aug 20, 2013, 3:24 AM
can you provide a clear details. Means in which textbox you want to show the text and what is the requirements..
selvi subramanianPosted Aug 20, 2013, 3:05 AM
its already i given in my source as text="(14.5/100)" .if my textbox3 answer cum after that i need the textbox5 value
Iftikar HussainPosted Aug 20, 2013, 2:46 AM
Regards,
Iftikar
selvi subramanianPosted Aug 20, 2013, 2:26 AM
Pankaj KumarPosted Aug 20, 2013, 2:23 AM
Iftikar HussainPosted Aug 20, 2013, 2:20 AM
Try like this
Regards,
Iftikar