function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
alex_from_parisalex_from_paris 

How to add a dashboard to a visualforce page

Hello

I would like to create a visualforce page with SF dashboard

How can I do that ?

Iframe solution is not nice <iframe src='https://eu1.salesforce.com/01ZD0000000hNvH'/>

I don't want to rebuild the dashboard with google vizualisation or jquery

Thanks for your help

Regards

bob_buzzardbob_buzzard

The only other option would be to get the contents of the dashboard page in your VF page controller and parse the HTML to pull back the details that you want.  I've no idea if this would work for charting images though.

alex_from_parisalex_from_paris

Hi

Thanks for your ideaand your very quick feedback

Not a "classical" solution but It should work to get this div content.

<div class="chartDiv">

<img id="chartimage" title="" name="chartimage" alt="" src="/servlet/servlet.ChartServer?rsid=131760395262000&s=3&fs=12&tfg=18&tfs=-16777216&explode=0&c=column&cs=0&eh=no&compo=yes&fg=-16777216&bg1=-1&bg2=-1&bgdir=2&dl1=Date%2FTime+Opened&l=1&sax=yes&Yman=no&nc=0&sd=1&scv=no&sct=no&spt=no&cu=XXX&ab=X&u=0&vt=0&ab2=Y&u2=-1&vt2=0&vl0=Record+Count&spoc=no&topn=no&gm=0.0&gc0=-1&gm0=1.0&gc1=-1&gm1=2.0&gc2=-1&gm2=3.0">
</div>
Nevertheless, if somebody has a more "classical" solution, I am still interested
Regards
Alex