• revanth admin
  • NEWBIE
  • 10 Points
  • Member since 2014

  • Chatter
    Feed
  • 0
    Best Answers
  • 0
    Likes Received
  • 0
    Likes Given
  • 3
    Questions
  • 3
    Replies
Hi..
  Please Explain About Set And get Methods IN simple way..
   "Get" and "Set" Methods How thes work  ::
        1- Visual Force -To- Class(console).
        2-Console(Class) -To- VisualForce
Hi
  I  have written visual force page using' customController' to display the contact details when checked using wrapper class
now the o/p (i.e, the checked contacts have to insert in my accounts as a records )

Note: the account vf page is custom page and at ( "add members"-page block section) those selected contacts must be displayed.
and 
at ( "add members"-page block section) there will be a 'add button ' by clicking the add buttion we have to go to 

contacts list which i have desigend and when i checked the contacts and when i pressed the "addcontacts button"

the checked contacts have to display in my accounts ..


--------------I have attache a sample image for better understanding of my requirement --------
User-added image

(MY trigger Has to UpDate the RecoredField - Batch_Email__C  ''Data Type is--Email For this Field''}   the update date must come from the Batch Record .

Note;   ((Hear ==="Student =parenet" and "Payment=child" and Batch is 'Parent' to Child="Student")) .

now the Batch_Email__c Field on paymetn Has to Update With the Email in The Batch Record...?


trigger PaymentToBatch on Payment__c (after update)
{
Payment__c paynew=trigger.new[0];

payment__c pay=[select id,Batch_Email__c,student__r.Batch__r.Group_Mail_ID__c From Payment__c
                                             where id=:paynew.id];

              system.debug('---pay----'+pay);
            system.debug('---payToBatch----'+pay.student__r.Batch__r.Group_Mail_ID__c);
            system.debug('---pay.Batch Name----'+pay.Batch_Email__c);

                                                   
      pay.Batch_Email__c=pay.student__r.Batch__r.Group_Mail_ID__c;
   
      system.debug('---payTOBatch.After----'+pay.Batch_Email__c);             

}

Result:

In My Developer Console the out put  is Shown But my ''Batch_Email__c' 'Field on Payment Is Not Showing the OutPut value.

Hi
  I  have written visual force page using' customController' to display the contact details when checked using wrapper class
now the o/p (i.e, the checked contacts have to insert in my accounts as a records )

Note: the account vf page is custom page and at ( "add members"-page block section) those selected contacts must be displayed.
and 
at ( "add members"-page block section) there will be a 'add button ' by clicking the add buttion we have to go to 

contacts list which i have desigend and when i checked the contacts and when i pressed the "addcontacts button"

the checked contacts have to display in my accounts ..


--------------I have attache a sample image for better understanding of my requirement --------
User-added image

(MY trigger Has to UpDate the RecoredField - Batch_Email__C  ''Data Type is--Email For this Field''}   the update date must come from the Batch Record .

Note;   ((Hear ==="Student =parenet" and "Payment=child" and Batch is 'Parent' to Child="Student")) .

now the Batch_Email__c Field on paymetn Has to Update With the Email in The Batch Record...?


trigger PaymentToBatch on Payment__c (after update)
{
Payment__c paynew=trigger.new[0];

payment__c pay=[select id,Batch_Email__c,student__r.Batch__r.Group_Mail_ID__c From Payment__c
                                             where id=:paynew.id];

              system.debug('---pay----'+pay);
            system.debug('---payToBatch----'+pay.student__r.Batch__r.Group_Mail_ID__c);
            system.debug('---pay.Batch Name----'+pay.Batch_Email__c);

                                                   
      pay.Batch_Email__c=pay.student__r.Batch__r.Group_Mail_ID__c;
   
      system.debug('---payTOBatch.After----'+pay.Batch_Email__c);             

}

Result:

In My Developer Console the out put  is Shown But my ''Batch_Email__c' 'Field on Payment Is Not Showing the OutPut value.

hi there,

 

I have a simple question.  I know how to throw errors from apex triggers by using the sObject.addErrors method.  This gets displayed on the UI as a red error message.   Is there a way to throw info level messages that show up as a non-critical message?  Or will I have to write something custom like set the info messages in a field from the trigger and display that field in a info message section on the UI?

 

thx,

Pi