DateTimePicker in RC Item |
Post Reply |
Author | ||
kerog
Newbie Joined: 21 March 2012 Status: Offline Points: 2 |
Post Options
Thanks(0)
Posted: 24 September 2012 at 5:24am |
|
How to add custom control to ReportRecordItem? I'd like to add to Item DateTimePicker. Can you give an example ho to do it? Regards |
||
Product: Xtreeme SuitePro (activeX) v. 15.3.1
Platform: MS Vista Buisness (32bit) SP2 PL IDE: PowerBuilder 11.5.1 |
||
Xander75
Senior Member Joined: 26 April 2007 Status: Offline Points: 353 |
Post Options
Thanks(0)
|
|
Hi,
The following code example shows how to add the DateTimePicker control, but can be used for any control. The original version of this code is found at: http://forum.codejock.com/forum_posts.asp?TID=18679&KW=DateTimePicker&title=adding-control-please-help However I have changed the code to use the BeginEdit event as this works better than FocusChanging. I also tweaked the code to set the position relative to the ReportControls position, as this is not always set as Left = 0 and Top = 0 on the screen. The code for showing/hiding the DateTimePicker has been added to a module so this can be reusable for any ReportControl. Note: I prefer to use the MSComCtl2.DTPicker instead of Codejocks XtremeSuiteControls.DateTimePicker as it allows me to change the colours. I find the XtremeSuiteControls.DateTimePicker Day names to be unreadable when used in conjunction with the SkinFramework control. Plus if you use the XtremeSuiteControls.DateTimePicker you will find the navigation on press of the Tab key doesn't quite work correctly as when the DateTimePicker has focus it then moves out of the ReportControl into other controls even with TabStop set as false! Using the MSComCtl2.DTPicker resolves this when setting TabStop to False allowing the Tab key navigation to flow correctly within the ReportControl even when the DTPicker has focus. Form Code
Module Code
|
||
Product: Xtreme SuitePro (ActiveX) v15.3.1
Platform: Windows 7 64-bit (SP1) Professional Edition Languages: C#.Net using Visual Studio 2012 & Visual Basic 6.0 (SP6) |
||
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 |