• Arnold Brown
  • NEWBIE
  • 20 Points
  • Member since 2014

  • Chatter
    Feed
  • 0
    Best Answers
  • 0
    Likes Received
  • 0
    Likes Given
  • 3
    Questions
  • 2
    Replies
I'm just trying to write a simple if statement to check the piclist value for TeammemberRole on Account Team object. I've tried it with double equalls signs "==" and using string method .equals().  No matter what I try I continue to get the error. "Condition expression must be of type boolean.  It should be a simple thing but it's stopping me cold. 
Here's how it looks currently:
 
for(AccountTeamMember member:  ATM ){
            if (member.TeamMemberRole == 'CRD - Back-up' ){
               BackupCRDMap.put(member.Account.id, member.user.name);
               }

 



 
Our Account Page layout is getting out of hand.  Too many sections.  We've implemented a Child object containing 75 fields, but the all the object's data has a 1:1 relationship to account.  The child exists solely to put the fields on another layout.  It's causing a lot of work as we want the data to flow to contacts.  Rather than write Triggers & Process Builders to push the data around, I'd like to move all the fields up to the Account object and create a tabbed view of Accounts via Visualforce.  The problem is all examples I'm finding use a seperate tab for the related lists.   In addition to doing that, I want to add a tab "Client Account Detail" and put the 75 pertinent fields only on that VF tab and not show them on the Master Account Layout.  

Soooo.....possibile?  I've not seen an example of this in practice and I've been digging a bit.  I'm new to VF development. Any examples you could point to would be most helpful. 

Thanks!!

Arnold

 

I just want to iterate through the list I create and set a field stating whether there are attachments on the object to no  when conditions are met via a before delete trigger.  I'm getitng variable does not exist


if(parentObjId.startsWith('a0x')&& Trigger.isdelete)
             List<CRM_Outreach__c> CRMNoList = [select id, Attachment_Added__c from CRM_Outreach__c where id =: Trigger.New[0].ParentId];  
             // query to see if there are still attachments under the object
             // If there were less than two, i.e. 1 attachment, then there will be zero after the after delete trigger.
           if(CRMNolist.size()<2){
               for (CRM_Outreach__c CRM : CRMNoList)
             {
                   CRM.Attachment_Added__c = 'No';

I'm just trying to write a simple if statement to check the piclist value for TeammemberRole on Account Team object. I've tried it with double equalls signs "==" and using string method .equals().  No matter what I try I continue to get the error. "Condition expression must be of type boolean.  It should be a simple thing but it's stopping me cold. 
Here's how it looks currently:
 
for(AccountTeamMember member:  ATM ){
            if (member.TeamMemberRole == 'CRD - Back-up' ){
               BackupCRDMap.put(member.Account.id, member.user.name);
               }