• Luiz Prandini
  • NEWBIE
  • 25 Points
  • Member since 2015

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

I need to create a new button on Opportunity product related list. I created the button. I want when I clickon this new button it takes me to Add Product page.
How can I do this? Does soemone has URL parameters for Add product?

Thanks,
 
I am trying to create a visualforce matrix chart that looks some thing like this..

User-added image

I would like to have it set that the columns and row headers are set, but want to have the other field editable. I will then create reports that look like this as well. Where is says PSI maybe have that editable as well. Do you have any suggestions on how to build this? 
Hi,

I need to create a new button on Opportunity product related list. I created the button. I want when I clickon this new button it takes me to Add Product page.
How can I do this? Does soemone has URL parameters for Add product?

Thanks,
 
User-added image
How do I add Page# of Total Page# in VF custom page? I only able to get Page#, I could not get the other part ( Of Total Page). Any Idea. Thanks 
 
<apex:panelGrid columns="9">
                <div id="panel">
                    <apex:commandLink action="{!first}">First</apex:commandlink>
                    <apex:commandLink action="{!previous}" rendered="{!hasPrevious}">Previous</apex:commandlink>
                    <apex:commandLink action="{!next}" rendered="{!hasNext}">Next</apex:commandlink>
                    <apex:commandLink action="{!last}">Last</apex:commandlink> 
                    <apex:outputText value="Page #{!pageNumber}"/>
                    <b>Record :</b>
                    <apex:outputText rendered="{!(setpb.pageNumber * setpb.pageSize) < setpb.ResultSize}" value="{!setpb.pageNumber * setpb.pageSize} OF {!setpb.ResultSize}"></apex:outputText>
                    <apex:outputText rendered="{!(setpb.pageNumber * setpb.pageSize) >= setpb.ResultSize}" value="{!setpb.ResultSize} OF {!setpb.ResultSize}"></apex:outputText>
                  
                </div>
            </apex:panelGrid>
Extension 
 
public class DispatcherContactNewController {

    public DispatcherContactNewController(ApexPages.StandardController controller) {
        this.controller = controller;
    }

    private integer offset; // Keeps track of the offset     
    private integer pageSize;   // Page size or number of rows           
    public integer totalRecords;  // Total number of records  
    
    public ApexPages.StandardSetController setpb{
        get{
            if(setpb == null){
                setpb = new ApexPages.StandardSetController(Database.getQueryLocator(
                    [SELECT Id, Name, RecordTypeId, Createddate FROM Product_Brief__c ORDER BY Createddate DESC ]));
                         setpb.setPageSize(10);
                         }
                         return setpb;
           } 
        set;
        
    }
    
    public List<Product_Brief__c>getpbs(){
        return (List<Product_Brief__c>)setpb.getrecords();
    }
    
    public Boolean hasNext {
        get {
            return setpb.getHasNext();
            }
        set;
    }
    
    public Boolean hasPrevious {
        get {
            return setpb.getHasPrevious();
            }
        set;
    }
    
    public Integer pageNumber {
        get {
            return setpb.getPageNumber();
            }
        set;
    }
    
    public void first() {
         setpb.first();
    }
     
    public void last() {
         setpb.last();
    }

    // returns the previous page of records
    public void previous() {
        setpb.previous();
    }

    // returns the next page of records
    public void next() {
        setpb.next();
    }
}