Calendar and VBScript |
Post Reply |
Author | |
DaveBonas
Newbie Joined: 06 February 2006 Status: Offline Points: 6 |
Post Options
Thanks(0)
Posted: 29 March 2006 at 1:57am |
Hi All, I am trying to get the calendar control working on a web page and have managed to get the basic object up and running with no problems using VB Script, but am now struggling to get things such as disabling edit events and detecting when user has clicked on an entry in the calendar and returning the data such as start time of the entry. Does anyone have a example of the calendar running using vb script which covers these kind of things that they could post, sorry for the generalisation of the question but am a noob to Vb/Script and am learing as I go. Cheers, Dave.
|
|
sserge
Moderator Group Joined: 01 December 2004 Status: Offline Points: 1297 |
Post Options
Thanks(0)
|
Hi Dave,
With VB Script it works in a little bit another way. There are 2 following solutions: 1. Old one (for versions 9.81 and earlier): ----------------------------------- Sub ccJobs_IsEditOperationDisabled(byval OpParams , CancelOperation) OpParams.DisableCancelOperation = True // NOTE: DisableCancelOperation is hidden member. End Sub 2. new one - version 10.x ----------------------------------- Sub ccJobs_IsEditOperationDisabledV(byval OpParams , CancelOperation) CancelOperation = True End Sub ----------------------------------- Both of them do the same job - just have different styles. -- WBR, Serge |
|
DaveBonas
Newbie Joined: 06 February 2006 Status: Offline Points: 6 |
Post Options
Thanks(0)
|
Thanks Serge, I have managed to disable the edit operation but am still struggling to replicate the HitTest process from the VB example in order to check what the user clicked on, any ideas on this one. Dave. |
|
sserge
Moderator Group Joined: 01 December 2004 Status: Offline Points: 1297 |
Post Options
Thanks(0)
|
This works in my test:
Sub ccJobs_DblClick() Dim HitTest Set HitTest = Document.forms(0).ccJobs.ActiveView.HitTest 'xtpCalendarHitTestEvent_Mask = 4080 If Not HitTest.HitCode and 4080 Then MsgBox "Event start = " & HitTest.ViewEvent.Event.StartTime End If End Sub |
|
Post Reply | |
Tweet
|
Forum Jump | Forum Permissions You cannot post new topics in this forum You cannot reply to topics in this forum You cannot delete your posts in this forum You cannot edit your posts in this forum You cannot create polls in this forum You cannot vote in polls in this forum |