|
Rank: Member Groups: Member
Joined: 9/22/2008 Posts: 14
|
Hello, I'm using datepicker object and I want to use "ClientSideOnChange" client event. So it's not working for me, it fires javascript error: [object expected] I setup object like that: Quote:ClientSideOnChange="alert('aaa')" At the end i want to do this utility: In my page I have two datepickers when i change first date picker it have to change datepicker2 on the same date of datepicker1 So i stay on first step "ClientSideOnChange" client event doesn't works for me. What i'm doing wrong? Thank you.
|
|
Rank: Administration Groups: Administration
Joined: 5/27/2007 Posts: 24,194
|
Hi,
ClientSideOnChange takes a function name, not inline JavaScript code. So whatever you want to call you have to put it inside a function first.
Thanks!
|
|
Rank: Member Groups: Member
Joined: 9/22/2008 Posts: 14
|
Hello,
Thank you so I check before with a javascript function as:
ClientSideOnChange="MyFunction()"
And then I setup this function in javascript module.
And it doesn't work as well.
Thank you.
|
|
Rank: Administration Groups: Administration
Joined: 5/27/2007 Posts: 24,194
|
Hi,
The name of the function is "MyFunction", not "MyFunction()".
Thanks
|
|
Rank: Member Groups: Member
Joined: 9/22/2008 Posts: 14
|
Hello, Right, sorry now it works.
So I cannot set a value on datepiker obj on javascript. I mean, in this javascript function I want to copy value of this datepicker to another datepicker in the same page.
I have tried with:
document.getElementById('_eo__ctl0_ContentPlaceHolder1_DpckDeparture_picker').value=document.getElementById('_eo__ctl0_ContentPlaceHolder1_DpckArrival_picker').value;
On "_eo__ctl0_ContentPlaceHolder1_DpckArrival_picker'" is id of input type text rendered by asp object. Is this way right? It doesn't works for me.
How can change datepicker value in a javascript?
Thank you for your fast responses.
|
|
Rank: Administration Groups: Administration
Joined: 5/27/2007 Posts: 24,194
|
Hi, You will want to go over this topic first: http://www.essentialobjects.com/ViewDoc.aspx?t=clientapi_howto.htmlThat should get you started about how to use our client side JavaScript APIs. It's not as what you thought. :) Thanks
|
|