• SF_Guha
  • NEWBIE
  • 9 Points
  • Member since 2013
  • Senior Technical Consultant
  • Acumen Solutions


  • Chatter
    Feed
  • 0
    Best Answers
  • 0
    Likes Received
  • 0
    Likes Given
  • 4
    Questions
  • 14
    Replies
Hi,

I am not able to send images from Email article with HTML Email in salesofrece. This is my requirement. I have one knowledge article type that contains some rich text area field in that i am placing some images and published the article. When i am sending the email article with html option from case feed based layouts answer customer section it is sending the images but when i am not able to see in outlook and gmail also. I there any way of sending the images from salesforce knowledge article through email article with HTML email.

i tried so many options like place the url, upload the image in fiels and use the url and also tried with normal url. but i am not able to display in customer email. 

User-added image

If there is any approach for the please let me know.

Any help is appreciated.

Thanks
 
On Behalf of my colleague:

I'm writing a trigger in the Case

There is a Case created with Email-to-Case. Email is present as the Related list. There is a column in the email related list which shows the sender address of the Email (Email Address in the Image).
User-added image
How to get that particular sender's address in the Trigger.

FYI. I could not find any Email related field (that forms the lookup relationship) in the Case

Please provide a work around to overcome the salesforce limitation of 500 mass email limit in enterprise edition.

 

Note: Our project has a constrain - not to use any app exchange tool for this.

 

 

  • September 06, 2013
  • Like
  • 0

I have requirement where I want to have a predictive search in my edit page of Opportunity record.

 

For example:

 

If I click on edit of any opp record and suppose if i want to do predictive search (like in google search) in Account field.
I achieved this through defining a home page component and mounted a JQuery to perform predictive search on "keyPress" Event.

 

Now the issue is it works fine in edit page. When i type "Ac" I get the Account Name "Acme" in the predictive search dropdown.

 

