All docs
V25.1
25.2
25.1
24.2
24.1
23.2
23.1
22.2
22.1
21.2
21.1
20.2
20.1
19.2
The page you are viewing does not exist in version 19.2.
19.1
The page you are viewing does not exist in version 19.1.
18.2
The page you are viewing does not exist in version 18.2.
18.1
The page you are viewing does not exist in version 18.1.
17.2
The page you are viewing does not exist in version 17.2.

JavaScript/jQuery Scheduler - View Switcher

The view switcher is a predefined toolbar item that allows users to switch between Scheduler views.

View Switcher

To specify available views, configure the views array. To specify the current view, configure the currentView property:

jQuery
<!-- index.js -->
$(function(){
    $("#schedulerContainer").dxScheduler({
        // ...
        views: ['day', 'week', 'agenda']
        currentView: 'day',
    });
});
Angular
<!-- app.component.html -->
<dx-scheduler ...
    [views]="views"
    currentView="day"
></dx-scheduler>

<!-- app.component.ts -->
import { DxSchedulerModule } from "devextreme-angular";

// ...
export class AppComponent {
    views = ['day', 'week', 'agenda'];
}
@NgModule({
    imports: [
        // ...
        DxSchedulerModule
    ],
})
Vue
App.vue
<template>
    <DxScheduler
        :views="views"
        current-view="day"
    />
</template>

<script>
import 'devextreme/dist/css/dx.fluent.blue.light.css';

import { DxScheduler } from 'devextreme-vue/scheduler';

const views = ['day', 'week', 'agenda'];
</script>
React
App.tsx
import React from 'react';

import 'devextreme/dist/css/dx.fluent.blue.light.css';
import { Scheduler } from 'devextreme-react/scheduler';

const views = ["day", "week", "agenda"];

function App () {
    return (
        <Scheduler
            views={views}
            currentView="day"
        />
    );
}
NOTE
Be sure to include the currentView value in the views array.

On mobile devices, Scheduler displays the view switcher as a drop-down menu:

Drop-down View Switcher

To integrate the drop-down menu view switcher on other devices, enable useDropDownViewSwitcher.

See Also