• jtwoods4
  • NEWBIE
  • 0 Points
  • Member since 2012

  • Chatter
    Feed
  • 0
    Best Answers
  • 0
    Likes Received
  • 0
    Likes Given
  • 3
    Questions
  • 5
    Replies

My controller class is returning an array of string to my apex page. How do I loop over the array items and display them?

 

In the code below I am just trying to access the first index in the array and display the value. But this does not work.

 

<apex:page standardController="Account" extensions="RECALLFDMServiceController">

<h1>TTM Revenues</h1>
    <apex:pageBlock >
        <apex:pageblocktable value="{!TTMByListBillingID}" var="TTMResponse">            


          <apex:column >
                {!TTMResponse['0'].TTM}
            </apex:column>

 

        </apex:pageblocktable>
    </apex:pageBlock>
    
</apex:page>

 

I am trying to configure the OpenAccess ODBC driver to connect to my saleforce account.  

I am not sure what to enter in the ODBC configuration screen (see below General and Security tabs)

 

We log in to our salesforce sandbox by going to test.salesforce.com. I then enter my username: jtwoods4@recall.com.alpha and password: ##########

 



 

                       

 

I am a .NET Developer and this is my first week developing salesforce applications. I was asked to make a custom salesforce APEX page that performs a "callout" to an external webservice. I was able to do this. However, I am not able to pass in the Account ID from the account page to the new APEX page.

 

I modiied the account view page to include a command button that redirects to my new APEX page. See code here

 

<apex:page standardController="Account" tabStyle="Account">
     <apex:pageBlock >
            <apex:form >             
                 <apex:commandButton action="{!URLFOR("/apex/RECALLDEV2",Account.id)}" value="TTM Revenue" /> 
            </apex:form>        
     </apex:pageBlock>
     <apex:detail subject="{!Account.Id}"/>              
</apex:page>

 

And here is my custom APEX page and Controller that handles the URLFOR redirect

 

 

public with sharing class RECALLDEV2Manager 
{
   
    private final List<Account> account;

    public RECALLDEV2Manager (ApexPages.StandardController controller) 
    {
        account = [SELECT Name FROM Account WHERE Id = :ApexPages.currentPage().getParameters().get('id')];
    }

    public string getHelloWorld() 
    {
        RECALLDEV2.WebService2Soap service = new RECALLDEV2.WebService2Soap();
        string responseFromService = service.HelloWorld();
        
        return responseFromService;
    }

}

 

Here is the Page, I am simply trying to access the account object I populated in the controller and write the company name to the page but it does not appear

 

<apex:page standardController="Account" extensions="RECALLDEV2Manager">
    <h1>Test Page</h1>
    <apex:pageBlock >

        <apex:form >
            <apex:outputLabel value="{!HelloWorld}" />
            <p>You are viewing the {!account.name} account.</p>

        </apex:form>

    </apex:pageBlock>
</apex:page>

 

My controller class is returning an array of string to my apex page. How do I loop over the array items and display them?

 

In the code below I am just trying to access the first index in the array and display the value. But this does not work.

 

<apex:page standardController="Account" extensions="RECALLFDMServiceController">

<h1>TTM Revenues</h1>
    <apex:pageBlock >
        <apex:pageblocktable value="{!TTMByListBillingID}" var="TTMResponse">            


          <apex:column >
                {!TTMResponse['0'].TTM}
            </apex:column>

 

        </apex:pageblocktable>
    </apex:pageBlock>
    
</apex:page>

 

I am a .NET Developer and this is my first week developing salesforce applications. I was asked to make a custom salesforce APEX page that performs a "callout" to an external webservice. I was able to do this. However, I am not able to pass in the Account ID from the account page to the new APEX page.

 

I modiied the account view page to include a command button that redirects to my new APEX page. See code here

 

<apex:page standardController="Account" tabStyle="Account">
     <apex:pageBlock >
            <apex:form >             
                 <apex:commandButton action="{!URLFOR("/apex/RECALLDEV2",Account.id)}" value="TTM Revenue" /> 
            </apex:form>        
     </apex:pageBlock>
     <apex:detail subject="{!Account.Id}"/>              
</apex:page>

 

And here is my custom APEX page and Controller that handles the URLFOR redirect

 

 

public with sharing class RECALLDEV2Manager 
{
   
    private final List<Account> account;

    public RECALLDEV2Manager (ApexPages.StandardController controller) 
    {
        account = [SELECT Name FROM Account WHERE Id = :ApexPages.currentPage().getParameters().get('id')];
    }

    public string getHelloWorld() 
    {
        RECALLDEV2.WebService2Soap service = new RECALLDEV2.WebService2Soap();
        string responseFromService = service.HelloWorld();
        
        return responseFromService;
    }

}

 

Here is the Page, I am simply trying to access the account object I populated in the controller and write the company name to the page but it does not appear

 

<apex:page standardController="Account" extensions="RECALLDEV2Manager">
    <h1>Test Page</h1>
    <apex:pageBlock >

        <apex:form >
            <apex:outputLabel value="{!HelloWorld}" />
            <p>You are viewing the {!account.name} account.</p>

        </apex:form>

    </apex:pageBlock>
</apex:page>

 

I'm new to Salesforce API, I'm trying to update salesforce case record comments from my applications, when I went through the samples, I see that in few samples, Url property of the SforceService is being set before SforceService.login() is called, this property is later overridden by the value returned by LoginResult.ServerUrl. I'm just wondering the importance of doing so... is it good practice to set Url property before calling login method? if yes, where do I get this Url? should I grab from WSDL? what if this changes later? -Santhosh