function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
Anu-SFDCAnu-SFDC 

String to Table

Hi,

 

I have a field which is filled automatically from webservices..The values of the field is like this.. First line of the field  shows the header of the excel and next lines are the corresponding table row values.

 

I want to read the info from this field and need to display it in a table in visualforce page.. I'm new to apex...

 

Can any one help me?

 

 

 

 

"CnPAID","sfContactID","FirstName","Lastname","Email","PaymentFor","NameOnCard","CreditCardNumber","Cvv","ExpirationDate","Amount","Periodicity","Installment#","FirstpaymentDate","RoutingNumber","AccountNumber","AccountType","CheckType","CheckNumber","VaultGUID","CampaignTracker","Tracker","Result","OrderNumber"
"6943","003E0000009YNsx","radha1","testmail","radha1@testmail987.com","Payment 1","John Smith","xxx...1111","123","12/14","10.01","Momtly","10","01/01/2012",,,,,,,"campagin","Tracker","Transaction processed sucessfully","1211033521724111"
"6943",,"radha1","testmail","radha1@testmail987.com","Donation 2","Ali Mashhod","xxx...1111","654","12/14","2.14","2 weeks","14","01/06/2012",,,,,,,,,"Transaction processed sucessfully","1211033525794111"
"6943","003E0000009YNsx","radha1","testmail","radha1@testmail987.com","Payment 3","Paul Robertson",,,,"51",,,,"123456789","987654321","Saving","Personal","852741963",,,,"Transaction declined","Internal error occured - "
"6943",,"radha1","testmail","radha1@testmail987.com","Payment 4","David","xxx...1111","654","12/14","32",,,,,,,,,,,,"Transaction processed sucessfully","1211033532554111"
"6943","003E0000009YNsx","radha1","testmail","radha1@testmail987.com","Payment 5","David",,,,"32",,,,,,,,,,"Campagin","Tracker","Payment method does not specified.",""

Navatar_DbSupNavatar_DbSup

Hi,

     you can use active widget table to bind the string list on the visual force through active widget table functionality.

 

For more information you can visit at this link:

 

http://www.activewidgets.com/

    

Anu-SFDCAnu-SFDC

Hi,

 

Thanks a lot for the suggestion.. But i'm completely not aware of javascript.. I want to do this in visualforce pages and apex..

This is my page.. I want to display headers now.. but with    <apex:column value="{!far.fileheader}" >  i can able to display in a column.. I want to show it in the top row..

 

I used facet.. but no luck..:(

 

<apex:page standardController="CnPBatchUpload__c" extensions="BatchUploadController">
<apex:pageBlock >
   <apex:pageBlockTable value="{!ListValues}" var="far">
    
    <apex:facet name="header">{!fileheader}</apex:facet>
    <apex:column value="{!far.fileheader}" >
       </apex:pageBlockTable>
</apex:pageBlock>
</apex:page>

Navatar_DbSupNavatar_DbSup

Tryout the below code, it may help you.

 

<apex:page standardController="CnPBatchUpload__c" extensions="BatchUploadController">
<apex:pageBlock >
   <apex:pageBlockTable value="{!ListValues}" var="far">
   <apex:column value="{!far.fileheader}">
       <apex:facet name="header">Name</apex:facet>
    </apex:column>
   </apex:pageBlockTable>
</apex:pageBlock>
</apex:page>