473,508 Members | 2,357 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Repost: Calendar Issue!

Hi all,

I have a page containing a aspx calendar.
This page appears in a pop up window via a javascript open window command.

What i need to acheive is, once a user has selected a date.
This window is to close and pass back the selected date to the calling page.

In classic asp i would use the following javascript when a user selected a
calendar item to achieve this:
javascript:self.opener.set_date('myFormElement','m ydateval');
window.close();

I have tried attaching this to the aspx calendar via the OnDayRender Method;
thus adding the javascript to the calendar cells. But when i select a date
nothing happens.

Any ideas on what i need to do or how i can acheive this with .net?

Any suggestions appreciated!

Cheers,
Adam

Nov 19 '05 #1
4 1130
Problem solved!!!

"Adam Knight" <ad**@pertrain.com.au> wrote in message
news:uz**************@TK2MSFTNGP14.phx.gbl...
Hi all,

I have a page containing a aspx calendar.
This page appears in a pop up window via a javascript open window command.

What i need to acheive is, once a user has selected a date.
This window is to close and pass back the selected date to the calling
page.

In classic asp i would use the following javascript when a user selected a
calendar item to achieve this:
javascript:self.opener.set_date('myFormElement','m ydateval');
window.close();

I have tried attaching this to the aspx calendar via the OnDayRender
Method;
thus adding the javascript to the calendar cells. But when i select a date
nothing happens.

Any ideas on what i need to do or how i can acheive this with .net?

Any suggestions appreciated!

Cheers,
Adam

Nov 19 '05 #2
Hi, Adam.

Would you please post the solution, so all can benefit from it ?

Thanks!

Juan T. Llibre, ASP.NET MVP
ASP.NET FAQ : http://asp.net.do/faq/
Foros de ASP.NET en Español : http://asp.net.do/foros/
======================================
"Adam Knight" <ad**@pertrain.com.au> wrote in message
news:uT*************@tk2msftngp13.phx.gbl...
Problem solved!!!
"Adam Knight" <ad**@pertrain.com.au> wrote in message
news:uz**************@TK2MSFTNGP14.phx.gbl...
Hi all,

I have a page containing a aspx calendar.
This page appears in a pop up window via a javascript open window command.

What i need to acheive is, once a user has selected a date.
This window is to close and pass back the selected date to the calling page.

In classic asp i would use the following javascript when a user selected a calendar
item to achieve this:
javascript:self.opener.set_date('myFormElement','m ydateval');
window.close();

I have tried attaching this to the aspx calendar via the OnDayRender Method;
thus adding the javascript to the calendar cells. But when i select a date nothing
happens.

Any ideas on what i need to do or how i can acheive this with .net?

Any suggestions appreciated!

Cheers,
Adam


Nov 19 '05 #3
ae
how did you solve it?

"Juan T. Llibre" wrote:
Hi, Adam.

Would you please post the solution, so all can benefit from it ?

Thanks!

Juan T. Llibre, ASP.NET MVP
ASP.NET FAQ : http://asp.net.do/faq/
Foros de ASP.NET en Español : http://asp.net.do/foros/
======================================
"Adam Knight" <ad**@pertrain.com.au> wrote in message
news:uT*************@tk2msftngp13.phx.gbl...
Problem solved!!!


"Adam Knight" <ad**@pertrain.com.au> wrote in message
news:uz**************@TK2MSFTNGP14.phx.gbl...
Hi all,

I have a page containing a aspx calendar.
This page appears in a pop up window via a javascript open window command.

What i need to acheive is, once a user has selected a date.
This window is to close and pass back the selected date to the calling page.

In classic asp i would use the following javascript when a user selected a calendar
item to achieve this:
javascript:self.opener.set_date('myFormElement','m ydateval');
window.close();

I have tried attaching this to the aspx calendar via the OnDayRender Method;
thus adding the javascript to the calendar cells. But when i select a date nothing
happens.

Any ideas on what i need to do or how i can acheive this with .net?

Any suggestions appreciated!

Cheers,
Adam



Nov 19 '05 #4
Hi guys,

Attaching the following code to the OnDayRender method of the Calendar works
fine:

javascript:self.opener.set_date('myFormElement','m ydateval');
window.close();

My problem was an oversight; i failed to specify the correct
'myFormElement'.

Here is the javascript function used: (parent window)
// JavaScript Document
function set_date(jsId, date_val) {

var fromEl = document.getElementById(jsId);
fromEl.value = date_val;

}

Cheers,
Adam

"Adam Knight" <ad**@pertrain.com.au> wrote in message
news:uz**************@TK2MSFTNGP14.phx.gbl...
Hi all,

I have a page containing a aspx calendar.
This page appears in a pop up window via a javascript open window command.

What i need to acheive is, once a user has selected a date.
This window is to close and pass back the selected date to the calling
page.

In classic asp i would use the following javascript when a user selected a
calendar item to achieve this:
javascript:self.opener.set_date('myFormElement','m ydateval');
window.close();

I have tried attaching this to the aspx calendar via the OnDayRender
Method;
thus adding the javascript to the calendar cells. But when i select a date
nothing happens.

Any ideas on what i need to do or how i can acheive this with .net?

Any suggestions appreciated!

Cheers,
Adam

Nov 19 '05 #5

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

Similar topics

6
516
by: Mason | last post by:
I have a quick, probably easy, question about Lebans' calendar program. I have a form that allows a user to click on different technicians. When this happens, Lebans' calendar comes up with...
4
1903
by: Andrew Chanter | last post by:
I recently installed Stephan Lebans calendar control into an application. Only problem is that it always launches at the extreme right of the screen with most of the dialog off screen. I am...
16
3036
by: DFS | last post by:
If you're listening, I want the middle of the calendar (showing 1 month) to open below the cursor position. It currently opens just to the right and below the cursor position. I hunted through...
3
1846
by: Adam | last post by:
I've posted about this previously, but failed to receive a satisfactory response, so have included a code sample: I am trying to receive messages from an HTML viewer control in compact.net (c#),...
7
2675
by: Colin Young | last post by:
I have a UserControl that contains a calendar control. The calendar is not raising events (month navigation, date selections, etc.). I've checked that the OnSelectionChanged event has a handler...
5
4589
by: Miguel Dias Moura | last post by:
Hello, i am trying to create a .css file with several styles and apply them to the calendar control so i can change the look of: 1. Text Type and Format (Bold, Underline, etc) 2. Background...
4
3732
by: Nad | last post by:
Hello, I have a user control that has a button and a Calendar. Once you click on the button I display the calendar. Now when I move this user control to a web form, once I click on this button...
4
2318
by: raghav | last post by:
Hi Friends I am having very small issue. I am using calendar control which is available in .net 2005 to display date. When a user clicks on image button, calendar is opening very well. He selects...
24
9644
by: =?Utf-8?B?Tkg=?= | last post by:
I have a basic calendar and a SelectionChanged event (asp.net 2.0). How can I handle it when a user chooses the same date again, in this case the SelectionChanged event is not fired because,...
0
7224
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
7120
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
7323
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
7380
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
7494
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
5626
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
1
5050
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 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 a new...
0
4706
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and...
0
1553
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated ...

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.