Print Page | Close Window

WorkDayStartTime and Gupta 3.0

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=5222
Printed Date: 21 November 2024 at 2:04pm
Software Version: Web Wiz Forums 12.04 - http://www.webwizforums.com


Topic: WorkDayStartTime and Gupta 3.0
Posted By: Rudiger
Subject: WorkDayStartTime and Gupta 3.0
Date Posted: 05 October 2006 at 7:49am
Hello,

using  CalendarPro 10.3.1 in Gupta SQL Windows 3.0 it's not possible to get or set the CalendarControl.Options.WorkDayStartTime and WorkDayEndTime.
When using Get it returns NULL and setting the two attributes e.g. to 1.1.0001 08:00 and 1.1.0001 17:00 has no effect to the calendar (no error, no visible effect).

Does anybody know, how to set these options in Gupta?


Thanks a lot!




Replies:
Posted By: sserge
Date Posted: 05 October 2006 at 12:35pm
Does Gupta work fine with other Calendar's properties of Date type?

--
WBR,
Serge


Posted By: g.achrainer
Date Posted: 06 October 2006 at 3:31am
Hi,
 
maybe I can help. I use the Xtreme CalendarPro Active-X with Gupta Teamdeveloper 3.1 here, and I'm very happy with it.
 
But there are some "hacks" you need to do in the Libraries that Gupta generates, one of them is yours:
 
instead of the original function, use
 
!!CB!! 279
Function: PropSetWorkDayStartTime2
 Description:
 Returns
  Boolean:
 Parameters
  Number: WorkDayStartTime
   !
 Static Variables
 Local variables
  Boolean: tmpret
 Actions
  Call __ObjectPushNumber(WorkDayStartTime, VT_DATE)
  Set tmpret = __ObjectInvoke("WorkDayStartTime", INVOKE_PUT)
  Call __ObjectFlushArgs()
  Return tmpret

the value of "WorkDayStartTime" is in days, i.e. 0.25 for 06:00 am etc. You can use the same modification for the "PropGet..." function:
 
!!CB!! 279
Function: PropGetWorkDayStartTime2
 Description:
 Returns
  Boolean:
 Parameters
  Receive Number: returnValue
   !
 Static Variables
 Local variables
  Boolean: tmpret
 Actions
  Set tmpret = __ObjectInvoke("WorkDayStartTime", INVOKE_GET)
  Call __ObjectPopNumber(-1, returnValue)
  Call __ObjectFlushArgs()
  Return tmpret
 
Regards,
 
Gerhard


Posted By: Rudiger
Date Posted: 06 October 2006 at 9:26am
Gupta works fine with all other Calendar properties of Date type as far as we have used them!

Besides the Calendar Control is a very, very good component. Compliment to all who developed this!



Posted By: Rudiger
Date Posted: 06 October 2006 at 9:30am
Thanks for the workaround code and for the amazingly fast reply to g.achrainer! Now setting and getting WorkDayStartTime and WorkDayEndTime is possible and works fine.



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