Sign in to follow this  
maks

Tooltip max character size

Recommended Posts

Hi:

 Can someone tell me the maximum character size of cahrt tooltip.

I am displaying a database comment field as tooltip in my chart.

But sometime chart does not appear and I know this is because of the tooltip text size. 

I have no idea about the max character length of tooltip.

Also I can't see the whole tooltip text (begining text is disappeared)

How can I make set the tooltip text in broken line so that the whole comment can be viewed.

Thanks in advance.

Maksuda

Edited by Guest

Share this post


Link to post
Share on other sites

Hello Maksuda,

If you want to add newline breaks to the tooltip, could you please add to the display string, and try again?

It should look something like:

hoverText="This is in a line ;This is in a new line"

I hope this helps! :)

Share this post


Link to post
Share on other sites

Thanks Dhruva:

In this case my tooltip text is a database field. I'm retriving data as follow:

DataTable myDataTable = DtSet.Tables[0];
foreach (DataRow dRow in myDataTable.Rows)
{
string comment = dRow["Comments"].ToString();
xmlData.AppendFormat("<set value='{0}' tooltext='{1}' />", dRow["Total"].ToString(), dRow["Comments"].ToString());
}
xmlData.Append("</dataset>");

How could I use new line lag here that you told ?

any kind of coding help is highly appriciated.

 

Thanks,

Maksuda...

Share this post


Link to post
Share on other sites

Hello again, Maksuda,

Could you please confirm if you are using FusionCharts Free, or FusionCharts v3?

This information is needed because the two versions have different attributes.

Also, could you please attach the generated XML so that we may have a look at it?

Share this post


Link to post
Share on other sites

Thank you Dhruva for the reply.

I think It's FusionCharts Free (I downloaded the Trial Version from website- but I was it is also v3 I think, so I'm confused about FusionCharts Free and FusionCharts v3 )

Here is my generated XML code:

  - <chart labelDisplay="[b]Rotate[/b]" slantLabels="[b]1[/b]" caption="NETWORK[b] REPORTING[/b]" subCaption="[b]Quarterly[/b]" pieSliceDepth="[b]30[/b]" showBorder="[b]0[/b]" 	 numberSuffix="[b][/b]" seriesNameInToolTip="[b]1[/b]" XAXISNAME="[b]Fiscal Quarter[/b]"     YAXISNAME="[b]No of Events[/b]" lineThickness="[b]5[/b]" reverseLegend="[b]0[/b]" anchorAlpha="[b]100[/b]" anchorRadius="[b]5[/b]" setAdaptiveYMin="[b]5[/b]" 	 drawAnchors="[b]1[/b]" numberScaleValue="[b]1000,1000,1000[/b]" numberScaleUnit="[b]K,M,B[/b]" formatNumber="[b]1[/b]" formatNumberScale="[b]1[/b]">- <categories>  <category label="[b]Q1-2008[/b]" />   <category label="[b]Q2-2008[/b]" />   <category label="[b]Q3-2008[/b]" />   <category label="[b]Q4-2008[/b]" />   </categories>- <dataset seriesName="[b]A[/b]" showValues="[b]0[/b]">  <set value="[b]21376661[/b]" tooltext="[b][/b]" />   <set value="[b]16411446[/b]" tooltext="[b][/b]" />   <set value="[b]18035111[/b]" tooltext="[b][/b]" />   <set value="[b]17572169[/b]" tooltext="Test [b]A comment is posted[/b]" />   </dataset>- <dataset seriesName="[b]B[/b]" showValues="[b]0[/b]">  <set value="[b]3486329[/b]" tooltext="[b][/b]" />   <set value="[b]5320359[/b]" tooltext="[b][/b]" />   <set value="[b]10395536[/b]" tooltext="[b][/b]" />   <set value="[b]12248346[/b]" tooltext="[b]Good Maksuda3[/b]" />   </dataset>- <dataset seriesName="[b]C[/b]" showValues="[b]0[/b]">  <set value="[b]161565632[/b]" tooltext="[b]Obvious question here - please explain this huge spike in C activity. - Maksuda[/b]" />   <set value="[b]12527735[/b]" tooltext="[b]null[/b]" />   <set value="[b]6119261[/b]" tooltext="[b][/b]" />   <set value="[b]6236180[/b]" tooltext="[b]Good Maksuda4[/b]" />   </dataset>- <dataset seriesName="[b]D[/b]" showValues="[b]0[/b]">  <set value="[b]2339025[/b]" tooltext="[b][/b]" />   <set value="[b]2070100[/b]" tooltext="[b][/b]" />   <set value="[b]116600[/b]" tooltext="[b][/b]" />   <set value="[b]21551[/b]" tooltext="[b]Good Maksuda5[/b]" />   </dataset>- <dataset seriesName="E" showValues="[b]0[/b]">  <set value="[b]697762[/b]" tooltext="[b][/b]" />   <set value="[b]1024645[/b]" tooltext="[b][/b]" />   <set value="[b]1051015[/b]" tooltext="[b][/b]" />   <set value="[b]5321449[/b]" tooltext="[b]Test E comment is posted[/b]" />   </dataset>- <dataset seriesName="F" showValues="[b]0[/b]">  <set value="[b]897074[/b]" tooltext="[b][/b]" />   <set value="[b]3882617[/b]" tooltext="[b][/b]" />   <set value="[b]2861059[/b]" tooltext="[b][/b]" />   <set value="[b]1346998[/b]" tooltext="[b]Good Maksuda7[/b]" />   </dataset>- <styles>- <definition>  <style name="[b]CanvasAnim[/b]" type="[b]animation[/b]" param="[b]_xScale[/b]" start="[b]100[/b]" duration="[b]1[/b]" />   <style name="[b]myHTMLFont[/b]" type="[b]font[/b]" isHTML="[b]1[/b]" />   <style name="[b]CapstionStyle[/b]" type="[b]font[/b]" face="[b]Arial[/b]" size="[b]18[/b]" color="[b]6A5ACD[/b]" bold="[b]0[/b]" bgColor="[b]FFFFFF[/b]" />   <style name="[b]SubCapstionStyle[/b]" type="[b]font[/b]" face="[b]Arial[/b]" size="[b]16[/b]" color="[b]6A5ACD[/b]" bold="[b]1[/b]" bgColor="[b]FFFFFF[/b]" />   </definition>- <application>  <apply toObject="[b]Canvas[/b]" styles="[b]CanvasAnim[/b]" />   <apply toObject="[b]Caption[/b]" styles="[b]CapstionStyle[/b]" />   <apply toObject="[b]SubCaption[/b]" styles="[b]SubCapstionStyle[/b]" />   <apply toObject="[b]TOOLTIP[/b]" styles="[b]myHTMLFont[/b]" />   </application>  </styles>  </chart>

 

