You need to sign in to do that
Don't have an account?
Steve Chadbourn
Summer 08 Ate My Hamster
Not my hamster actually but my formula fields.
Our dev sandbox has just had some sort of Summer 08 upgrade. I'm guessing this as all my pages now declare themselves to be API 13.0. I had to open and save all my VF pages before Eclipse could see them.
I tried to run my first page and got the error: "An internal server error has occurred". By a process of removing and adding components I narrowed it down to 3 formula fields. 2 no longer display anything. The third causes the internal server error. What heinous act does the formula field try and do I hear you ask? it has one line of code:
NOW()
The page uses an outputField to display the formula field.
Is anyone else having the same problem?
Not sure about the issue with Eclipse - the force.com ide plugin is not owned or developed by the visualforce team.
Message Edited by dchasman on 05-21-2008 06:46 PM
Does your formula field $User.FirstName & ' ' & $User.LastName display correctly when used in a page layout?
I don't have an easy way of testing that. The field is against an object that is only ever temporary - it provides databinding for a wizard.
This works:
<apex:outputText value="{!$User.FirstName}"/>
<fx: Slaps head>
Of course its this:
<apex:outputText value="{!$User.FirstName} {!$User.LastName}"/>
<apex:outputText value="{!Username}"/>
// controller
public string getUsername()
{
return UserInfo.getName();
}
I can report that formula fields do work on page layouts, just not on VF pages.
I have a formula field Contact.FullAddress__c which contains:
MailingStreet
& IF( MailingCity = "", "", ", " & MailingCity )
& IF( MailingPostalCode = "", "", ", " & MailingPostalCode )
This appears fine if I put it on the Contact layout but returns nothing if I put it on a VF page.
Has this been identified as a bug?
If it is a custom controller are you pulling all the contact fields that are used in this formula field for the contact object.
I don't know if this would make a difference but I'm just bouncing ideas around.
Thanks for the ideas.
I'm using a custom controller. I'm filling an array with contact objects I create then displaying it in a pageblocktable.
I have 2 sandboxes - one on Spring 08 and one on Summer 08. It works fine on Spring but is blank in Summer.