[CLOSED] CalendarPanel Button Next, Previous with DateField

  1. #1

    [CLOSED] CalendarPanel Button Next, Previous with DateField

    Hi Team, I want the directevent to buttons previous and next of CalendarPanel, I am tring with DateChange but, when I give clic in the button day, week and month the event is fire, and I want when the clic my control DateField change its value.

    My screen is as this:

    Click image for larger version. 

Name:	CalendarPanelWithDateField.png 
Views:	16 
Size:	14.4 KB 
ID:	7014

    Regards
    Last edited by Daniil; Oct 15, 2013 at 6:40 AM. Reason: [CLOSED]
  2. #2
    Hello!

    I don't quite understand you but it seems you should call onNextClick method:

    public void ButtonClick(object sender, DirectEventArgs e)
    {
        this.CalendarPanel1.Call("onNextClick");
    }
    To show previous period you can use onPrevClick

    this.CalendarPanel1.Call("onPrevClick");
  3. #3
    Quote Originally Posted by Baidaly View Post
    Hello!

    I don't quite understand you but it seems you should call onNextClick method:

    public void ButtonClick(object sender, DirectEventArgs e)
    {
        this.CalendarPanel1.Call("onNextClick");
    }
    To show previous period you can use onPrevClick

    this.CalendarPanel1.Call("onPrevClick");
    I'am sorry Baidaly for my bad english or expression.

    How Can I do to change the date of control DateField when I get to do click in the Buttons Previous and Next of CalendarPanel (where are buttons day, week, month) in the Day View?
  4. #4
    Hi,

    Seems the functionality you need is presented in this example:
    https://examples2.ext.net/#/Calendar/Overview/Basic/

    Just there is a DatePicker instead of a DateField. But it doesn't matter.

    A CalendarPanel's ViewChange event is being listened to.
    <ViewChange  Fn="CompanyX.viewChange" Scope="CompanyX" />
    viewChange : function (p, vw, dateInfo) {
        var win = this.getWindow();
            
        if (win) {
            win.hide();
        }
            
        if (dateInfo) {
            // will be null when switching to the event edit form, so ignore
            this.DatePicker1.setValue(dateInfo.activeDate);
            this.updateTitle(dateInfo.viewStart, dateInfo.viewEnd);
        }
    }
    Please note the setValue call on the DatePicker1.

Similar Threads

  1. Replies: 5
    Last Post: Mar 19, 2013, 3:27 AM
  2. [CLOSED] Back button returns focus to previous control in IE
    By michaeld in forum 1.x Legacy Premium Help
    Replies: 4
    Last Post: Mar 04, 2013, 8:20 AM
  3. [CLOSED] Cancel button event if wrong date in datefield
    By nhg_itd in forum 1.x Legacy Premium Help
    Replies: 3
    Last Post: Oct 11, 2011, 8:25 AM
  4. [CLOSED] [SOLVED] Datefield with spinner (next-previous)
    By softmachine2011 in forum 1.x Legacy Premium Help
    Replies: 3
    Last Post: Jun 29, 2011, 8:39 AM
  5. Replies: 1
    Last Post: Dec 06, 2010, 8:49 PM

Tags for this Thread

Posting Permissions