search envelope-o feed check
Home Unanswered Active Tags New Question
user comment-o

e.InnerHTML Hyperlink error for MonthView

Asked by Anonymous
15 years ago.
Hi,

I am having problems trying to get a link to work if a single event has to carry over to the next week (say if an event lasted 10 days). The HTML does not seem to recognise the link in this situation.

I am using code similar to the following

On BeforeEventRender event for Month View of Calendar
e.InnerHTML = "<a href='NewPage.aspx?id=" + e.Value + "'>MyLink</a>" + e.InnerHTML;

Thank you for your time and I look forward to your response,
Sandeep
Comment posted by Dan Letecky
15 years ago.
I've tried your code in IE7 and FF2 and in both it works fine.

The problem is that it fires EventClick event before it actually goes to the new URL. You could:

1) Disable EventClick by setting EventClickHandling="Disabled".

2) Use custom JavaScript EventClick handler (EventClickHandling="JavaScript"). You would need to play with the hyperlink a little bit so it can be detected in the JavaScript handler. For all other cases you would call dpc.eventClickCallBack, dpc.eventClickPostBack, or any other desired action.
This question is more than 1 months old and has been closed. Please create a new question if you have anything to add.