• RichardR1
  • NEWBIE
  • 60 Points
  • Member since 2019
  • Salesforce Admin trying to learn to code

  • Chatter
    Feed
  • 0
    Best Answers
  • 0
    Likes Received
  • 0
    Likes Given
  • 15
    Questions
  • 10
    Replies
I made a tab for my visualforce page just so I can get it's URL and reference it in a hyperlink in a formula field. Unfortunately since it is a tab, the page moves away from the originating page to the VF tab. How can I reference only the VF page instead of the tab?
Hi all, I'm trying to learn Apex. I need to update some triggers but our org code coverage is below the requirement. I think it's because of some Apex classes and I'm not sure if I can delete/ deactivate them. How do I check that?

I'm very new to development. We have a trigger that I think is bulkified but still I am getting errors whenever I mass update more than 200 contacts using Data Import Wizard.

What I don't understand is why only the first 200 contacts fail and then all other contacts in excess are updated successfully, even though they are on the same CSV upload. Does anyone know why this is the case?

Without using Einstein Analytics, what would it take to be able to link a dashboard which automatically selects a filter based on the link that I sent the user, so the user won't have to select the filters? This would be useful in our case where a dashboard have as many as 50 filters at a time.
Hope you're all in good health. Can anyone help how to reduce the width of the first column in my pageBlockSection VF page? There's just too much space for checkbox fields.
<apex:page standardController="Contact" sidebar="false" >
   <apex:form >
   <apex:inlineEditSupport />
   <apex:pageBlock mode="maindetail" >
   <apex:pageBlockSection columns="4" >

         <apex:pageBlockSectionItem > <apex:outputText > <b> Hard Pref </b> </apex:outputText> </apex:pageBlockSectionItem>
         <apex:pageBlockSectionItem > <apex:outputText > <b>Category</b> </apex:outputText> </apex:pageBlockSectionItem>
         <apex:pageBlockSectionItem > <apex:outputText > <b>Preferences</b> </apex:outputText> </apex:pageBlockSectionItem>
         <apex:pageBlockSectionItem >  <apex:outputText > <b>Notes</b> &nbsp; &nbsp;&nbsp;</apex:outputText> </apex:pageBlockSectionItem>
           
        
         <apex:pageBlockSectionItem > <apex:outputField value="{!Contact.Handle_with_care__c}" /> </apex:pageBlockSectionItem>
         <apex:pageBlockSectionItem > <apex:outputText > Geography </apex:outputText> </apex:pageBlockSectionItem>
         <apex:pageBlockSectionItem > <apex:outputField value="{!Contact.Geographic_HWC__c}" /> </apex:pageBlockSectionItem>
         <apex:pageBlockSectionItem > <apex:outputField value="{!Contact.Geographic_Preferences_Notes__c}" /> </apex:pageBlockSectionItem>
         
      
         <apex:pageBlockSectionItem > <apex:outputField value="{!Contact.Handle_with_care__c}" /> </apex:pageBlockSectionItem>
         <apex:pageBlockSectionItem > <apex:outputText > Travel </apex:outputText> </apex:pageBlockSectionItem>
         <apex:pageBlockSectionItem > <apex:outputField value="{!Contact.Travel_HWC__c}" /> </apex:pageBlockSectionItem>
         <apex:pageBlockSectionItem > <apex:outputField value="{!Contact.HwC_Preferences_Notes__c}" /> </apex:pageBlockSectionItem>

   </apex:pageBlockSection>
      <div align="center"> <apex:commandButton action="{!quicksave}" value="Save" /> </div>
   </apex:pageBlock>
   </apex:form>
</apex:page>

pageBlockSection
I want to put borders on every row but it seems that my rows are not being detected as rows, and that's why I don't see borders where I want them to be, which is between the rows...
 
