calendarextender

Two CalendarExtenders?

你离开我真会死。 提交于 2019-12-11 01:08:57
问题 I have a popup ajax calendarextender that populates a text box with the selected date, (MM/dd/yyyy). This works. I want to capture the same date in an additional text box with a different format (yyyyMMdd). The first is for display and the second date is a parameter for gridview query. Is this done with two calandarextenders? (btw I'm using C#) 回答1: If you are supplying one to a query, you could just change the parameter value in code before supplying it to the query. var datetimeForQuery =

.net Ajax calendarExtender cuts of saturday's in IE7 (works fine in firefox)

杀马特。学长 韩版系。学妹 提交于 2019-12-10 20:08:40
问题 I was having this problem in IE7 where the saturdays appear to be missing from the calendar. It displays fine in Firefox and a few people have suggested that it could be my other stylesheets messing it up so i am now using a custom calendar CSS theme and i'm still having the same problem. Any ideas? is there a known bug with the ajax toolkit pack that is used? 回答1: here's a solution: .cal_Theme1 .ajax__calendar_days td { padding:0px; } 回答2: Great answer from SocialAddict, but it didn't work

ASP.NET AJAX Toolkit - CalendarExtender is reset on Postback

一个人想着一个人 提交于 2019-12-08 15:52:02
问题 I have an ASP.NET page that has two input elements: A TextBox that is ReadOnly. This TextBox is the TargetControl of a CalendarExtender A DropDownList with AutoPostBack=true Here is the code: <table border="0" cellpadding="0" cellspacing="0"> <tr><td colspan="2">Date:</td></tr> <tr><td colspan="2"> <asp:TextBox ID="dateTextBox" runat="server" ReadOnly="true" /> <ajax:CalendarExtender ID="datePicker" runat="server" Format="MM/dd/yyyy" OnLoad="datePicker_Load" TargetControlID="dateTextBox" /> <

ASP.NET Ajax CalendarExtender will not update SelectedDate value

无人久伴 提交于 2019-12-05 02:51:58
For some reason, any CalendarExtenders on an ASP.NET site that is being worked on will not be updated. I have already checked all the obvious places (such as AutoPostBack and AutoEventHandler). The problem is that when I select a date from the Calendar and post it to the form, the TextBox that is being extended IS being updated, but the calendar extender's date is simply not being being updated (e.g. SelectedDate is still the same as before). I have googled for any possible solutions but none have worked. Here is the code: <%@ Page Title="" Language="C#" MasterPageFile="~/Site.master"

Why is my CalendarExtender getting overlapped when rendered?

放肆的年华 提交于 2019-12-04 17:45:41
问题 I'm working on a .NET web application and I'm using a CalendarExtender control within it to have the user specify a date. For some reason, when I click the icon to display the calendar, the background seems to be transparent. I'm using the extender on other pages and do not run into this issue. I'm not sure if it is worth mentioning, but the calendar is nested within a panel that has a rounded corner extender attached to it, as well as the panel below it (where the "From" is overlapping).

Why is my CalendarExtender getting overlapped when rendered?

ⅰ亾dé卋堺 提交于 2019-12-03 11:44:08
I'm working on a .NET web application and I'm using a CalendarExtender control within it to have the user specify a date. For some reason, when I click the icon to display the calendar, the background seems to be transparent. I'm using the extender on other pages and do not run into this issue. I'm not sure if it is worth mentioning, but the calendar is nested within a panel that has a rounded corner extender attached to it, as well as the panel below it (where the "From" is overlapping). Within that panel, I do have a div layout setup to create two columns. EDIT: The other thing to note here

String was not recognized as a valid DateTime during insert

折月煮酒 提交于 2019-12-02 16:13:00
问题 I get the following error when i try to convert to date time. String was not recognized as a valid DateTime. cost.b_date = DateTime.Parse(c_date.Text) ;//c_date.Text = 12/28/2012 Then i try string date = string.Format("{0:yyyy-MM-dd}",c_date.Text); cost.b_date = DateTime.Parse(date) ; but i get the same exception how to fix this problem. 回答1: Using string.Format when the input is a string is pointless. If you know the format of the string, you should use DateTime.ParseExact or DateTime

String was not recognized as a valid DateTime during insert

白昼怎懂夜的黑 提交于 2019-12-02 07:38:31
I get the following error when i try to convert to date time. String was not recognized as a valid DateTime. cost.b_date = DateTime.Parse(c_date.Text) ;//c_date.Text = 12/28/2012 Then i try string date = string.Format("{0:yyyy-MM-dd}",c_date.Text); cost.b_date = DateTime.Parse(date) ; but i get the same exception how to fix this problem. Using string.Format when the input is a string is pointless. If you know the format of the string, you should use DateTime.ParseExact or DateTime.TryParseExact . For example, for the string you've got, you could use: DateTime date = DateTime.ParseExact(text,

CalendarExtender Change date with Javascript

不打扰是莪最后的温柔 提交于 2019-11-29 17:35:02
问题 I have a CalendarExtender control on my page and sometimes have to change the date to the next occuring Sunday. I'm currently using the OnClientDateSelectionChanged property of the control to call a function that will add some days to the date until its Sunday. The problem I'm having is that if I select a Tuesday in my calendar, the textbox will display the next Sunday but the selected date in the calendar is still Tuesday. How do I update the CalendarExtender to have the new date that has

CalendarExtender wrongly positioned after scrolling

感情迁移 提交于 2019-11-29 09:50:07
I am adding a CalendarExtender to a page, using the default styles. When I click the calendar button to trigger the calendar popup, the calendar displays normally. However, when I scroll down and click the button again, the calendar's position is not where it should be, as seen below. Why is this occuring and how do I fix it? EDIT: A bit about the implementation of this page. The CalendarExtender and TextBox are part of a WebPart added to a SharePoint 2007 Page. I am creating the extender like so: textBox = new TextBox() { ID = "textBox" }; Controls.Add(textBox); calendar = new