• Nirmal Garg 20
  • NEWBIE
  • 5 Points
  • Member since 2017

  • Chatter
    Feed
  • 0
    Best Answers
  • 0
    Likes Received
  • 0
    Likes Given
  • 0
    Questions
  • 1
    Replies

Hi all,

 

I am trying to use the styleClass attribute to apply a specific style to a button but it doesn't work.

When I apply the same style inline in the tag it works.

 

The tag is <apex:commandButton>, any hint?

 

(I only managed so far  to modify the background colour of the button inline)

Thanks for explaining me what can be wrong in my code:

 

<apex:page >

    <style type="text/css"> 
      .myClass {
          color:white;
          background-color:#00CC00;
       }
    </style>
    

<apex:commandButton styleClass="myClass" action="{!someAction}">  
</apex:outputText>

</apex:page>
  • November 18, 2013
  • Like
  • 0