<apex:dataTable value="{!Contact}" var="a" align="center" border="4" cellspacing="3" cellpadding="4" rules="all">
   
       <apex:column headerValue="Hard preference?" width="50px" >
        <apex:outputField value="{!a.Handle_with_care__c}" /> <br></br>
        <apex:outputField value="{!a.Handle_with_care__c}"/>
       </apex:column>

       <apex:column headerValue="Preference Category" width="400px" >
        <apex:outputField value="{!a.Handle_with_care_description__c}" /> <br></br>
        <apex:outputText > Travel </apex:outputText>
       </apex:column>

       <apex:column headerValue="Preferences" width="300px" >
        <apex:outputField value="{!a.Geographic_HWC__c}" /> <br></br>
        <apex:outputField value="{!a.Travel_HWC__c}" />
       </apex:column>
      
       <apex:column headerValue="Additional Notes" width="300px" >
        <apex:outputField value="{!a.Geographic_Preferences_Notes__c}" /> <br></br>
        <apex:outputField value="{!a.HwC_Preferences_Notes__c}" />
       </apex:column>
      
       <apex:inlineEditSupport />
</apex:dataTable>

 
I'm new to development. How can I mimic the native SF record detail page but have more columns instead of two? I tried creating VF page but they are always in edit mode, not like the desired behavior where the field would only go on edit mode when it is double clicked.
I am new to development. I created a VF page to be used in a section of Contact page layout. But when I tried clicking the Save button from the VF page, it saves and then goes to the Contact detail page... So it becomes a Contact detail page inside a Contact detail page. How can I change it so that it refreshes the entire Contact detail page after save?
I tried learning Apex coding only to realize it will take a while to learn significant enough to create the triggers that I want which I can do with native declarative tools.

I want to know if Visualforce is faster to learn than Apex and if it's even possible to learn without learning Apex first? 
Hi all, there is a similar question but it is old and may not get another answer so I am posting it as a new question.

Is there any documentation that supports that Workflow Rules don't count against Apex CPU limits?

I know that based on experience that they don't, for the reason that I have never received any Apex CPU limit related error messages ever from Workflow rules.

That being said, I still can't find any straightforward statement from Salesforce about that.
Hi all, we want a more customizable bar chart component in lightning dashboard. For example, the bar color changes based on the end group or sub group column but we want the bar color change to be based on the main group column/ field. Also we don't want the bar scale to change into decimal increments.

Our firm is willing to pay for custom solutions but I can't find anything in AppExchange.

Hi all, so I want to know what's causing our API to reach our limit so we purchased Event Monitoring and I copy pasted the event log from Workbench but I don't know which column will tell me what I want and how to read the data. The columns that I have are:

EVENT_TYPE
TIMESTAMP
REQUEST_ID
ORGANIZATION_ID
USER_ID
RUN_TIME
CPU_TIME
URI
SESSION_KEY
LOGIN_KEY
REQUEST_STATUS
DB_TOTAL_TIME
API_TYPE
API_VERSION
CLIENT_NAME
METHOD_NAME
ENTITY_NAME
ROWS_PROCESSED
REQUEST_SIZE
RESPONSE_SIZE
DB_BLOCKS
DB_CPU_TIME
TIMESTAMP_DERIVED
USER_ID_DERIVED
CLIENT_IP
URI_ID_DERIVED
 

Thanks,
Richard

Hi everyone, I have an issue I can't seem to solve on my own. In our Org we have automated rating (of quality) of Contacts and I used Process Builder for that since I have no coding experience.

Contact Abc's correct rating should be 2. For some reason, formula A does not rate Abc as 2, but formula B does.

Formula A:
AND(
        OR(
             [Contact].Account.Is_a_Venture_Capital_Firm__c  = TRUE ,
             [Contact].Account.Is_a_Private_Equity_Firm__c = TRUE ,
             AND(
                     OR(
                          ISPICKVAL( [Contact].Title_Achieved__c , 'Manager') ,
                          ISPICKVAL( [Contact].Title_Achieved__c , 'Associate') ,
                          ISPICKVAL( [Contact].Title_Achieved__c , 'Partner')
                          ) ,
               CONTAINS(UPPER([Contact].Account_Industry_c) , 'Technology')
               )
           ) ,
         NOT( CONTAINS( UPPER([Contact].Current_Title__c) , 'STUDENT' )) ,
         NOT( CONTAINS( UPPER([Contact].Current_Title__c) , 'ENGINEER' ))
        )

