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
NJ_Devils_FanNJ_Devils_Fan 

Dynamic Height for VF Homepage Component

I want to display a visual force page on my salesforce homepage. However, I can't do that because the height of the page is dynamic, and no matter what I try the homepage components always end up being static. 
 
 My homepage component is this:
<IFRAME id=itarget src="/apex/OSShomepage" frameBorder=0 width="100%" height=400></IFRAME> 
 
Is there something i'm not doing here that would make it dynamic??
 
 
Also, I tried going in a different direction and made a custom home tab that displayed the visual force page. I thought that this would solve the problem because the page itself has no problems. However, when I went to remove the standard home page from the custom app, it said you're not allowed to do this. Then when I went to hide the home tab from peoples profiles, it didn't let me. Is there another way i don't know about?
 
There must be a way to accomplish at least one of these things. Thanks in advance for your help.
 
 
NonickNonick
I'm an absolute idiot when it comes to salesforce but I remember someone mentioning you can write an scontrol and imbed it in home page forwards to different page. Don't think it hid the home tab though.
mtbclimbermtbclimber
You can't remove the home tab but you can make your Visualforce page based custom tab the "default" for the given tabset (aka App) . Go to your "App" definition in setup to see this option. This was released in Summer '08 and removes the need to embed an scontrol that redirects.

As for iframes, they do not provide a "dynamic height" capability natively. If the domain of the page that served the iframe is the same as that of the page that is embedded in the iframe then you can write script that resizes the frame to fit the contents but this is something that is not possible for Visualforce pages since they are now served from force.com.
NJ_Devils_FanNJ_Devils_Fan

Thanks for responding Andrew. Though now it seems that there really is no way to get what i'm looking for, because even with the new feature where you can set a default tab, you cannot get rid of the other homepage tab.

Is there any thought around solving this problem in the future? Adding visualforce homepage components that have dynamic heights? Or overriding the home tab?

TehNrdTehNrd

mtbclimber wrote:
As for iframes, they do not provide a "dynamic height" capability natively. If the domain of the page that served the iframe is the same as that of the page that is embedded in the iframe then you can write script that resizes the frame to fit the contents but this is something that is not possible for Visualforce pages since they are now served from force.com.

Is this still the case? I have tried the script approach and it appears to work:

http://community.salesforce.com/sforce/board/message?board.id=Visualforce&thread.id=10573