Help ON Save Button With Calculation

Posted by Vijayar under C# on 12/21/2011 | Points: 10 | Views : 884 | Status : [Member] | Replies : 1
Hi
i am developing a master for fee which includes fields like fee-id,class-id,I-term,II-term,III-term ,I-termlastdate,II-termlastdate,III term last date,fine .I am using calendar control to enter date.When firstterm lastdate is after 30th june
fine should be 25,if it is after 30th aug fine should be 50.How to compare this
can we compare like
datetime datetime1=txtfirsttermlastdate
if(datetime1>txtfirsttermlastdate)
fine=25
else
fine=......
where i declare fine variable and assign values.Is this correct way .Please inform me

vijaya


Responses

Posted by: Anweshabhowmick on: 12/22/2011 [Member] Starter | Points: 25

Up
0
Down
This way is right..Please send the exact code for your project.....

datetime datetime1=txtfirsttermlastdate.Text;
if(datetime1>txtfirsttermlastdate)
fine=25
else
fine=......

Vijayar, if this helps please login to Mark As Answer. | Alert Moderator

Login to post response