Formula B
AND(
        OR(
             [Contact].Account.Is_a_Venture_Capital_Firm__c  = TRUE ,
             [Contact].Account.Is_a_Private_Equity_Firm__c = TRUE ,
             ISPICKVAL( [Contact].Title_Achieved__c , 'Manager') ,
             ISPICKVAL( [Contact].Title_Achieved__c , 'Associate') ,
             ISPICKVAL( [Contact].Title_Achieved__c , 'Partner')
              ) ,
       NOT( CONTAINS( UPPER([Contact].Current_Title__c) , 'STUDENT' )) ,
       NOT( CONTAINS( UPPER([Contact].Current_Title__c) , 'ENGINEER' ))
       )

Is there anyting wrong with my Formula A?
Hi guys,

Why are VF pages not available to be displayed in Dashboard in Lightning?
Sorry in advance, the string below is long. I don't know why I got the error message "Error: Incorrect parameter type for function 'OR()'. Expected Boolean, received Text"

OR(
    IF(
       AND(
           OR(
              PE_company__c = FALSE ,
              PE_Portfolio_Company__c = FALSE
              ) ,
           OR(
              CONTAINS(LinkedIn_Company_Size__c ,'Self-employed') ,
              CONTAINS(LinkedIn_Company_Size__c ,'2-10 employees') ,
              CONTAINS(LinkedIn_Company_Size__c ,'N/A') ,
              CONTAINS(LinkedIn_Company_Size__c ,'') 
              )
           ) ,
       
       '0.5' , '0'
       ) ,

    IF(
       OR(
          AND(
              Years_of_work_exp__c  >= 8 ,
              NOT(
                  OR(
                     CONTAINS(LinkedIn_Company_Size__c ,'Self-employed') ,
                     CONTAINS(LinkedIn_Company_Size__c ,'2-10 employees') ,
                     CONTAINS(LinkedIn_Company_Size__c ,'11-50 employees') ,
                     CONTAINS(LinkedIn_Company_Size__c ,'N/A') ,
                     CONTAINS(LinkedIn_Company_Size__c ,'') 
                     )
                  )
              ) ,
          OR(
             CONTAINS( Current_Title__c , 'director') ,
             CONTAINS( Current_Title__c , 'vice president') ,
             CONTAINS( Current_Title__c , 'president') ,
             CONTAINS( Current_Title__c , 'general manager') ,
             CONTAINS( Current_Title__c , 'chief') ,
             CONTAINS( Current_Title__c , 'officer') ,
             CONTAINS( Current_Title__c , 'CEO') ,
             CONTAINS( Current_Title__c , 'COO') ,
             CONTAINS( Current_Title__c , 'CSO') ,
             CONTAINS( Current_Title__c , 'CTO') ,
             CONTAINS( Current_Title__c , 'CFO') ,
             CONTAINS( Current_Title__c , 'CHRO') ,
             CONTAINS( Current_Title__c , 'SVP') ,
             CONTAINS( Current_Title__c , 'EVP') 
             )
          ) ,

       '1', '0'
       ) ,
    
    IF(
       AND(
           OR(
              PE_company__c = TRUE ,
              PE_Portfolio_Company__c = TRUE
              ) ,
           OR(
              Years_of_work_exp__c  >= 8 ,
              CONTAINS( Current_Title__c , 'managing director') ,
              CONTAINS( Current_Title__c , 'principal') ,
              CONTAINS( Current_Title__c , 'vice president') ,
              CONTAINS( Current_Title__c , 'president') ,
              CONTAINS( Current_Title__c , 'vp') ,
              CONTAINS( Current_Title__c , 'operating') ,
              CONTAINS( Current_Title__c , 'partner') ,
              CONTAINS( Current_Title__c , 'executive') ,
              CONTAINS( Current_Title__c , 'chief') ,
              CONTAINS( Current_Title__c , 'general manager') ,
              CONTAINS( Current_Title__c , 'officer') ,
              CONTAINS( Current_Title__c , 'CEO') ,
              CONTAINS( Current_Title__c , 'COO') ,
              CONTAINS( Current_Title__c , 'CSO') ,
              CONTAINS( Current_Title__c , 'CTO') ,
              CONTAINS( Current_Title__c , 'CFO') ,
              CONTAINS( Current_Title__c , 'CHRO') ,
              CONTAINS( Current_Title__c , 'Director') ,
              CONTAINS( Current_Title__c , 'Portfolio operations') ,
              CONTAINS( Current_Title__c , 'Talent') ,
              CONTAINS( Current_Title__c , 'Chief talent officer') ,
              CONTAINS( Current_Title__c , 'Head of HR') ,
              CONTAINS( Current_Title__c , 'SVP') ,
              CONTAINS( Current_Title__c , 'EVP') 
              )
           ) ,

       '2', '0'
       )
   )

