Codejock Forums Homepage
Forum Home Forum Home > Codejock Products > ActiveX COM > Calendar
  New Posts New Posts RSS Feed - SelectSatrtTime/EndTime
  FAQ FAQ  Forum Search   Events   Register Register  Login Login

SelectSatrtTime/EndTime

 Post Reply Post Reply
Author
Message
moe188 View Drop Down
Senior Member
Senior Member


Joined: 27 March 2006
Status: Offline
Points: 220
Post Options Post Options   Thanks (0) Thanks(0)   Quote moe188 Quote  Post ReplyReply Direct Link To This Post Topic: SelectSatrtTime/EndTime
    Posted: 15 August 2006 at 3:34pm
Hi,
I am using 2 text box (TxtStartTime and TxtEndTime), and I want to select to display the calendar control and set focus on the selection (TxtStartTme and TxtEndTime).
Code:
CalendarControl.Dayview.GetSelection TxtStartTime,TxtEndTime,False
 
I get this error message:
run time error 13, or Type mismatch
 
Thank you for your help
 
Back to Top
jcollier View Drop Down
Senior Member
Senior Member


Joined: 15 February 2006
Status: Offline
Points: 250
Post Options Post Options   Thanks (0) Thanks(0)   Quote jcollier Quote  Post ReplyReply Direct Link To This Post Posted: 16 August 2006 at 8:54am
Try this:

CalendarControl.DayView.GetSelection CDate(txtStartTime), CDate(txtEndTime), False
Back to Top
moe188 View Drop Down
Senior Member
Senior Member


Joined: 27 March 2006
Status: Offline
Points: 220
Post Options Post Options   Thanks (0) Thanks(0)   Quote moe188 Quote  Post ReplyReply Direct Link To This Post Posted: 16 August 2006 at 12:11pm

same error message, but thank you anyway

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: 24 August 2006 at 3:56am
Hi,

Actually the problem is because GetSelection returns all 3 values, and the last one shows whether is it "all day" area selection. And you're trying to return a value to a constant (False).

So far, a solutioon would be to call this method having all 3 variables:

Dim dtBegin As Date, dtEnd As Date, bAllDay As Boolean
CalendarControl.DayView.GetSelection dtBegin, dtEnd, bAllDay


--
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.141 seconds.