0

How to set any day/week/month as default view in zk-calendar [closed]

asked 2020-04-13 20:45:36 +0800

rsheth gravatar image rsheth
103 2

Hello All,

I'm using ZK CE-9.0.0 & zk-calendar-2.1.5.

Whenever I open the calendar by default it displays today/current week/current month as per its mold. If I want to navigate to other day/week/month, I have to use the buttons provided.

My requirement is, it should display the day/week/month specified by my program. Specified date can be in future or in past. That should be displayed by default. Can anyone tell me how can I achieve this?

Thanks,

RAS

delete flag offensive retag edit

The question has been closed for the following reason "duplicate question" by cor3000
close date 2020-04-21 10:40:12

Comments

zk-calendar-2.1.5 downloaded from (https://www.zkoss.org/download/zkcalendar)

rsheth ( 2020-04-13 20:46:00 +0800 )edit
1

I increased your Karma so you can post links and upload screenshots if needed

cor3000 ( 2020-04-14 11:27:43 +0800 )edit

1 Answer

Sort by ยป oldest newest most voted
0

answered 2020-04-14 11:25:17 +0800

cor3000 gravatar image cor3000
5250 2 7
ZK Team

ZK Calendar can be initialized as explained on the first page (2nd paragraph) of ZK Calendars Essentials

E.g. you can switch to the month view by calling:

calendars.setMold("month");

or specify a 7-days-view by calling:

calendars.setMold("default");
calendars.setDays(7);

The current date can be set by:

calendars.setCurrentDate(aDate);

Please also refer to the zk calendar javadocs

link publish delete flag offensive edit

Comments

Question tools

Follow
2 followers

RSS

Stats

Asked: 2020-04-13 20:45:36 +0800

Seen: 8 times

Last updated: Apr 14

Support Options
  • Email Support
  • Training
  • Consulting
  • Outsourcing
Learn More