Print Page | Close Window

DatePicker

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=14453
Printed Date: 18 July 2025 at 7:16pm
Software Version: Web Wiz Forums 12.04 - http://www.webwizforums.com


Topic: DatePicker
Posted By: Jeff B
Subject: DatePicker
Date Posted: 04 June 2009 at 1:15pm
I am trying to get a handle on how to use the Codejock controls and am getting stumped.

I use xHarbour/Fivewin.


This is how I connect to the control:

oAct := TActiveX():New( oWnd, "Codejock.CalendarControl.13.0.0", 100, 0, 1000, 550 )  

All of these commands (with some trial and error) are now working:

      oAct:SetDataProvider:="Provider=XML;Data Source=\FusionEMR\Events.xml"
      oAct:DataProvider:Open()
      oAct:DayView:Timescale := 30
      oAct:ActiveView:ShowDay:= Date()
      oAct:ViewType:=xtpCalendarDayView
      oAct:Options:WorkDayStartTime("8:00:00 AM")
      oAct:Options:WorkDayEndTime("8:00:00 PM")
      oAct:DayView:ScrollToWorkDayBegin()
      oAct:VisualTheme:=xtpCalendarThemeOffice2007
      oAct:ShowTimelineButton:=  .f.
      oAct:ShowCaptionBar:= .t.
      oAct:ShowCaptionBarScrollDateButtons:= .t.
      oAct:ViewType:= xtpCalendarWorkWeekView
      oAct:Options:EnablePrevNextEventButtons:=.f.


I just can not figure out some of the different controls like DataPicker.

Can someone please help me with the formatting of the command based on what I used above? 






Replies:
Posted By: Jeff B
Date Posted: 04 June 2009 at 9:43pm
I have the DatePicker now on screen.  Didn't realize I had to do:
oDate:= TActiveX():New( oWnd, "Codejock.DatePicker.13.0.0", 100, 0, 200, 550 )          

Now, I tried to issue:
oDate:AttachToCalendar(oAct)   but it is not working.  Do I need to do something else before this?




Posted By: skiman
Date Posted: 06 June 2009 at 4:55am
Hi,
 
This seems correct to me. I use it this way in Xbase++, and it is working.
 
This are my steps:
- Create datepicker oDatepicker
- Create calendar oCalendar
- oDatePicker:attachToCalendar(oCalendar)
- setdataprovider...
- ....
 
Regards,
Chris.


-------------
ABO Service


Posted By: Jeff B
Date Posted: 06 June 2009 at 9:35am
Hi Chris,

Thanks for the reply...

I keep getting an error stating "Member not found" which refers to "AttachToCalendar"

I just can't figure out why :-(




Posted By: Jeff B
Date Posted: 16 June 2009 at 4:43pm
Problem Solved.

Had to do it this way (oAct is the Calendat Object, oDate is the DatePicker object):


oDate:AttachToCalendar( TOleAuto():New( ActXPdisp( oAct:hActiveX ) ) )





-------------
Thanks,
Jeff
--------------------------------------------
Product: Codejock 13.0.0 (ActiveX)
Language: xHarbour / Fivewin
OS: Windows XP (32bit)



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