Codejock Forums Homepage
Forum Home Forum Home > Codejock Products > ActiveX COM > Calendar
  New Posts New Posts RSS Feed - ScheduleID
  FAQ FAQ  Forum Search   Events   Register Register  Login Login

ScheduleID

 Post Reply Post Reply
Author
Message
mengo View Drop Down
Newbie
Newbie


Joined: 09 June 2006
Status: Offline
Points: 4
Post Options Post Options   Thanks (0) Thanks(0)   Quote mengo Quote  Post ReplyReply Direct Link To This Post Topic: ScheduleID
    Posted: 09 June 2006 at 7:21am

Hi to all. I'am new there...

I've an easy question... In a calenda with multiple schedule, Can I retrive a scheduleid without selecting an event on my calendar control?

Grazie,

Mengo, Italy.

Back to Top
sserge View Drop Down
Moderator Group
Moderator Group


Joined: 01 December 2004
Status: Offline
Points: 1297
Post Options Post Options   Thanks (0) Thanks(0)   Quote sserge Quote  Post ReplyReply Direct Link To This Post Posted: 09 June 2006 at 8:39am
Welcome here 

You can access ScheduleID values in a number of ways, the most straightforward is following:

CalendarControl.DataProvider.Schedules(nIndex).Id


--
WBR,
Serge
Back to Top
mengo View Drop Down
Newbie
Newbie


Joined: 09 June 2006
Status: Offline
Points: 4
Post Options Post Options   Thanks (0) Thanks(0)   Quote mengo Quote  Post ReplyReply Direct Link To This Post Posted: 09 June 2006 at 11:45am

... the selected scheduleId on calendarcontrl, I don't know (nIndex) value... maybe i found... CalendarControl.DataProvider.Selection.globalindex does it right?

Mengo.-
Back to Top
sserge View Drop Down
Moderator Group
Moderator Group


Joined: 01 December 2004
Status: Offline
Points: 1297
Post Options Post Options   Thanks (0) Thanks(0)   Quote sserge Quote  Post ReplyReply Direct Link To This Post Posted: 10 June 2006 at 12:01pm
what do you mean by selected scheduleId ?

.Selection.globalindex is not our member, correct one is:
CalendarControl .ActiveView.Selection.GroupIndex

Example:

nGrIndex = CalendarControl .ActiveView.Selection.GroupIndex
nSchCount = CalendarControl .ActiveView.Days(0).ViewGroups(nGrIndex).MultipleResources(0 ).ScheduleIDs.Count
If nSchCount = 1 Then
   nSelectedScheduleID = CalendarControl .ActiveView.Days(0).ViewGroups(nGrIndex).MultipleResources(0 ).ScheduleIDs(0)
ElseIf nSchCount > 1 Then
   // in this case a few schedules is shown in one group
   //
   // by default for month and week views nSchCount > 1
Else
   // nSchCount = 0
   // all schedules are shown in such group
EndIf


--
WBR,
Serge
Back to Top
mengo View Drop Down
Newbie
Newbie


Joined: 09 June 2006
Status: Offline
Points: 4
Post Options Post Options   Thanks (0) Thanks(0)   Quote mengo Quote  Post ReplyReply Direct Link To This Post Posted: 12 June 2006 at 7:43am

I wrong...!

I wrote the post without remember the real source code...

 

Tnx!

Mengo.-
Back to Top
 Post Reply Post Reply
  Share Topic   

Forum Jump Forum Permissions View Drop Down

Forum Software by Web Wiz Forums® version 12.04
Copyright ©2001-2021 Web Wiz Ltd.

This page was generated in 0.202 seconds.