• Suraj Demgunde
  • NEWBIE
  • 30 Points
  • Member since 2017

  • Chatter
    Feed
  • 0
    Best Answers
  • 0
    Likes Received
  • 0
    Likes Given
  • 32
    Questions
  • 14
    Replies
 public pagereference vendorsearch() {


  string tempInput ;
  tempInput = '%' + searchfpo + '%';
  IccMPPFpolst2 = new List < ICCWorkbench__c > ();

  // string  tempInput = '%' + searchtext + '%';
  if (loggedUser.Profile.Name == 'Customer Community Login User') {
   con = new ApexPages.StandardSetController(Database.getQueryLocator([select id, name,Organization__c,Supplier_Status__c,PO_Promised_Date__c,Ex_Factory_Date__c    from ICCWorkbench__c where Supplier_Status__c = :'Submitted To Supplier   '
    AND( Organization__r.name LIKE: tempInput OR name LIKE: tempInput) Order by PO_Promised_Date__c ASC
   ]));

  } 

  //IccMPPFpolst2=con.getRecords();

  con.setPageSize(10);
  getICCworkbench2();
  return null;


vf:
<apex:commandButton value="Search" action="{!vendorsearch}" style="float:right;width:45px;background:#cfeef8;height:25%; margin-right:0%;margin-top:5px;"/> <apex:inputText value="{!searchfpo}" style=" float:right;width:85px;margin-top:5px;"/>
like  
item no    vendor    Lead time    calcalted filed 1         
1              x              5                   avg==5
1              x              5 
trigger contupdate on Container__c (before update) {
    try{
    list<string> FPOName = new list<string>();
    String fnames='';
 
    for(Container__c currentCont : trigger.new){
  
        list<ICCWorkbench__c> getRelatedFPO = [Select Id,Name,Container_Name__r.Name,Bill_Lading__r.ZAC_PO__c  from ICCWorkbench__c where Container_Name__r.Name = : currentCont.Name];
        for(ICCWorkbench__c IccWb : getRelatedFPO){
    
            FPOName.add(IccWb.Name);
            fnames=fnames+IccWb.Name+',';
    
        }
            currentCont.ZAC_Purchase_order_Number__c =  String.join(FPOName,',');
         // currentCont.BOL_ID__r.ZAC_PO__c = currentCont.ZAC_Purchase_order_Number__c ;
 
            
            system.debug('FPOName-->'+ FPOName);
        
        Bill_Of_Lading__c bolObj=[Select Id,Name,ZAC_PO__c from Bill_Of_Lading__c where id = : currentCont.BOL_ID__c ];
        bolObj.ZAC_PO__c=fnames;
        update bolObj;
        
    }
    }
    
        catch(exception e){
            system.debug('Exception throw ->' + e.getMessage());
            
        }
  

}

test class

@isTest(SeeAlldata=true)
public class testcontainerupdate {
    testmethod static void  testfn(){
    Bill_Of_Lading__c bol = new Bill_Of_Lading__c();
   bol.CurrencyIsoCode ='EUR';
    bol.Name='kekekek';
    bol.ZAC_PO__c='testing,myfpo';
        bol.ZAC_PO__c = 'test,test2';
    insert bol;
        
        bol.Name='zaccc';
        bol.ZAC_PO__c='11111';
        update bol;
        

   
    ICCWorkbench__c wcb  = new ICCWorkbench__c();
    wcb.name ='test';
    wcb.Bill_Lading__c=bol.Id;
    wcb.CurrencyIsoCode='EUR';
   // wcb.Container_Name__c=cont.id;
    insert wcb;
        
      wcb.name='finaltest,suraj,sam';
        update wcb;

    
  
    Container__c cont  = new Container__c();
    cont.name ='bolcont2';
    
     cont.ZAC_Purchase_order_Number__c='testing,myfpo,1111';
    insert cont;
      cont.name ='bolcont3';
       cont.ZAC_Purchase_order_Number__c='testing,myfpo,11111';
       cont.Bill_Of_Lading_Number__c='fire';
    //   cont.
       
       update cont;
      
    }
}

line not cover


            FPOName.add(IccWb.Name);
            fnames=fnames+IccWb.Name+',';

and

bolObj.ZAC_PO__c=fnames;
        update bolObj;
from above class
   if(suporg.Group_Email__C!=null){
            String[] emailAddress = suporg.Group_Email__C.split(';');
         
     mail.setToAddresses(emailAddress );
      System.debug(emailAddress );
class:
global class ICC_ReminderEmails implements Database.Batchable<sObject>{
    
    
     global list<ICCWorkbench__c> start(Database.BatchableContext BC){
        return [select id,name,Organization_ID__c,Vendor_Name__r.name,Vendor_Name__r.Email__c,Vendor_Name__r.Email1__c,Vendor_Name__r.Email2__c,Vendor_Name__r.Group_Email__c,MppsubmittDate__c,CreatedDate from ICCWorkbench__c where Supplier_Status__c ='Submitted To Supplier' AND MppsubmittDate__c=Last_n_days:1];
   }

     global void execute(Database.BatchableContext BC, List<ICCWorkbench__c> scope){
        system.debug('Scope -->' + scope);
        List < Messaging.SingleEmailMessage > emails = new List < Messaging.SingleEmailMessage > ();
           
        for(ICCWorkbench__c wcb : scope){
                
                               List<String> emailAddress  = wcb.Vendor_Name__r.Group_Email__c.split(';'); 
                               System.debug(emailAddress);
                               if(wcb.Vendor_Name__r.Email__c != null)
                                emailAddress.add(wcb.Vendor_Name__r.Email__c);
                               if(wcb.Vendor_Name__r.Email1__c != null)
                                emailAddress.add(wcb.Vendor_Name__r.Email1__c);
                               if(wcb.Vendor_Name__r.Email2__c != null)
                                emailAddress.add(wcb.Vendor_Name__r.Email2__c);
                               Messaging.SingleEmailMessage email = new Messaging.SingleEmailMessage();
                               email.setToAddresses(emailAddress);
                               email.setSubject('Reminder For Pending Po Acknowledge '); 
                               email.setPlainTextBody('Dear User,' +' '+
                                                                'Your PO Number '+' '+wcb.Name +' ' + 'Pending For Acknowledge if Already Acknowledge then Ignore  this Mail otherwise Submit it immedietly.');
                                                      
                               emails.add(email);
                               system.debug('List Of Emails -->' + emails);
            
           
          }
       Messaging.sendEmail(emails);
      }
    
    global void finish(Database.BatchableContext BC){
   }
}

test class:

@isTest
Public class TestICC_ReminderEmails {  
public static testMethod void TestRemindermails(){   

//LisT<ICCWorkbench__c>  query = [select id,name,Vendor_Name__c ,Organization_ID__c,Vendor_Name__r.name,Vendor_Name__r.Email__c,Vendor_Name__r.Email1__c,Vendor_Name__r.Email2__c,Vendor_Name__r.Group_Email__c,MppsubmittDate__c,CreatedDate from ICCWorkbench__c where Supplier_Status__c ='Submitted To Supplier' AND MppsubmittDate__c=Last_n_days:1];
RecordType rtvnd = [select id,Name from RecordType where Name='Vender'];
ICCOrganization__c org = new ICCOrganization__c();
org.RecordTypeID = rtvnd.id;
org.Name ='test3';
//org.CurrencyIsoCode='';
org.Email__c = 'surajdem@gmail.com';     
org.Email1__c='surajdem@gmail.com';
org.Email2__c ='harshard.pansare@zamilindustrial.com'; 
org.Group_Email__c='surajdem@gmail.com;harshad.pansare@zamilindustrial.com';
insert org;
System.debug(org);

RecordType rtvnd1 = [select id,Name from RecordType where Name ='Manual FPO'];    
ICCWorkbench__c wcb = new ICCWorkbench__c();
wcb.RecordTypeID = rtvnd1.id;
wcb.Vendor_Name__c=org.id;
wcb.Name='hchchchchchc2';
wcb.MppsubmittDate__c= Date.newInstance(2014,1,21);
wcb.Organization_ID__c= '82';
wcb.Supplier_Status__c = 'Submitted To Supplier';
//wcb.Vendor_Name__r.Email__c  = org.Email__c;
//wcb.Vendor_Name__r.Email1__c= org.Email1__c;
//wcb.Vendor_Name__r.Email2__c = org.Email2__c;
//wcb.Vendor_Name__r.Group_Email__c=org.Group_Email__c;

//wcb.CurrencyIsoCode = 'EUR-Euro';

insert wcb;
System.debug(wcb);

test.startTest();  

//initiating an instance of the batch job   
ICC_ReminderEmails b = new ICC_ReminderEmails();
Database.executeBatch(b);

test.stopTest();  


}
}
class;

global class ICC_ReminderEmails implements Database.Batchable<sObject>{
    
    
     global list<ICCWorkbench__c> start(Database.BatchableContext BC){
        return [select id,name,Organization_ID__c,Vendor_Name__r.name,Vendor_Name__r.Email__c,Vendor_Name__r.Email1__c,Vendor_Name__r.Email2__c,Vendor_Name__r.Group_Email__c,MppsubmittDate__c,CreatedDate from ICCWorkbench__c where Supplier_Status__c ='Submitted To Supplier' AND MppsubmittDate__c=Last_n_days:1];
   }

     global void execute(Database.BatchableContext BC, List<ICCWorkbench__c> scope){
        system.debug('Scope -->' + scope);
        List < Messaging.SingleEmailMessage > emails = new List < Messaging.SingleEmailMessage > ();
           
        for(ICCWorkbench__c wcb : scope){
                
                               List<String> emailAddress  = wcb.Vendor_Name__r.Group_Email__c.split(';'); 
                               System.debug(emailAddress);
                               if(wcb.Vendor_Name__r.Email__c != null)
                                emailAddress.add(wcb.Vendor_Name__r.Email__c);
                               if(wcb.Vendor_Name__r.Email1__c != null)
                                emailAddress.add(wcb.Vendor_Name__r.Email1__c);
                               if(wcb.Vendor_Name__r.Email2__c != null)
                                emailAddress.add(wcb.Vendor_Name__r.Email2__c);
                               Messaging.SingleEmailMessage email = new Messaging.SingleEmailMessage();
                               email.setToAddresses(emailAddress);
                               email.setSubject('Reminder For Pending Po Acknowledge '); 
                               email.setPlainTextBody('Dear User,' +' '+
                                                                'Your PO Number '+' '+wcb.Name +' ' + 'Pending For Acknowledge if Already Acknowledge then Ignore  this Mail otherwise Submit it immedietly.');
                                                      
                               emails.add(email);
                               system.debug('List Of Emails -->' + emails);
            
           
          }
       Messaging.sendEmail(emails);
      }
    
    global void finish(Database.BatchableContext BC){
   }
}


test class

@isTest
Public class TestICC_ReminderEmails {  
public static testMethod void TestRemindermails(){   

LisT<ICCWorkbench__c>  query = [select id,name,Vendor_Name__c ,Organization_ID__c,Vendor_Name__r.name,Vendor_Name__r.Email__c,Vendor_Name__r.Email1__c,Vendor_Name__r.Email2__c,Vendor_Name__r.Group_Email__c,MppsubmittDate__c,CreatedDate from ICCWorkbench__c where Supplier_Status__c ='Submitted To Supplier' AND MppsubmittDate__c=Last_n_days:1];
RecordType rtvnd = [select id,Name from RecordType where Name='Vender'];
ICCOrganization__c org = new ICCOrganization__c();
org.RecordTypeID = rtvnd.id;
org.Name = 'test3';
org.Email__c = 'surajdem@gmail.com';     
org.Email1__c='surajdem@gmail.com';
org.Email2__c = 'harshard.pansare@zamilindustrial.com'; 
org.Group_Email__c='surajdem@gmail.com;harshad.pansare@zamilindustrial.com';
insert org;
System.debug(org);

RecordType rtvnd1 = [select id,Name from RecordType where Name ='Manual FPO'];    
ICCWorkbench__c wcb = new ICCWorkbench__c();
wcb.RecordTypeID = rtvnd1.id;
wcb.Vendor_Name__c=org.id;
wcb.Name='hchchchchchc2';
wcb.MppsubmittDate__c= Date.newInstance(2014,1,21);
wcb.Organization_ID__c= '82';
wcb.Supplier_Status__c = 'Submitted To Supplier';
//wcb.Vendor_Name__r.Email__c  = org.Email__c;
//wcb.Vendor_Name__r.Email1__c= org.Email1__c;
//wcb.Vendor_Name__r.Email2__c = org.Email2__c;
//wcb.Vendor_Name__r.Group_Email__c=org.Group_Email__c;

//wcb.CurrencyIsoCode = 'EUR-Euro';

insert wcb;
System.debug(wcb);

test.startTest();  

//initiating an instance of the batch job   
ICC_ReminderEmails b = new ICC_ReminderEmails();
Database.executeBatch(b);

test.stopTest();  


}
}
global class ICC_ReminderEmails implements Database.Batchable<sObject>{
    
    
     global list<ICCWorkbench__c> start(Database.BatchableContext BC){
        return [select id,name,Vendor_Name__c ,Organization_ID__c,Vendor_Name__r.name,Vendor_Name__r.Email__c,Vendor_Name__r.Email1__c,Vendor_Name__r.Email2__c,Vendor_Name__r.Group_Email__c,MppsubmittDate__c,CreatedDate,(select id,Sales_Order__c from Workbench_Sources__r) from ICCWorkbench__c where Supplier_Status__c ='Submitted To Supplier' AND MppsubmittDate__c=Last_n_days:1];
   }

     global void execute(Database.BatchableContext BC, List<ICCWorkbench__c> scope){
        system.debug('Scope -->' + scope);
        List < Messaging.SingleEmailMessage > emails = new List < Messaging.SingleEmailMessage > ();
           
        for(ICCWorkbench__c wcb : scope){
                
                               List<String> emailAddress  = wcb.Vendor_Name__r.Group_Email__c.split(';'); 
                               System.debug(emailAddress);
                               if(wcb.Vendor_Name__r.Email__c != null)
                                emailAddress.add(wcb.Vendor_Name__r.Email__c);
                               if(wcb.Vendor_Name__r.Email1__c != null)
                                emailAddress.add(wcb.Vendor_Name__r.Email1__c);
                               if(wcb.Vendor_Name__r.Email2__c != null)
                                emailAddress.add(wcb.Vendor_Name__r.Email2__c);
                               Messaging.SingleEmailMessage email = new Messaging.SingleEmailMessage();
                               email.setToAddresses(emailAddress);
                               email.setSubject('Reminder For Pending Po Acknowledge '); 
                               email.setPlainTextBody('Dear User,' +' '+
                                                                'Your PO Number '+' '+wcb.Name +' ' + 'Pending For Acknowledge if Already Acknowledge then Ignore  this Mail otherwise Submit it immedietly.');
                                                      
                               emails.add(email);
                               system.debug('List Of Emails -->' + emails);
            
           
          }
       Messaging.sendEmail(emails);
      }
    
    global void finish(Database.BatchableContext BC){
   }
}

if(suporg.Email3__c!=null){
      
       ccAddresses.add(suporg.Email3__c);
      
      mail.setccAddresses(ccAddresses);
     }
User-added image
<apex:page standardController="User" >
<apex:form >

 <div align="center">
<apex:image url="https://c.ap4.visual.force.com/resource/1548067870000/LoginImage" styleClass="imageStyle" height="100" width="100"/>
</div>

<apex:pageBlock title="User Information"> 

<apex:pageBlockSection columns="3">

<div align="left" draggable="false" >
      
       

<apex:inputField value="{!User.Username}" />
<apex:inputField value="{!User.Password__c}" required="true"/>
</div>
</apex:pageBlockSection>
<div align="right:top" columns="2" >
<apex:commandButton value="Login" action="{!save}"/>
</div>

</apex:pageBlock>

</apex:form>
  
</apex:page>
<apex:page controller="ICCinvoicePdf" renderAs="pdf" applyBodyTag="false" applyHtmlTag="false" showHeader="false">
<head>
<style type="text/css" >

@page{
@bottom-right {
  font-family:sans-serif;
  font-size:90%;
  content:  "Copyright © 2015 Zamil Industrial, All Rights Reserved   Page" counter(page)  " of " counter(pages);
 }
 @bottom-left{
  font-family:sans-serif;
  font-size:90%;
  content:"- Generated by ICC" ;
 }
  
  }




 

div.header{

padding: 10px;
text-align: center;
position: running(header);
}



div.footer {
display: block;             
padding: 5px;               
position:running(footer);
;
}  
.pagenumber:before {
content: counter(page);
}
.pagecount:before {
content: counter(pages);
}

.quoteTable{
     border-width: 1px;
    border-spacing: 0px;
    border-style: solid;
    border-color: black;
    border-collapse: collapse;
    background-color: white;  
 
    -fs-table-paginate: paginate; 
    <!--font-family:"Times New Roman", Times, serif;-->
    font-family:sans-serif;
    font-size:65%;    
}

   





</style>

  
</head>

<apex:pageBlock >
<div >
<table width="100%" cellpadding="2" style="border-collapse:collapse;"  border="1">
<tr>
             <td align="center" valign="" width="100%"><h3>INVOICE:{!invoicenum}</h3>
              <div >
                <table width="100%"  cellpadding="2" style="border-collapse:collapse;"  border="1"   >
              <tr>
            <td centre="left" width="100%">
              Number of Pages: <span class="pagecount"/> <br></br>
              </td>
               <td align="left" width="100%">
            Date:
            <apex:outputText value="{0,date,MMMM dd, yyyy}">
                <apex:param value="{!TODAY()}" />
             </apex:outputText><br></br>
              </td>
          </tr>
          </table>
          <div style="color:#0000;border-bottom:none;">
          <table width="100%"  cellpadding="1" style="border-collapse:collapse;"  border="1"  >
          <tr>
          <td>
          CONSOLIDATION<br></br>
            </td>
            </tr>
            </table>
            </div>
            <div style="color:#0000;border-bottom:none;" >
             <table width="100%" cellpadding="1" style="border-collapse:collapse;"  border="1"  >
          <tr>
          <td align="left">
        SHIPMENT<br></br>
            BOL #:{!cname}<br></br>
            </td>
            </tr>
            </table>
            </div>
            <div style="color:#0000;border:none" >
            
             <table width="100%" cellpadding="1" style="border-collapse:collapse;"  border="1"  >
             <tr>
             <td align="left">
             <apex:outputPanel rendered="{!recordtypename=='SeaFreight'}">
             
             Vessel Name:&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;{!vesselname}<br></br>
            </apex:outputPanel>
            
            <apex:outputPanel rendered="{!recordtypename=='Broker'}">
            Vessel Name:&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;{!vesselname}<br></br>
              </apex:outputPanel>
            
           <apex:outputPanel rendered="{!recordtypename=='Planner'}">
           Vessel Name:&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;{!vesselname}<br></br>
            </apex:outputPanel>
           
            <apex:outputPanel rendered="{!recordtypename=='Coordinator'}">
           Vessel Name:&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;{!vesselname}<br></br>
            </apex:outputPanel>
             <apex:outputPanel rendered="{!recordtypename=='AirFreight'}">
                AirLine Name:&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;{!airlinename}<br></br>
            </apex:outputPanel>
          <apex:outputPanel rendered="{!recordtypename=='AirFreight Coordinator'}">
         <!--  <apex:outputPanel rendered="{!recordtypename=='AirFreight'  || recordtypename=='AirFreight Broker'}">-->
            <!-- AirLine Name:ETIHAD CARGO {!airlinename}<br></br> -->
              AirLine Name:{!airlinename}<br></br>
            </apex:outputPanel>
          <apex:outputPanel rendered="{!recordtypename=='AirFreight Broker'}">
             AirLine Name:&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;{!airlinename}<br></br>
            </apex:outputPanel>
            </td>
            </tr>
            </table>
            </div>
            <div style="border:0" >
             <table width="100%" cellpadding="1" style="border-collapse:collapse;"  border="0"  >
            </table>
            </div>
          </div>
          </td>
     </tr>
     <tr>
      <td align="left" width="50%">
       <apex:outputpanel rendered="{!s2.size==0}">
         <h3>METRO FREIGHT SERVICES INC</h3> 
        2365 E,Linden Ave. Linden,<br>
            New Jersey 07036</br><br></br>
            Telephone:001 908 925 8400 <br></br>
             FAX:001 908 925 8444 
             </apex:outputpanel>
               <apex:outputpanel rendered="{!s2!=null}"> 
         <apex:repeat value="{!s2}" var="s" >
            {!s} <br/> 
            </apex:repeat>
         </apex:outputpanel>  
      </td> 
            
         
         <td align="right" width="50%">
           <apex:outputpanel rendered="{!s2.size==0}">
         <h3>METRO FREIGHT SERVICES INC</h3> 
        2365 E,Linden Ave. Linden,<br>
            New Jersey 07036</br><br></br>
            Telephone:001 908 925 8400 <br></br>
             FAX:001 908 925 8444 
             </apex:outputpanel>
               <apex:outputpanel rendered="{!s2!=null}"> 
         <apex:repeat value="{!s2}" var="s" >
            {!s} <br/> 
            </apex:repeat>
         </apex:outputpanel> 
         </td>   
      </tr>
</table>
</div>
</apex:pageblock>
 <br/><br/> User-added image
trigger SVMXUPG_convertNumberToWord on SVMXC__Quote__c (before insert, before update) {
    EnglishNumberToWords enw = new EnglishNumberToWords();
    for(SVMXC__Quote__c Quote: Trigger.new){
        Quote.Net_Amount_in_Text__c = enw.convert(Quote.Total_After_VAT__c);
    }
}
 
Public Class AccountSelected {
 
    Public List<AccWrap>AccList {get;set;}
   
    Public AccountSelected (){
        List<Account> AccRecords=[Select ID, Name From Account];
         for(Account c:AccRecords){
                 AccList.add(new AccWrap(c));
            }
    }
 
 
    public class AccWrap{
        Public Account Acc;
        Public Boolean CheckBoolean;
       
            Public AccWrap(Account a){
                Acc=a;
                CheckBoolean=false;
            }
    }
}

//////////////////////////

<apex:page controller="AccountSelected ">
 <apex:form>
 <apex:pageBlock>
 
     <apex:pageBlockSection >
         <apex:pageBlockTable value="{!AccList}" var="d">
             <apex:column value="{!d.Acc.name}" />
         </apex:pageBlockTable>
     </apex:pageBlockSection>
 
 </apex:pageBlock>
 
 
 </apex:form>
</apex:page>     
trigger Lead_Update on Lead (before insert,before update) {
    String dam ='';
    String jub='';
    String west1 ='';
    String west2 = '';
    String central = '';
    String Gcc = '';
    
     String uid=UserInfo.getUserId(); 
      User UserDetails =   [select  User.Lead_Region__c, User.Location__c from User Where User.Id =:uid limit 1]; 
       string UserLoc = UserDetails.Location__c;
       string LeadRegion = UserDetails.Lead_Region__c; 
        
    
    for(Lead lt : trigger.new){
        
       lt.Lead_City__c = UserLoc;
       lt.Region__c = LeadRegion;
    
        
    }

}
trigger SVMXUPG_convertNumberToWord on SVMXC__Quote__c (before insert, before update) {
    EnglishNumberToWords enw = new EnglishNumberToWords();
    for(SVMXC__Quote__c Quote: Trigger.new){
        Quote.Net_Amount_in_Text__c = enw.convert(Quote.Total_After_VAT__c);
    }
}
 
trigger Lead_Update on Lead (before insert,before update) {
    String dam ='';
    String jub='';
    String west1 ='';
    String west2 = '';
    String central = '';
    String Gcc = '';
    /*Public String uid=UserInfo.getUserId(); 
  public user UserDetails =   [select  User.Location__c from User Where User.Id =:uid limit 1]; 
  public string UserLoc= UserDetails.Location__c;
   // System.debug(UserLoc);*/
    
    for(Lead lt : trigger.new){
        
    String uid=UserInfo.getUserId(); 
   user UserDetails =   [select  User.Location__c from User Where User.Id =:uid limit 1]; 
   string UserLoc= UserDetails.Location__c;
        
      //  system.debug('---------------------Location------------------'+location);
        
        
        
       lt.Region__c = UserLoc;
        
    }

}
 
trigger Lead_Update on Lead (before insert,before update) {
    String dam ='';
    String jub='';
    String west1 ='';
    String west2 = '';
    String central = '';
    String Gcc = '';
    for(Lead lt : trigger.new){
        if(String.isNotBlank(lt.Dammam__c)){
           
            dam = 'Dammam\n';
           
        }  
        
        if(String.isNotBlank(lt.Jubail__c)){
          
            jub = 'Jubail\n';
           
        }
       
        if(String.isNotBlank(lt.West_North__c)){
            
            west1 = 'West North\n';
 
        }
       
        if(String.isNotBlank(lt.West_South__c)){
           
            west2 = 'West South\n';
           
        }
      
        if(String.isNotBlank(lt.Central_Region__c)){
           
            central = 'Central\n';
        }
       
        If(String.isNotBlank(lt.GCC__c)){
           
            Gcc = 'GCC';
        }
       
       lt.Region__c = dam+ jub+ west1+west2 +central +Gcc;
       
    }
 
}
 
I have a custom object. And I have a field Name and ID.. How can I display these fileds in Visual Force page, using custom controller.
Thank you in advance.
  • March 04, 2014
  • Like
  • 0