Thanks,

Maksuda

Share this post


Link to post
Share on other sites

Hello Maksuda,

You are using FusionCharts v3 Evaluation. :) 

It has all the features of the FusionCharts v3, and is different from FusionCharts Free.

What you need to do here is write some code, which will automatically place the  string inside the tooltext string at some suitable location.

I suggest you proceed thus:

1. Calculate the string length of the tooltext string in the generated XML.

2. If the string exceeds a certain predefined length, locate the central word.

3. Append the string at the end of the central word, and before the next word.

For eg, something like this:

<set value="[b]161565632[/b]" tooltext="Obvious question here - please explain this huge spike in C activity. - Maksuda" />

 

I hope this helps! :)

Share this post


Link to post
Share on other sites

Thank you Dhruva, thank you very much. :)

Yes it worked for me and I'm getting perfect Tooltip now

Thanks for the help again.

Maksuda

:)

Share this post


Link to post
Share on other sites

Hi Dhruva: <?xml:namespace prefix = o ns = "urn:schemas-microsoft-com:office:office" />

I appreciate your help and support.

Another thing which is creating problem displaying my chart -

when users brows site and post comments, they very natuarally press enter button to go to next line.

And after that chart related with that data does no appear.

I tested and figured it out that enter causes the problem to show up the chart.

Is there any way that I can overcome the problem.

I can't ask the users "please don't press enter when you submit comments".

Thanking you,

Maksuda...

Edited by Guest

Share this post


Link to post
Share on other sites

Hi Dhruva :

Thank you for the mail. I'm afraid I may not do that.

The project is running on company database which has all live data. And according to company rule nobody allows to do that. So I can't help you regarding this.

Is there anything that I can do that will let you helping me to solve the prob?

Thanking You,

Maksuda...

Edited by Guest

Share this post


Link to post
Share on other sites

Hi Sudipto:

Thanks for your reply. You asked me to send my script to your support group.

I'm sending my all my script (XML, .aspx and aspx.cs code).

 

Thanking you,

Maksuda...

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this