Thanks,

Richard
I made a tab for my visualforce page just so I can get it's URL and reference it in a hyperlink in a formula field. Unfortunately since it is a tab, the page moves away from the originating page to the VF tab. How can I reference only the VF page instead of the tab?

I'm very new to development. We have a trigger that I think is bulkified but still I am getting errors whenever I mass update more than 200 contacts using Data Import Wizard.

What I don't understand is why only the first 200 contacts fail and then all other contacts in excess are updated successfully, even though they are on the same CSV upload. Does anyone know why this is the case?

Without using Einstein Analytics, what would it take to be able to link a dashboard which automatically selects a filter based on the link that I sent the user, so the user won't have to select the filters? This would be useful in our case where a dashboard have as many as 50 filters at a time.
Hope you're all in good health. Can anyone help how to reduce the width of the first column in my pageBlockSection VF page? There's just too much space for checkbox fields.
<apex:page standardController="Contact" sidebar="false" >
   <apex:form >
   <apex:inlineEditSupport />
   <apex:pageBlock mode="maindetail" >
   <apex:pageBlockSection columns="4" >

         <apex:pageBlockSectionItem > <apex:outputText > <b> Hard Pref </b> </apex:outputText> </apex:pageBlockSectionItem>
         <apex:pageBlockSectionItem > <apex:outputText > <b>Category</b> </apex:outputText> </apex:pageBlockSectionItem>
         <apex:pageBlockSectionItem > <apex:outputText > <b>Preferences</b> </apex:outputText> </apex:pageBlockSectionItem>
         <apex:pageBlockSectionItem >  <apex:outputText > <b>Notes</b> &nbsp; &nbsp;&nbsp;</apex:outputText> </apex:pageBlockSectionItem>
           
        
         <apex:pageBlockSectionItem > <apex:outputField value="{!Contact.Handle_with_care__c}" /> </apex:pageBlockSectionItem>
         <apex:pageBlockSectionItem > <apex:outputText > Geography </apex:outputText> </apex:pageBlockSectionItem>
         <apex:pageBlockSectionItem > <apex:outputField value="{!Contact.Geographic_HWC__c}" /> </apex:pageBlockSectionItem>
         <apex:pageBlockSectionItem > <apex:outputField value="{!Contact.Geographic_Preferences_Notes__c}" /> </apex:pageBlockSectionItem>
         
      
         <apex:pageBlockSectionItem > <apex:outputField value="{!Contact.Handle_with_care__c}" /> </apex:pageBlockSectionItem>
         <apex:pageBlockSectionItem > <apex:outputText > Travel </apex:outputText> </apex:pageBlockSectionItem>
         <apex:pageBlockSectionItem > <apex:outputField value="{!Contact.Travel_HWC__c}" /> </apex:pageBlockSectionItem>
         <apex:pageBlockSectionItem > <apex:outputField value="{!Contact.HwC_Preferences_Notes__c}" /> </apex:pageBlockSectionItem>

   </apex:pageBlockSection>
      <div align="center"> <apex:commandButton action="{!quicksave}" value="Save" /> </div>
   </apex:pageBlock>
   </apex:form>
</apex:page>

pageBlockSection
I want to put borders on every row but it seems that my rows are not being detected as rows, and that's why I don't see borders where I want them to be, which is between the rows...
 
