• SFTechy
  • NEWBIE
  • 0 Points
  • Member since 2015

  • Chatter
    Feed
  • 0
    Best Answers
  • 0
    Likes Received
  • 0
    Likes Given
  • 1
    Questions
  • 2
    Replies
Hi, I'm fairly new to APEX.  I wrote a class which needs to get the Salesforce base URL of my org instance, so I can append it with a record id. I keep getting the following error message when I execute an anonymous block.  

Compile error at line 1 column 1
Method does not exist or incorrect signature: SalesforceBaseURL.GetSFBaseURL()

I'm running this in my sandbox.  Whether it be Eclipse or the Developer Console, I get the same error message.  Can someone please help?  What am I doing wrong?  Thank you so much!

Anonymous block syntax:
SalesforceBaseURL.GetSFBaseURL();

public class SalesforceBaseURL {   
    //public String SFBaseURL;    
    
    public static String GetSFBaseURL(){
        // Get the dynamic Salesforce base URL
        //SFBaseURL = Url.getSalesforceBaseUrl().toExternalForm();
        //SFBaseURL = "TESTING";
        return 'TESTING';
    }
}
Hi, I'm fairly new to APEX.  I wrote a class which needs to get the Salesforce base URL of my org instance, so I can append it with a record id. I keep getting the following error message when I execute an anonymous block.  

Compile error at line 1 column 1
Method does not exist or incorrect signature: SalesforceBaseURL.GetSFBaseURL()

I'm running this in my sandbox.  Whether it be Eclipse or the Developer Console, I get the same error message.  Can someone please help?  What am I doing wrong?  Thank you so much!

Anonymous block syntax:
SalesforceBaseURL.GetSFBaseURL();

public class SalesforceBaseURL {   
    //public String SFBaseURL;    
    
    public static String GetSFBaseURL(){
        // Get the dynamic Salesforce base URL
        //SFBaseURL = Url.getSalesforceBaseUrl().toExternalForm();
        //SFBaseURL = "TESTING";
        return 'TESTING';
    }
}

Looking to see if anyone has information on what the related list name is for Campaign Influence on Opportunities. Working on a tabbed Opportunities page and its the only list where I cannot find the API name. I have tried APEX Explorere and searching the boards but no luck yet. The best info i have come across so far were some older posts indicating that this list is not exposed to the API but was on the roadmap.

 

Anyone have more up-to-date information on this?

 

Just so we are 100% clear on what I am looking to do, here is a code snippet from my VF page:

<apex:tab label="Campaign" name="Campaign" id="tabCamp">
         <apex:relatedList subject="{!Opportunity}" list="CampaignInfluence" />
      </apex:tab>

 Thx!