Codejock Forums Homepage
Forum Home Forum Home > Codejock Products > ActiveX COM > Calendar
  New Posts New Posts RSS Feed - Again: Setting up Multiple resources with M$ SQL
  FAQ FAQ  Forum Search   Events   Register Register  Login Login

Again: Setting up Multiple resources with M$ SQL

 Post Reply Post Reply
Author
Message
flauzer View Drop Down
Senior Member
Senior Member
Avatar

Joined: 30 December 2003
Location: Italy
Status: Offline
Points: 108
Post Options Post Options   Thanks (0) Thanks(0)   Quote flauzer Quote  Post ReplyReply Direct Link To This Post Topic: Again: Setting up Multiple resources with M$ SQL
    Posted: 18 August 2006 at 6:32am
Sorry but (for me) the whole architecture of Multiple-Resource is source of confusion.
 
Suppose that the user A is enabled to see the events of resource R1 and R2....in the code we map "name" R1 e R2 with 2 long ScheduleIDs, with some Hash function....
In SQL event table we add ScheduleID field.
 
1) ..User A can view 2 resource so:
 

pRes0.Name = "Resource1"

pRes0.ScheduleIDs.Add HashforR1

arResources.Add pRes0

 

pRes1.Name = "Resource2"

pRes1.ScheduleIDs.Add hashForR2

arResources.Add pRes1
 
2) BUT  my problem is with providerSQLServer and SQLDataHelper:
 
I Must modify also code in property (MakeRetrieveDayEventsSQL, and so on)  to manage SQL SELECT  in accord with the scheduleID ??
 
Thanks
 
 
 
 
 
 
 
 
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: 21 August 2006 at 2:21pm
Yes, you must...
 
Note: Calendar expects that ScheduleID values (which you set to resources and events) should present in DataProvider.Schedules collection. (you have to fill it as well)

When you add a new Schedule to DataProvider.Schedules collection, the element's index is assigned as ID by default, but you can easily change ID to your value (other hash or something).

ps: attached see updated files from VB sample:
uploads/20060821_154751_f4827.zip

--
WBR,
Serge
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.156 seconds.