Hi
I am using desktopalert control in my windows form. I want to know how I can redirect to a new page on clicking the desktopalert (by clicking anywhere on the desktopalert or on the captiontex or on the caption image).
Also I want to know how can I make this application which would wake up every x minutes and check our database for some condition and display the desktopalert.
Thanks
I am using desktopalert control in my windows form. I want to know how I can redirect to a new page on clicking the desktopalert (by clicking anywhere on the desktopalert or on the captiontex or on the caption image).
Also I want to know how can I make this application which would wake up every x minutes and check our database for some condition and display the desktopalert.
Thanks
4 Answers, 1 is accepted
0
Hello Vijesh,
You can do this by using the click event of RadDesktopAlert popup. Consider the following sample:
Find further details about RadDesktopAlert in our online documentation.
You can wake up your application by using a timer. Consider this MSDN forum thread for an example.
If you need further assistance, I will be glad to help.
Regards, Jack
the Telerik team
You can do this by using the click event of RadDesktopAlert popup. Consider the following sample:
RadDesktopAlert alert =
new
RadDesktopAlert();
alert.CaptionText =
"Hello world"
;
alert.ContentText =
"I am a simple desktop alert message."
;
alert.Popup.Click +=
new
EventHandler(Popup_Click);
alert.Show();
void
Popup_Click(
object
sender, EventArgs e)
{
MessageBox.Show(
"Alert clicked!"
);
}
Find further details about RadDesktopAlert in our online documentation.
You can wake up your application by using a timer. Consider this MSDN forum thread for an example.
If you need further assistance, I will be glad to help.
Regards, Jack
the Telerik team
0
VIJESH
Top achievements
Rank 1
answered on 13 Dec 2012, 10:39 AM
Hi Jack,
Thanks for your reply.
The code which you sent is working fine for me. But on click of close button or pin button, the message box is displaying.
Thanks for your reply.
The code which you sent is working fine for me. But on click of close button or pin button, the message box is displaying.
0
Hello Vijesh,
You can avoid this by checking the element that is currently located under the mouse. Do this by calling the GetElementAtPoint method. Here is a sample:
Regards,
Jack
the Telerik team
You can avoid this by checking the element that is currently located under the mouse. Do this by calling the GetElementAtPoint method. Here is a sample:
void
Popup_Click(
object
sender, EventArgs e)
{
DesktopAlertPopup popup = (DesktopAlertPopup)sender;
Point pt = popup.PointToClient(Control.MousePosition);
RadButtonElement button = popup.ElementTree.GetElementAtPoint(pt)
as
RadButtonElement;
if
(button !=
null
)
{
return
;
}
MessageBox.Show(
"Hello world!"
);
}
Regards,
Jack
the Telerik team
0
VIJESH
Top achievements
Rank 1
answered on 14 Dec 2012, 03:51 PM
Hi Jack,
Your code works fine for me. Thank you so much.
Regards,
VIJESH
Your code works fine for me. Thank you so much.
Regards,
VIJESH