<apex:dataTable value="{!Contact}" var="a" align="center" border="4" cellspacing="3" cellpadding="4" rules="all">
   
       <apex:column headerValue="Hard preference?" width="50px" >
        <apex:outputField value="{!a.Handle_with_care__c}" /> <br></br>
        <apex:outputField value="{!a.Handle_with_care__c}"/>
       </apex:column>

       <apex:column headerValue="Preference Category" width="400px" >
        <apex:outputField value="{!a.Handle_with_care_description__c}" /> <br></br>
        <apex:outputText > Travel </apex:outputText>
       </apex:column>

       <apex:column headerValue="Preferences" width="300px" >
        <apex:outputField value="{!a.Geographic_HWC__c}" /> <br></br>
        <apex:outputField value="{!a.Travel_HWC__c}" />
       </apex:column>
      
       <apex:column headerValue="Additional Notes" width="300px" >
        <apex:outputField value="{!a.Geographic_Preferences_Notes__c}" /> <br></br>
        <apex:outputField value="{!a.HwC_Preferences_Notes__c}" />
       </apex:column>
      
       <apex:inlineEditSupport />
</apex:dataTable>

 

Hi all, so I want to know what's causing our API to reach our limit so we purchased Event Monitoring and I copy pasted the event log from Workbench but I don't know which column will tell me what I want and how to read the data. The columns that I have are:

EVENT_TYPE
TIMESTAMP
REQUEST_ID
ORGANIZATION_ID
USER_ID
RUN_TIME
CPU_TIME
URI
SESSION_KEY
LOGIN_KEY
REQUEST_STATUS
DB_TOTAL_TIME
API_TYPE
API_VERSION
CLIENT_NAME
METHOD_NAME
ENTITY_NAME
ROWS_PROCESSED
REQUEST_SIZE
RESPONSE_SIZE
DB_BLOCKS
DB_CPU_TIME
TIMESTAMP_DERIVED
USER_ID_DERIVED
CLIENT_IP
URI_ID_DERIVED
 

Thanks,
Richard

Hi guys,

Why are VF pages not available to be displayed in Dashboard in Lightning?
Sorry in advance, the string below is long. I don't know why I got the error message "Error: Incorrect parameter type for function 'OR()'. Expected Boolean, received Text"

OR(
    IF(
       AND(
           OR(
              PE_company__c = FALSE ,
              PE_Portfolio_Company__c = FALSE
              ) ,
           OR(
              CONTAINS(LinkedIn_Company_Size__c ,'Self-employed') ,
              CONTAINS(LinkedIn_Company_Size__c ,'2-10 employees') ,
              CONTAINS(LinkedIn_Company_Size__c ,'N/A') ,
              CONTAINS(LinkedIn_Company_Size__c ,'') 
              )
           ) ,
       
       '0.5' , '0'
       ) ,

    IF(
       OR(
          AND(
              Years_of_work_exp__c  >= 8 ,
              NOT(
                  OR(
                     CONTAINS(LinkedIn_Company_Size__c ,'Self-employed') ,
                     CONTAINS(LinkedIn_Company_Size__c ,'2-10 employees') ,
                     CONTAINS(LinkedIn_Company_Size__c ,'11-50 employees') ,
                     CONTAINS(LinkedIn_Company_Size__c ,'N/A') ,
                     CONTAINS(LinkedIn_Company_Size__c ,'') 
                     )
                  )
              ) ,
          OR(
             CONTAINS( Current_Title__c , 'director') ,
             CONTAINS( Current_Title__c , 'vice president') ,
             CONTAINS( Current_Title__c , 'president') ,
             CONTAINS( Current_Title__c , 'general manager') ,
             CONTAINS( Current_Title__c , 'chief') ,
             CONTAINS( Current_Title__c , 'officer') ,
             CONTAINS( Current_Title__c , 'CEO') ,
             CONTAINS( Current_Title__c , 'COO') ,
             CONTAINS( Current_Title__c , 'CSO') ,
             CONTAINS( Current_Title__c , 'CTO') ,
             CONTAINS( Current_Title__c , 'CFO') ,
             CONTAINS( Current_Title__c , 'CHRO') ,
             CONTAINS( Current_Title__c , 'SVP') ,
             CONTAINS( Current_Title__c , 'EVP') 
             )
          ) ,

       '1', '0'
       ) ,
    
    IF(
       AND(
           OR(
              PE_company__c = TRUE ,
              PE_Portfolio_Company__c = TRUE
              ) ,
           OR(
              Years_of_work_exp__c  >= 8 ,
              CONTAINS( Current_Title__c , 'managing director') ,
              CONTAINS( Current_Title__c , 'principal') ,
              CONTAINS( Current_Title__c , 'vice president') ,
              CONTAINS( Current_Title__c , 'president') ,
              CONTAINS( Current_Title__c , 'vp') ,
              CONTAINS( Current_Title__c , 'operating') ,
              CONTAINS( Current_Title__c , 'partner') ,
              CONTAINS( Current_Title__c , 'executive') ,
              CONTAINS( Current_Title__c , 'chief') ,
              CONTAINS( Current_Title__c , 'general manager') ,
              CONTAINS( Current_Title__c , 'officer') ,
              CONTAINS( Current_Title__c , 'CEO') ,
              CONTAINS( Current_Title__c , 'COO') ,
              CONTAINS( Current_Title__c , 'CSO') ,
              CONTAINS( Current_Title__c , 'CTO') ,
              CONTAINS( Current_Title__c , 'CFO') ,
              CONTAINS( Current_Title__c , 'CHRO') ,
              CONTAINS( Current_Title__c , 'Director') ,
              CONTAINS( Current_Title__c , 'Portfolio operations') ,
              CONTAINS( Current_Title__c , 'Talent') ,
              CONTAINS( Current_Title__c , 'Chief talent officer') ,
              CONTAINS( Current_Title__c , 'Head of HR') ,
              CONTAINS( Current_Title__c , 'SVP') ,
              CONTAINS( Current_Title__c , 'EVP') 
              )
           ) ,

       '2', '0'
       )
   )

