Page 214 - DCAP312_WEB_TECHNOLOGIES_II
P. 214

Web Technologies-II



                   Notes         Step 10:  Go to Default.cs page and on the button click event use the following code.
                                           Protected void Button1_Click(object sender, EventArgs ex
                                           {
                                           localhost.Service my = new localhost.Service(), // you need to create
                                           the object of the web service
                                           inta=Convert.ToInt32(TextBox1.Text);
                                           intb=Convert.ToInt32(TextBox2.Text);
                                           intc=mys.Multiplication(a,b);
                                           TextBox3.Text=c.ToString();
                                           }
                                 Step 11:  After pressing the F5 function key to run the website, you will see:






























                                 Enter the number.































        208                               LOVELY PROFESSIONAL UNIVERSITY
   209   210   211   212   213   214   215   216   217   218   219