0

Hi i want grid behavior in vf; below is the code i am using, but strange behavior is that my tooltip is missing and also label; for that i have used outputlabel anyways. How to render tootltip? I have used panelgrid to get a grid behavior i.e two coloumns, and i will hide that second coloumn section fields based on some condition. If i use normal pageblocksection i am getting tooltip and label also, but if i hide second coloumn field in this case Desc , the other field Section2 is coming into place which i do not want. Any suggestions please, to get tooltip or any other alternative way?

        <apex:pageblockSection title="Description" columns="1">
            <apex:pageBlockSectionItem helpText="{!test.Name}">
                <apex:panelGrid columns="4" columnClasses="col1, col2, col3, col4" cellpadding="">
                    <apex:panelGroup>
                        <apex:outputLabel> Name</apex:outputLabel>
                    </apex:panelGroup>
                    <apex:panelGroup>
                        <apex:outputField value="{!test.Overall__c}" />
                    </apex:panelGroup>
                    <apex:panelGroup> 
                        <apex:outputLabel>Desc </apex:outputLabel> 
                    </apex:panelGroup>
                    <apex:panelGroup rendered="{!IF( hidingfield == true, true, false )}">
                        <apex:outputField value="{!test.Over__c}" />
                    </apex:panelGroup>
                    <apex:panelGroup> 
                        <apex:outputLabel>Section2</apex:outputLabel> 
                    </apex:panelGroup>
                    <apex:panelGroup>
                        <apex:outputField value="{!test.Ov__c}" />
                    </apex:panelGroup>
                </apex:panelGrid>
            </apex:pageBlockSectionItem>
        </apex:pageblockSection>

    </apex:pageBlock>
1

For <apex:panelGrid> you can use the "title" attribute to show the tooltip when the user's mouse pointer hovers over this component. As per what I see in the above code I think you also have to put the rendered condition on this <apex:outputLabel>Desc</apex:outputLabel> line also.

May this will help you.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.