Print Page | Close Window

Multi schedule in Visual FoxPro

Printed From: Codejock Forums
Category: Codejock Products
Forum Name: Calendar
Forum Description: Topics Related to Codejock Calendar
URL: http://forum.codejock.com/forum_posts.asp?TID=18006
Printed Date: 08 July 2024 at 4:31pm
Software Version: Web Wiz Forums 12.04 - http://www.webwizforums.com


Topic: Multi schedule in Visual FoxPro
Posted By: foxpro2000
Subject: Multi schedule in Visual FoxPro
Date Posted: 07 March 2011 at 2:55am

Again talking in FOXPRO way :

1 . You need to create a CalendarResources collection :

calResourceS = createobject("Codejock.CalendarResourceS.11.2.2")

2. Create a calendar Resource object for each Schedule that you want

Sche1 = createobject("Codejock.CalendarResource.11.2.2")

and for each Schedule created, set some properties :

Sche1.name = �title for schedule1�

Sche1.setDataProvider2(�memory�, false)
dataProvider1 = sche1.dataProvider
dataProvider1.create()

Sche1.ScheduleIDs.Add(nID1) � One for each ID for Schedule
Sche1.ScheduleIDs.Add(nID2) � One for each ID for Schedule



Sche2 = createobject("Codejock.CalendarResource.11.2.2")

Sche2.name = �title for schedule1�
Sche2.setDataProvider2(�memory�, false)
dataProvider2 = sche1.dataProvider
dataProvider2.create()

Sche1.ScheduleIDs.Add(nID3) � One for each ID for Schedule

Sche3�Sche4�


3.  Add the schedule to Schedule collections
CalResourceS.Add( Sche1 )
CalResourceS.Add( Sche2 )
CalResourceS.Add( ScheN )


4 Inform the control that you want multiples resource :
.SetMultipleResources( CalResourceS )

5 Each event must be populated in the righ dataprovider

If a then 

Can someone explain the variable "a" to whom is assigned?


 dataP =.MultipleResources.Item(0).DataProvider
else
dataP =.MultipleResources.Item(1).DataProvider
end if


Set objEvent = dataP.CreateEvent()


dataP.AddEvent objEvent

 



Replies:
Posted By: foxpro2000
Date Posted: 21 March 2011 at 3:14am
Help



Print Page | Close Window

Forum Software by Web Wiz Forums® version 12.04 - http://www.webwizforums.com
Copyright ©2001-2021 Web Wiz Ltd. - https://www.webwiz.net