Print Page | Close Window

[QUESTION] Chart NoItemsText

Printed From: Codejock Forums
Category: Codejock Products
Forum Name: Chart Control
Forum Description: Topics Related to Codejock Chart Control
URL: http://forum.codejock.com/forum_posts.asp?TID=18736
Printed Date: 22 November 2024 at 12:20pm
Software Version: Web Wiz Forums 12.04 - http://www.webwizforums.com


Topic: [QUESTION] Chart NoItemsText
Posted By: Xander75
Subject: [QUESTION] Chart NoItemsText
Date Posted: 27 July 2011 at 11:20am
Hi,

I have had a look but can't find any functionality that's like the ReportControl.PaintManager.NoItemsText.

Is there something like this available within the ChartControl already?

If not then is it possible to add it? Like the ReportControl it would be good to display a reason as to why there is no chart data being displayed if no data is found. I would prefer that than showing a Chart with lots of zeros.

At the moment I check to see if the ReportControl I am getting data from has records greater than zero


        If rpcGrid(1).Records.Count > 0 Then
            Set .Content.Series(1).style = New ChartLineSeriesStyle
                .Content.Series(1).style.Color = &H4080FF
                .Content.Series(1).style.Label.Format.Category = xtpChartNumber
                .Content.Series(1).style.Label.Format.UseThousandSeparator = True
                .Content.Series(1).style.Label.Format.DecimalPlaces = 2
        End If


As the Set .Content.Series(1).style = New ChartLineSeriesStyle is inside the check the Chart never gets populated with zeros (the way I want it), therefore a NoItemsText would be a nice have.

Thanks.


-------------
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)



Replies:
Posted By: Aaron
Date Posted: 27 July 2011 at 12:15pm
Hi Alexander,
 
You could add a "Title" instead
 
 
    If rpcGrid(1).Records.Count > 0 Then
        Set .Content.Series(1).style = New ChartLineSeriesStyle
               .Content.Series(1).style.Color = &H4080FF
               .Content.Series(1).style.Label.Format.Category = xtpChartNumber
               .Content.Series(1).style.Label.Format.UseThousandSeparator = True
               .Content.Series(1).style.Label.Format.DecimalPlaces = 2
    Else
 
        With Me.ChartControl
            With .Content
                With .Titles
                    .DeleteAll
                    .Add "No items available"
                End With
            End With
        End With
 
    End If
 
 
 


-------------
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: Xander75
Date Posted: 28 July 2011 at 3:21am
Hi Aaron,

Yeah I thought about that and have that in place for now, but I thought it would be nice to have some standardisation between controls.

It was just a "would be nice to have".


-------------
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)


Posted By: Aaron
Date Posted: 29 July 2011 at 5:42am
Originally posted by Xander75 Xander75 wrote:

Hi Aaron,

Yeah I thought about that and have that in place for now, but I thought it would be nice to have some standardisation between controls.

It was just a "would be nice to have".
 
Hi,
 
Yes, would be nice to have... I could add this to requests in my ChartControl post but I don't think it's worth trying... I don't even get replies for the remaining "problems" from support. So I have to say good luck LOL
 
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....



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