473,326 Members | 2,012 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,326 software developers and data experts.

Pass the selected date from a calendar in a querystring - .net 2005 b2

We are trying to pass the selected date from a .net calendar in a
querystring. We manage to display the selected date from the calendar in a
Lable like this :

protected void Calendar1_SelectionChanged(object sender, EventArgs e)
{
lblDate.Text = Calendar1.SelectedDate.ToShortDateString();
}

<asp:Label ID="lblDate" runat="server"></asp:Label>

What we are trying to accomplish is to pull the above value of the lable
which is "lblDate" to the following link and pass is as a querystring

<a href='default5.aspx?tech=<%# Eval("RESPONS")
%>&amp;today=selected_date'><span style="font-size: 10px">Link
Name</span></a><br />

thnx

Nov 19 '05 #1
1 1633
protected void Calendar1_SelectionChanged(object sender, EventArgs e)
{
lblDate.Text = Calendar1.SelectedDate.ToShortDateString();
litDate.Text = Calendar1.SelectedDate.ToShortDateString();

}

<asp:Label ID="lblDate" runat="server"></asp:Label>
<a href='default5.aspx?tech=<asp:Literal ID="litDate"
runat="server"/>amp;today=selected_date'><span style="font-size: 10px">Link
Name</span></a><br />
Or just use HyperLink WebControl and fill NavigateUrl property with correct
data.
--
C# Dev
"Chanaka" wrote:
We are trying to pass the selected date from a .net calendar in a
querystring. We manage to display the selected date from the calendar in a
Lable like this :

protected void Calendar1_SelectionChanged(object sender, EventArgs e)
{
lblDate.Text = Calendar1.SelectedDate.ToShortDateString();
}

<asp:Label ID="lblDate" runat="server"></asp:Label>

What we are trying to accomplish is to pull the above value of the lable
which is "lblDate" to the following link and pass is as a querystring

<a href='default5.aspx?tech=<%# Eval("RESPONS")
%>&today=selected_date'><span style="font-size: 10px">Link
Name</span></a><br />

thnx


Nov 19 '05 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

7
by: Mick White | last post by:
According to the Safari browser the world began on "Fri Dec 13 1901 15:45:52 GMT-0500", but I need to be able to get around this limitation. I am interested in dates from 1500 to 1901, as far as...
9
by: Thomas R. Hummel | last post by:
Hello, I am importing data that lists rates for particular coverages for a particular period of time. Unfortunately, the data source isn't very clean. I've come up with some rules that I think...
4
by: tom | last post by:
Hi Experts, I want to pass the selectedDate value from my calender form to another web form or a web user control. Could you please show me how to do this? Thanks in advance.
0
by: Michael England | last post by:
I'm having trouble with the Calendar control in ASP.NET using VB. When I place a calendar on a page and then select a new date, it seems that I have to select the date twice in order for any...
2
by: mg | last post by:
When I click any date in System.Web.UI.WebControls.Calendar (C# WebForm), the SelectionChanged event handler fires. If I next click on the same date again, this event handler does not fire, so I...
1
by: Chanaka | last post by:
We are trying to pass the selected date from the .net calendar in a querystring.
1
by: TB | last post by:
Hi All: A kind soul provided by with the code for very nice calendar popup, which all in all works fine execpt for one thing: If I pick the current date (i.e. today's date) then the pop-up does...
5
by: Mark Olbert | last post by:
I just noticed something weird about the calendar control in ASPNET2. If you assign a value to SelectedDate that has a time component (e.g., 3/1/2007 10:37 AM), and you have a custom style for the...
1
by: EyeHawk | last post by:
OK, hopefully somebody can help me out again. My next problem is updating 3 form fields (type list/menu option) that correspond to a date, one for month, one for day and one for year when the user...
0
by: DolphinDB | last post by:
Tired of spending countless mintues downsampling your data? Look no further! In this article, you’ll learn how to efficiently downsample 6.48 billion high-frequency records to 61 million...
0
by: ryjfgjl | last post by:
ExcelToDatabase: batch import excel into database automatically...
1
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: Vimpel783 | last post by:
Hello! Guys, I found this code on the Internet, but I need to modify it a little. It works well, the problem is this: Data is sent from only one cell, in this case B5, but it is necessary that data...
0
by: jfyes | last post by:
As a hardware engineer, after seeing that CEIWEI recently released a new tool for Modbus RTU Over TCP/UDP filtering and monitoring, I actively went to its official website to take a look. It turned...
1
by: PapaRatzi | last post by:
Hello, I am teaching myself MS Access forms design and Visual Basic. I've created a table to capture a list of Top 30 singles and forms to capture new entries. The final step is a form (unbound)...
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
0
by: af34tf | last post by:
Hi Guys, I have a domain whose name is BytesLimited.com, and I want to sell it. Does anyone know about platforms that allow me to list my domain in auction for free. Thank you
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome former...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.