But in the inline edit feature(i.e, when i click on save I am taken back to read mode of the record's detail page. In that page when i double click on the field I get a inline edit functionality which allows me to enter a value without redirecting me to any other edit mode.) , I want this predictive feature to work. But it is not working.

 

Please give me a workaround to make it work in inline editing as well.

 

 

  • September 04, 2013
  • Like
  • 0
Hey guys, I'm attempting to write a test class for what I feel is a pretty simple controller. I'm learning all of this stuff so I don't know what I'm doing just yet. I went throught the trailhead and wrote the 2 test classes there which helped a little. Basically the controller I have (taken of the internet but works for what I need) checks for an existing contact then creates a lead if it doesn't exist already. This is for the liveagent chat module if that matters. Here is the code below. I tried to post this on salesforce stack exchange but got the impression I need to be more advanced to post anything there. I would appreciate any help! thanks!
 
public class LiveAgent_preChatRemoting_Con
{
public LiveAgent_preChatRemoting_Con(ApexPages.StandardController controller)
{
 
}
@RemoteAction
public static contact getcontact(string contactemail)
{
Contact testContact=new Contact();
testContact=[Select Id,Name from Contact where email=:contactemail limit 1];
return testContact;
}
 
}

Here is were I attempted to get started on a test class and hit a brick wall:
 
@isTest
public class LiveAgent_preChatRemoting_ConTests {
    public static testMethod void testMyController() {
        Contact testContact = new Contact();
        testContact = 'test@email.com';
        return testContact;
    }
}



 
Can someone please explain (and possibly fix) why the last section on my VF Page falls out of the frame?  The other frames stay within the "page" but the last section falls off.  

User-added image
 
<apex:page standardController="License_Numbers__c" recordSetvar="lic" extensions="LicenseList" showHeader="false" sidebar="false">
<!------------------------------------------------------------------------------------------------------>
<!--Based on option chosen for License Type, will show description of that license type-->
<apex:pageBlock title="License Definitions">
<apex:form id="theForm">
<apex:pageBlockSection columns="1">
<apex:selectList label="Please select a License Type"  value="{!discountScheduleID}" size="1" >
   <apex:actionSupport event="onchange" action="{!displayDescription}" rerender="description"/>
   <apex:selectOptions value="{!schedules}" />
</apex:selectList> 

<apex:outputText label="Description" id="description" value="{!OutPutString}"/>

<br></br><br></br><br></br><br></br>
</apex:pageBlockSection>
</apex:form>
</apex:pageBlock>
<!---------------------------------------------------------------------------------------------------->
<apex:form >
<!--displays the licenses that are owned by your business unit (declared on User record)-->
<apex:pageBlock title="Current Licenses">
<apex:pageBlockSection columns="1">

<apex:pageBlockTable value="{!LicenseList}" var="ln">

<apex:outputLink value="{!ln.Id}">{!ln.Name}</apex:outputLink>

<apex:column value="{!ln.Org__c}" />
<apex:column value="{!ln.Business_Unit__c}" />
<apex:column value="{!ln.BMS_Code__c}" />
<apex:column value="{!ln.License_Type__c}" />
<apex:column value="{!ln.Monthly_Unit_Price__c}" />
<apex:column headerValue="2016 Starting Amount" value="{!ln.X2016_Starting_Amount__c}" />
<apex:column headerValue="2016 Running License Total" value="{!ln.Running_License_Total__c}" />
<apex:column headerValue="2016 Annualized Cost" value="{!ln.X2016_Subtotal__c}" />
<apex:column headerValue="2016 Cost" value="{!ln.X2016_Cost__c}"/>

</apex:pageBlockTable>
</apex:pageBlockSection>

                
          
</apex:pageBlock>

</apex:form>

<apex:panelGrid columns="1">

</apex:panelGrid>



<!--------------------------------------------------------------------------------------------------------->
<apex:form id="theForm">
<apex:pageBlock id="blockId" title="2017 License Needs">
<apex:pageBlockSection columns="1">

<td>
<apex:outputText style="font-weight:800" label="Total 2017 Annualized Cost" value="${0, number, ###,###,###,##0.00}">
    <apex:param value="{!tTotal}" />
</apex:outputText>
</td>
<td>
<apex:outputText style="font-weight:800" label="Total 2017 Estimated Cost" value="${0, number, ###,###,###,##0.00}">
    <apex:param value="{!aTotal}" />
</apex:outputText>
</td>
</apex:pageBlockSection>

<!-------------------------------------------------------------------------------------------------->


<apex:pageBlockTable value="{!LicenseList17}" var="ln17">

<apex:outputLink value="{!ln17.Id}">{!ln17.Name}</apex:outputLink>
<apex:column >
<apex:commandbutton value="Edit" rerender="blockId" rendered="{!!(tobeEdited == ln17.id)}">
    <apex:param assignTo="{!tobeEdited}" value="{!ln17.id}" name="ittobeedited"/>
</apex:commandbutton>
<apex:commandButton value="Save" action="{!saveRecord}" reRender="blockId" rendered="{!tobeEdited == ln17.id}"/>
</apex:column> 

<apex:column value="{!ln17.Org__c}" />

<apex:column headerValue="BMS Code">
    <!--Allows it to be edited-->
    <apex:inputfield value="{!ln17.BMS_Code__c}" rendered="{!tobeEdited == ln17.id}"/>
    <!--After Save-->
    <apex:outputField value="{!ln17.BMS_Code__c}" rendered="{!!(tobeEdited == ln17.id)}"/>
</apex:column>    

<apex:column value="{!ln17.License_Type__c}"/>

<apex:column headerValue="BU Agrees to Pay">
    <apex:inputfield value="{!ln17.BU_Agrees_to_Pay__c}" rendered="{!tobeEdited == ln17.id}"/>
    <apex:outputField value="{!ln17.BU_Agrees_to_Pay__c}" rendered="{!!(tobeEdited == ln17.id)}"/>
</apex:column> 

<apex:column value="{!ln17.Monthly_Unit_Price__c}" />

<apex:column headerValue="2017 Number Needed">
    <apex:inputfield value="{!ln17.X2017_Total_Needed__c}" rendered="{!tobeEdited == ln17.id}"/>
    <apex:outputField value="{!ln17.X2017_Total_Needed__c}" rendered="{!!(tobeEdited == ln17.id)}"/>
</apex:column>    

<apex:column headerValue="2017 Annualized Cost" value="{!ln17.X2017_Subtotal__c}" />

<apex:column headerValue="Estimated 2017 Cost" value="{!ln17.X2017_Cost__c}"/>


</apex:pageBlockTable>

</apex:pageBlock>

<!------------------------------------------------------------------------------------------>
<apex:pageBlock title="New Licenses Needed for 2017">

<apex:pageBlockTable value="{!wrappers}" var="wrapper" id="wtable">

<apex:column HeaderValue="Org">
<apex:inputField value="{!wrapper.lic.Org__c}" />
</apex:column>

<apex:column HeaderValue="Business Unit">
<apex:inputField value="{!wrapper.lic.Business_Unit__c}" />
</apex:column>

<apex:column HeaderValue="BMS Code">
<apex:inputField value="{!wrapper.lic.BMS_Code__c}" />
</apex:column>

<apex:column HeaderValue="License Type">
<apex:inputField value="{!wrapper.lic.License_Type__c}"  />
</apex:column>

<apex:column HeaderValue="BU Agrees to Pay">
<apex:inputField value="{!wrapper.lic.BU_Agrees_to_Pay__c}" />
</apex:column>

<apex:column HeaderValue="2017 Number Needed">
<apex:inputField value="{!wrapper.lic.X2017_Total_Needed__c}" />
</apex:column>

<apex:column HeaderValue="License Year">
<apex:inputField value="{!wrapper.lic.License_Year__c}" />
</apex:column>

</apex:pageBlockTable>


</apex:pageBlock>
<apex:commandButton value="Save" action="{!save}"/>


</apex:form>

<!--------------------------------------------------------------------------------------------------------->
</apex:page>

 
  • October 13, 2016
  • Like
  • 0
HI Everybody,

I have a standard Implementation object that works very closely like the Opportunity object but has different stages and a few different fields.  I'm trying to hide/show sections of this Implementation object based on what Stage was chosen out of this picklist.  I'm able to get this working when I create a separate visualforce page with the code below but I'm having trouble embedding this in the Implementation object.  I would rather not re-create an entirely custom Implementation object and just put some inline visualforce page into a section that takes care of this functionality. 

When I embed my visualforce page it acts completely separate from the standard Implementation object.  Here is my current visualforce code:

<apex:page standardController="Implementation__c" sidebar="true" tabStyle="Implementation__c">
   
    <apex:form >
       <apex:pageBlock title="Implementation">             
           <apex:pageBlocksection columns="2">
               <apex:outputField value="{!Implementation__c.Name}"/>
                <apex:outputField value="{!Implementation__c.Closed_Date__c}"/>
               <apex:inputField value="{!Implementation__c.Stages__c}">
                <apex:actionSupport event="onchange" reRender="ab, ac"/>  
                 </apex:inputField>
            </apex:pageBlocksection>
            </apex:pageBlock>
    
        <apex:outputpanel id="ab">
                <apex:pageBlock title="Execution" rendered="{!Implementation__c.Stages__c == 'Execution I'}">
                <apex:pageBlockSection >  
                <apex:pageblocksectionItem >
                    <apex:outputField value="{!Implementation__c.Next_Steps__c}"/>
                </apex:pageBlocksectionItem>
            </apex:pageBlocksection>
            </apex:pageblock>
        </apex:outputpanel>    
 
        <apex:outputpanel id="ac">
                <apex:pageBlock title="Completion" rendered="{!Implementation__c.Stages__c == 'Completion'}">
                <apex:pageBlockSection >  
                <apex:pageblocksectionItem >
                    <apex:outputField value="{!Implementation__c.Next_Steps__c}"/>
                </apex:pageBlocksectionItem>
            </apex:pageBlocksection>
            </apex:pageblock>
        </apex:outputpanel>
        
    </apex:form>
</apex:page>

Thanks,
Jeff


 
Hi,
I need one help, i have written one vf page for user popup notification whenever user login into salesforce.thenafter  i put as default landing page(This VF page) for users.now i want to make address bar as readonly(Because users can modifi URL and login into the system with out clicking agree button). Please help me if anybody is having idea on this. Thanks for your consideration!!
This formula field on cases object displays in minutes such as "125" minutes:     (Emailed_time__c - CreatedDate) * 1440

How to show this in "2 Hours 5 Minutes"?

These articles are useless:
https://help.salesforce.com/apex/HTViewSolution?id=000004635&language=en_US

Please provide a work around to overcome the salesforce limitation of 500 mass email limit in enterprise edition.

 

Note: Our project has a constrain - not to use any app exchange tool for this.

 

 

  • September 06, 2013
  • Like
  • 0

I was able to show Monday to Friday except sunday and saturday. My problem is when the checkbox field 'nightshift__c' is true, the table should only display Monday to Thursday.
here's my code:

public Date getdisplayingdates() {
        listOfDates.clear();
            Date startDate = Date.ValueOf(leave.Leave_Date_From__c);
            Date endDate = Date.ValueOf(leave.Leave_Date_To__c);
            totaldays = startDate.daysBetween(endDate);
            boolean shift = leave.nighshift__c;
            
        if (shift == true) {
            for(integer i=0;i<=totaldays;i++) {
                Date today = startDate;
                Date startOfWeek = today.toStartOfWeek();
                Integer dayOfWeek = today.day()-startOfWeek.day();
    
                if(dayOfWeek == 0 || dayOfWeek == 6 || dayOfWeek == 1) {
                    startDate = startDate.addDays(1);
                } else {
                    listOfDates.add(startDate);
                    startDate = startDate.addDays(1);
            }
            }
        } else {
            for(integer i=0;i<=totaldays;i++) {
                Date today = startDate;
                Date startOfWeek = today.toStartOfWeek();
                Integer dayOfWeek = today.day()-startOfWeek.day();
    
                if(dayOfWeek == 0 || dayOfWeek == 6 || dayOfWeek == 5) {
                    startDate = startDate.addDays(1);
                } else {
                    listOfDates.add(startDate);
                    startDate = startDate.addDays(1);
                }
            }
            
        }
        return startDate;
    }

 

I tried adding 

 || dayOfWeek == 5

when the checkbox is unchecked but it is still displaying Friday.

Any idea what might be the problem?

  • September 04, 2013
  • Like
  • 0

Hi I am using Border Radius property in my VF page.

 

It works fine in VF page but at the same page does not sustain this style when renderd as PDF.

 

I have used many other styles on the same page like background color and border etc, which works fine in both VF page.

 

Thanks

Ashok

  • September 03, 2013
  • Like
  • 0

Hi,,

 

          i am working with service console app.. when customer click on chat button means automatically chat box is open at that time visualforce page must be lock..and after some the vf page must be unlock how can i achieve this..

  • September 02, 2013
  • Like
  • 0

Hi,

 

I have a VF page with a jQuery input field (actually a timepicker).

 

1) The NOK user scenario is the following : the user deletes the content of the input field and click immediately on the (VF) Save button.  VF has to process 2 events : - updating the field in the data model (jQuery event), and saving the data model to the database (Visualforce-managed event).

Unfortunately, the Save event does not 'wait' for the update to take place : the saved data is not up to date.

 

2) The OK scenario is the following : the user deletes the content of the input field and click somewhere else in the page, then clicks on the Save button. The data is always correctly saved to the database.

 

How can I make sure, in scenario 1) that the data gets updated before being saved ?

Thanks for any help,

Rup

I have a visualforcepage which is included in a layoutpage.

Viewlayout of this object has an override with another visual force page.

 

When I  call a pagereference methode from "inline" visualforcepage an try to leave the Iframe and load current objectpage again, salesforce creates a new URL with parameter inline=1.

By this parameter, Header and Sidebar is invisible. 

 

Code:

<apex:commandlink styleClass="btn newButton" style="text-decoration: none; margin: 2px !important;" value="Click" action="{!executeAction}" target="_parent">
</apex:commandlink>
pageRef = Page.NAME;
pageRef.getParameters().put('id',OBJECT.Id);
//pageRef = new ApexPages.StandardController(OBJECT).view();

 

 Is there a possibility to avoid getting parameter inline=1?

 

I tried:

  • new parameter inline=0
  • URL as a string
  • new redirect visualforce page

 

without success...