Hi currently I am doing a online calendar project.
There ia a drop-down list tied to reminder(label) and when i select any of the reminder options in the ddl and
click on downlaod pdf button, there should be a message box that tells users they are not allow to select any of the reminder options
for PDF.
This is the code that i have entered:
protected void downloadPDFBtn_Click(object sender, ImageClickEventArgs
e) { //calls
the method to create the datatable
GetCustomMadeDataTable(); //calls
the method to generate the pdf from the
datatable GeneratePDF(table);
//popup error message when staff
choose one of the field under the Reminder field and click on the "download PDF"
button. if
(DropDownList1.SelectedItem.Value !=
null)
{
MessageBox.Show("There is no timetable available
for");
Response.Redirect("DownloadTimetable.aspx");
}
|
Thanks ur help is deeply appreciated. Hope to hear from u soon!
Bryian TanPosted Jan 26, 2011, 10:34 PM
How did you solve it?
lauren brownPosted Jan 26, 2011, 8:50 PM
Marco de BoerPosted Jan 25, 2011, 5:09 PM
Sam HobbsPosted Jan 25, 2011, 1:29 PM
What is the "Download PDF" button? Is it in a form that you created; if not, then where does it come from? What is the Reminder field?
lauren brownPosted Jan 25, 2011, 2:41 AM
Thanks for your reply:)
However, I am unable to get the output. The output stays the same as before.
The user is not suppose to select one of the opetion under the Reminder field. If they accidently select the reminder and click on the "Download PDF" button, the system will prompt user with an message to remind them that "There is no reminder availavle for PDF format".
Thanks ur help is deeply appreciated. Hope to hear from u soon!
Suthish NairPosted Jan 25, 2011, 1:26 AM
MessageBox.Show will work for windows only, not web applications.