Thanks,

Richard
I was positive that they do not, but after searching for hours, I cannot find the documentation that states this. Am I remembering this incorrectly?
I am attempting to use a DataTable to show individual field values as "cell" values in a spreadsheet on my VisualForce page. I'm doing this by stacking the fields upon one another. This is the actual syntax I am using : 

 
<apex:pageblocksection title="Risk Assessment" showheader="true" collapsible="true" columns="1">
<apex:dataTable value="{!Vendor_Product_Review__c}" var="pitem" border="4"  align="center" cellpadding="8" > 
                             <apex:column headerValue="">
                             <apex:outputLabel >Credit   </apex:outputLabel><br></br>
                             <apex:outputLabel >Liquidity   </apex:outputLabel><br></br>
                             <apex:outputLabel >Transaction   </apex:outputLabel><br></br>
                             <apex:outputLabel >Foreign Exchange   </apex:outputLabel>
                             </apex:column>
                         
                             <apex:column headerValue="P">
                                 <apex:inputfield value="{!pitem.CreditRiskProbability__c}"/><br></br>
                                 <apex:inputfield value="{!pitem.LiquidityRiskProbability__c}"/><br></br>
                                 <apex:inputfield value="{!pitem.TransactionRiskProbability__c}"/><br></br>
                                 <apex:inputfield value="{!pitem.ForeignExchangeRiskProbability__c}"/><br></br>
                             </apex:column>
                         
                             <apex:column headerValue="S">   
                                <apex:inputfield value="{!pitem.CreditRiskSeverity__c}"/><br></br>
                                <apex:inputfield value="{!pitem.LiquidityRiskSeverity__c}"/><br></br>
                                <apex:inputfield value="{!pitem.TransactionRiskSeverity__c}"/><br></br>
                                <apex:inputfield value="{!pitem.ForeignExchangeRiskSeverity__c}"/><br></br>
                             </apex:column>
                         
                             <apex:column headerValue="C">
                              <apex:inputfield value="{!pitem.CreditControlAdequacy__c}"/><br></br>   
                              <apex:inputfield value="{!pitem.LiquidityControlAdequacy__c}"/><br></br>      
                              <apex:inputfield value="{!pitem.TransactionControlAdequacy__c}"/><br></br>      
                              <apex:inputfield value="{!pitem.ForeignExchangeControlAdequacy__c}"/><br></br>                           
                             </apex:column>
</apex:dataTable>
</apex:pageblocksection>


Is there a way for me to have the horizontal grid lines appear between each individual InputField in order to make them appear to be in their own "cell" ?

Thank you for your input.

 

  • November 13, 2015
  • Like
  • 0