Print Page | Close Window

Solved: Control Tooltip

Printed From: Codejock Forums
Category: Codejock Products
Forum Name: Report Control
Forum Description: Topics Related to Codejock Report Control
URL: http://forum.codejock.com/forum_posts.asp?TID=14486
Printed Date: 21 November 2024 at 11:06pm
Software Version: Web Wiz Forums 12.04 - http://www.webwizforums.com


Topic: Solved: Control Tooltip
Posted By: Boris
Subject: Solved: Control Tooltip
Date Posted: 09 June 2009 at 3:42pm
Hi,
 
When you set a tooltip for an item you can set its contextual style. How do you do that for the whole control so that when displaying a tip for a cell that is not wide enough and hidden by an ellipses that too uses the same contextual style??
 
Regards to all


-------------
Boris

Product: Xtreme SuitePro (ActiveX) version 16.4.0 16.3.1

Platform: Windows XP (32bit) - SP 3

Language: Visual Basic 6.0 SP6

VS 2005-2008-2010-2013



Replies:
Posted By: Aaron
Date Posted: 10 June 2009 at 11:51am
Hi,
 
I don't know what you mean, can you upload somekind of image to show what you mean?
 
Thanks
 


-------------
Product: Xtreme SuitePro (ActiveX) version 15.0.2
Platform: Windows XP (32bit) - SP 2
Language: Visual Basic 6.0

Zero replies is not an option....


Posted By: Boris
Date Posted: 10 June 2009 at 12:13pm
Hi Aaron,
 
I have merged two images into one so you can see what I mean.
 
Does this help?
 
Regards,
 


-------------
Boris

Product: Xtreme SuitePro (ActiveX) version 16.4.0 16.3.1

Platform: Windows XP (32bit) - SP 3

Language: Visual Basic 6.0 SP6

VS 2005-2008-2010-2013


Posted By: Aaron
Date Posted: 10 June 2009 at 2:50pm
hI,
 
OK, I think I understand
 
       
With wndReportControl
    With .ToolTipContext
        .Style = xtpToolTipOffice2007
    End With
End With
 
Private Sub wndReportControl_BeforeDrawRow(ByVal Row As XtremeReportControl.IReportRow, ByVal Item As XtremeReportControl.IReportRecordItem, ByVal Metrics As XtremeReportControl.IReportRecordItemMetrics)
    Item.ToolTip = Item.Caption
End Sub
 
or you assign value to ReportItem.Tooltip when adding recorditems. If you are going to edit items, you have to assign same value to tooltip text and with BeforeDrawRow event it will be done for you
 
 


-------------
Product: Xtreme SuitePro (ActiveX) version 15.0.2
Platform: Windows XP (32bit) - SP 2
Language: Visual Basic 6.0

Zero replies is not an option....


Posted By: Boris
Date Posted: 10 June 2009 at 6:02pm
Hi Aaron
 
 
Thanks for the tip. It worked! It wasn't really what I was trying to do though. I merely hoped that CJ would have provided me with a simple setting.
 
Elsewhere in my app I have an appearance routine. This detects each type of control in the form and sets this to each control on Form_Load. It saves repeating over and over the same settings for each form. Its simpler to change too!
 
I have to set this for each control manually. By using the routine mentioned I just call that when the form loads. Everything is universally set and I haven't forgeotten any settings as a result.

However, you have saved the day. By testing to see whether the tooltip has been set already (by code) I found that your code honoured that tooltip and only set it to the caption if empty

 If Item.ToolTip = vbNullString Then Item.ToolTip = Item.Caption
 
 
Cheers enjoy your evening.
 


-------------
Boris

Product: Xtreme SuitePro (ActiveX) version 16.4.0 16.3.1

Platform: Windows XP (32bit) - SP 3

Language: Visual Basic 6.0 SP6

VS 2005-2008-2010-2013



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