popup calendar problem

Bill Humphrey

Active member
Joined
Apr 10, 2008
Messages
35
Programming Experience
Beginner
In VS2003 I used to use the code below in a td in an ascx page and it would open a popup window which was a calendar:

<td valign="middle" align="left" width="20%"><asp:HyperLink ID="fDateRequired_Calender" runat="server" ImageUrl="../images/icon-calendar.gif" NavigateUrl="javascript:OpenCalendar('JobRequestDetailsCTL:fDateRequired', 'JobRequestDetailsCTL', true)" tabIndex="1"></asp:HyperLink>

</td>

However in VS2008 this line of code generates an error in the aspx container page for the control:

NavigateUrl="javascript:OpenCalendar('JobRequestDetailsCTL:fDateRequired', 'JobRequestDetailsCTL', true)"

Error Rendering Control

A relative URI exception cannot be created because the ‘uriString’ parameter represents an absolute URI

Any ideas on a work around?

Regards BH
 
whats wrong with using the calednar control?
 
you can use CSS to hide portions you don't want to see, or make it smaller.
 
u could create a custom control
ASP.NET.4GuysFromRolla.com: Extending the Calendar Control's Date Navigation

use a button to toggle visibility of the calendar

ur custom control be a combination a textbox for the date, the controls mentioned above on the url, and a button

It should look like this

1ha3cl.jpg


once u select the date, the control will go back to hide the calendar
 
Back
Top