• CLK
  • NEWBIE
  • 430 Points
  • Member since 2010

  • Chatter
    Feed
  • 16
    Best Answers
  • 0
    Likes Received
  • 0
    Likes Given
  • 13
    Questions
  • 168
    Replies
Hi Guys

I have a problem, one of the guys in company created (via call to salesforce) an enterprise trial org over a month ago and never did setup the password and security question. They only attempted to do that yesterday and the link that's on the email seems to have expired because it does not redirect to the salesforce password setup page.

I have contacted salesforce about this but still have not recieved any feedback regarding how we can salvage the org. Has anyone ever encountered such an issue? is there a way salvage the org? because according to them they purchased licenses for the org 


Now I am tasked with finding a solution to this, any suggestions guys?

Thanks.

Hi All,

 

From apex i am sending single email message. it is not showing any errors and exceptions. but still mail is not going.

code as below.

Opportunity oppty=[select id,ownerID,owner.email from Opportunity where id = :OpptyId];
EmailTemplate OwnerChangeET= [SELECT id FROM EmailTemplate WHERE developerName = 'OpportunityChangeOwner'];

Messaging.SingleEmailMessage mail = new Messaging.SingleEmailMessage() ;
String[] toAddresses = new String[] {oppty.owner.email} ;
mail.setToAddresses(toAddresses) ;
mail.setTargetObjectId(oppty.ownerID);
mail.setWhatId(oppty.Id);
//mail.saveAsActivity = false;
mail.setSaveAsActivity(false);
mail.setTemplateId(OwnerChangeET.id);
List<Messaging.SendEmailResult> results = new list<Messaging.SendEmailResult>();
List<Messaging.SingleEmailMessage> singleEmailList= new list<Messaging.SingleEmailMessage>();
singleEmailList.add(mail);
results=Messaging.sendEmail(singleEmailList);
if (results[0].isSuccess())
System.debug('&&&& ' +results[0]);

 

in the debug i am getting success .  i have tried with with sharing and without sharing class.

 

debug:

01:26:19.829 (829047000)|SYSTEM_CONSTRUCTOR_EXIT|[38]|<init>()
01:26:19.829 (829066000)|SYSTEM_METHOD_ENTRY|[39]|LIST<Messaging.SingleEmailMessage>.add(Object)
01:26:19.829 (829088000)|SYSTEM_METHOD_EXIT|[39]|LIST<Messaging.SingleEmailMessage>.add(Object)
01:26:19.829 (829140000)|SYSTEM_METHOD_ENTRY|[40]|Messaging.sendEmail(LIST<Messaging.Email>)
01:26:19.928 (928161000)|EMAIL_QUEUE|[40]|subject: A new Opportunity has been Assigned to you, bccSender: false, saveAsActivity: false, useSignature: true, toAddresses: [praveenkumar.reddy@hp.com], targetObjectId: 005d0000000f3aSAAQ, whatId: 006Z0000003rmqcIAA, templateId: 00XG0000001eql8MAA, htmlBody: <html>
<p>Hi PraveenKumar Reddy N,</p>

<p>You have been assigned ownership of the Opportunity: TestOpportunity</p>
<p>
For more details, click the following link:</p><a href="https://hp--supportdev--c.cs11.visual.force.com/006Z0000003rmqcIAA">https://hp--supportdev--c.cs11.visual.force.com/006Z0000003rmqcIAA</a></html>, 
01:26:19.928 (928279000)|SYSTEM_METHOD_EXIT|[40]|Messaging.sendEmail(LIST<Messaging.Email>)
01:26:19.928 (928407000)|SYSTEM_METHOD_ENTRY|[42]|String.valueOf(Object)
01:26:19.928 (928464000)|SYSTEM_METHOD_EXIT|[42]|String.valueOf(Object)
01:26:19.928 (928484000)|SYSTEM_METHOD_ENTRY|[42]|System.debug(ANY)
01:26:19.928 (928494000)|USER_DEBUG|[42]|DEBUG|&&&& Messaging.SendEmailResult[getErrors=();isSuccess=true;]

Any idea please?
thanks in advance.

Hi,

 

I just programmed a bulk trigger(or tried to, because Im starting with bulk triggers) in leads that update info in leads depending on the record type and the country of the lead. The problem is that if I change the country of the lead and click on Save, the data doest get updated until I click on Edit and Save again.Isnt that weird? Does anyone know why is that?

 

Here is my trigger code:

 

trigger UpdateMerchantInterface onLead (beforeinsert,beforeupdate) {

 

Set<Id> addLeads = newSet<Id>();

 

for (Lead lead: Trigger.new){

 

if (lead.RecordTypeId=='01220000000YDkG'){

addLeads.add(lead.id);

}

elseif (lead.RecordTypeId=='012D00000002iGo' && lead.Route_to_market_del__c=='HOTELBEDS'){

addLeads.add(lead.id);

}

elseif (lead.RecordTypeId=='012D00000002iGo' && lead.Route_to_market_del__c=='BEDSONLINE'){

addLeads.add(lead.id);

}

elseif (lead.RecordTypeId=='012D00000002iGo' && lead.Route_to_market_del__c=='HOTELOPIA'){

addLeads.add(lead.id);

}

}

if(addLeads.size()>0){

               Map<Id,Lead> Updatevalues1 = new Map<Id,Lead> ([select route_to_market_del__c,RecordTypeId,Area__c,Lead_Country__c,Merchant__c,Interface__c,Invoicing_Company_Empresas__c from Lead where Id in: addLeads]);

 

     for (Lead ld2:Updatevalues1.values()){

 

               if (ld2.RecordTypeId=='012D00000002iGo' && ld2.Route_to_market_del__c=='HOTELBEDS'){//Caso de HB

                     if (ld2.Lead_Country__c=='SPAIN'){

                              ld2.Interface__c='WL';

                                        ld2.Invoicing_Company_Empresas__c='EW1';

                                        ld2.Merchant__c='WHITELABLEEUR';

                               }

               }

        }

     for (Lead l: Trigger.new){

       l.Interface__c=Updatevalues1.get(l.id).Interface__c ;

       l.Merchant__c=Updatevalues1.get(l.id).Merchant__c;

       l.Invoicing_Company_Empresas__c=Updatevalues1.get(l.id).Invoicing_Company_Empresas__c;

}

//}

}

 

I dont know why is this happening.

 

Thanks!

 

}

Hello! I have been trying to do a Test Method for the following Trigger but everything I do doesn't seem to work. Please help me in any way you can. Here is my Trigger:

 

trigger duplicamant on Mantenimiento_Gastos__c(before insert){
    for(Mantenimiento_Gastos__c c : Trigger.new)
        {
Mantenimiento_Gastos__c[] contacts=[Select id,Propiedad__c from Mantenimiento_Gastos__c Where Propiedad__c=:c.Propiedad__c];
            if (contacts.size()>0) 
             {
            c.Propiedad__c.addError('The number is already registered!');
              }
          }
}

I have tried the following Test Method but it is giving me an error and I think it is because of the id, I don't seem to find a way for it not to give me an error. Please help me!

 

@isTest
class testmantenimiento{

static testmethod void testmantenimiento(){

Integer size = 1;
List<Mantenimiento_Gastos__c> opp = new List<Mantenimiento_Gastos__c>();
for (Integer i = 0; i < size; i++)  {
   Mantenimiento_Gastos__c o = new Mantenimiento_Gastos__c();
   o.Propiedad__c = 'a0IQ0000000o962';
   opp.add(o);
}
insert opp;  
}
}



Good morning,

 

I thought I'd ask this question in case there was a standard way to implement many to many relationships.

 

What is the best way to represent many to many relationships within salesforce. I'm used to simply creating a new table to store both IDs, but don't know whether this is efficient in salesforce and the simplicity (if possible) of using a case for page layouts etc.

 

Thank you for your time,

 

Lloyd

email templates, work flow are not packaged

Error
Package upload errorThere are problems that prevent this package from being uploaded.

 

Component Type Name Problem Email Template Email Template

Lead NotifyUnable to include components from personal or unfiled folders. TechnolServices Pvt. Ltd.
Opporunity StageUnable to include components from personal or unfiled folders. Technology Services Pvt. Ltd.

Hi there, I'm creating an apex page to override the normal layout and I want a lookup field to have a default value which I am coding into the custom controller. The code I have so far is

 

 

Log_Book__c[] logbook;
    
    public Void<Log_Book__c> getlogbook(){
    
        logbook = [SELECT Id FROM Log_Book__c WHERE Owner.Id = :UserInfo.getUserId() LIMIT 1];
        }

    
    public List<Objective__c> objective = new List<Objective__c>();
    
    public List<Objective__c>  getObjective(){
       return objective; 
    }
    
    public void addObjective(){
        objective.add(new Objective__c(Log_Book__c = logbook.Id));
    }

 

 

when I try to save it I get this error

 

Error: Compile Error: Initial term of field expression must be a concrete SObject: LIST<Log_Book__c> 

 

I have tried just putting logbook instead of logbook.Id but then I get the following error:

Error: Compile Error: Invalid initial expression type for field Objective__c.Log_Book__c, expecting

 

Any ideas on this would be great.

 

Thank you for your time

 

Ezmo

  • March 09, 2011
  • Like
  • 0

Hi,

 

We have a requirement of overriding the lookup functionality in which we open a popup window which displays the records in table view and selecting any record on that list will display the name field on the parent form and stores the respective ID field on a hidden component bound with the object's reference field.

 

However there are few standard object in the salesforce (service cloud based objects) which doesn't have the name fields available. So it breaks my code and throws the runtime exception name field not found.

 

Is there any way by which I can find out the field name used to identify the record's uniqueness ? (e.g. caseNumber field available in CASE object).

 

I was wondering if we could access the search layout fields information throught apex code. Can we ?

 

Thanks & Regards,

Anand Agrawal.

 

 

Hi there,

 

How do I check if a Customer Portal User already exists for a contact. I am writing a trigger on Contact that generates a Customer Portal User for a Contact (under certain conditions) and I need to check that a Customer Portal User does not already exist for this Contact before attempting to create one.

 

Thanks in advance for your help

Hi, If someone could help me on a way to hide a standard field in Accounts module?

 

Thanks,

Pradeep Virk.

Hi 

 

I have  object called "Sales order" and "week management".Week management have some records.i have created a button on week management called "create sales order".When a user  select a record in weekmanagement by clicking it,and then click "Create sales order"  then record in a sales order record is created in sales order object.

 

I have to do this by using java script coz i had choosed use javascript to create that button. and i have to use web services.

 

How can i do that.

 

Plz help

 

Nasir

  • December 22, 2010
  • Like
  • 0

I'm trying to create a validation rule that only has to work when the date of creation is greater than a specific date (e.g. 21/12/2010).

 

With date fields I know I have to use the expression: Custom date field > DATE (2010,10,21)

 

But CreatedDate is a date/time field. How should I adapt the expression below in order to make it work?

 

 

AND
(
(ISPICKVAL( Reason_Won_lost__c ,'')),
CreatedDate > xxx),
OR
(
(ISPICKVAL( Actual_Stage__c ,'Closed lost')),
(ISPICKVAL( Actual_Stage__c ,'Closed won'))
)
)

 

 

Thanks in advance!

hi guys,

i have a requirement to make a dynamic inputText, where it should disabled or enabled according to the value of a checkbox field in an object, for example:

 

<apex:inputText value="{!My_Object__c.Quantity__c}" disabled="{!My_Object__c.Disable__c}" />

 

where Disable__c field is a checkbox field.

 

 

but i keep getting this error when i try to insert the My_Object__c.

 

 

<apex:inputText> element value must resolve to a String type!

 

 


can anyone help me with this?

thank you in advance.

 

 

Regards,

 


function redirect(){
        if(!checkClientSideValidations())
                     actionFunction();
}

<apex:actionFunction name="actionFunction" action='{!ControllerRedirectMethod}'/>

<apex:commandButton onclick="redirect();" value="Next">

As shown in above code, When i trying to redirect user from one page to another using ActionFucntion, then its not working only in IE browser. In debugging found that, it actually not calling controller action mentioned in actionFunction. On the click, its redirecting user to same page and flushing the view state. All works well in chrome.

Anyone has idea, where its going wrong or its browser specific issue?
  • February 23, 2015
  • Like
  • 0
AS per challenge - I have created "Case Escalate on High Priority" workflow field update. Still, i am getting the error on check that - "Challenge not yet complete... here's what's wrong: 
The 'Set Case to Escalated' Workflow field update action was not found."
  • January 29, 2015
  • Like
  • 0
  • January 08, 2014
  • Like
  • 0

how to specify valid domain names for email, user can have for there emailID field in our org?

Actually, I m getting error when i try to change email id in my client instance saying "domain should be xyz.com or abc.com for ur email". So there should be setting some where. So guys need your help?

  • November 09, 2011
  • Like
  • 0

System.TypeException: Invalid conversion from runtime type SET<String> to SET<Id>

 

getting this error when trying to test future method which takes parameter of SET<ID> and i am passing

SET<ID> only.

 

I dont know whay it happening, can anybody knows it.

 

 

  • October 03, 2011
  • Like
  • 0

 <apex:Commandlink value="Remove" action="{!generateQuery_RemoveCondion_click}"        rerender="pbsQueryWhereClause,pgHeader" status="asFilterProcessing">
               <apex:param assignTo="{!SelectedFilterNumber}" value="{!filterCriteria.SrNumber}"/>
</apex:Commandlink>

 

In this code apex:param i want to pass value of filterCriteria.SrNumber to parameter defined in assignTo.

But it's not working. am i doing something wrong?

  • July 11, 2011
  • Like
  • 0
I want to access parents window javascript method from lookup(child) window's javascript. For this i am using window.opener to refer parent window, but i am getting error window.opener is null Anybody has idea why this is occuring or any other way to refer parent window from child window. It's very argent friends... any help would be appriciated. Thanks in advance.
  • May 20, 2011
  • Like
  • 0

SOSL throws null exception & redirects to Std VF error page.

Any updates?

  • February 02, 2011
  • Like
  • 0

As i am facing problem installing IDE provided by Force.com, i would like to use latest eclipse which has plugins for latest force.com version. If anybody knows plz provide me the webpath of that eclipse. Thanks in Advance

  • December 31, 2011
  • Like
  • 0

As i am facing problem installing IDE provided by Force.com, i would like to use latest eclipse which has plugins for latest force.com version.

 

If anybody knows plz provide me the webpath of that eclipse.

Thanks in Advance

  • December 31, 2011
  • Like
  • 0

Hi All,

 

I am trying to install force.com IDE

All goes well except in last step it fails when installer tries to gather some packages form web

something like "com.beans.xyz"

 

is it due to proxy is enabled on my system?

 

if anybody gone through this then plz help me out. 

  • December 31, 2011
  • Like
  • 0

When i quering Account a = [Select name from acoount where id =: strId];

it throws exception System.QueryException: List has no rows for assignment to SObject

  • December 22, 2010
  • Like
  • 0

Example :

 

Public Case MyCase

{

     get

     {

           if(MyCase == null)

                 MyCase = new Case(); // do your opertion   

            return MyCase;

     }

set{}

}

 

Explation - This Property is refering itself & it does not goes into Stack overflow.

If you try same thing into other technology platform, it will cause Stack overflow.

 

Advantage -

1)No need to use private member variable in tha class.

2)As in example shown, this property will get initialized when vf page or controller class refers it. Means we are taking care of memory use

3) Avoiding null pointer exception.

  • December 17, 2010
  • Like
  • 0
Is there any salesforce App which can provide the Latitude and longitude for accounts based on the account address ?
public with sharing class controller1{
public PageReference save() {
                /Manipulation
                return null;
    }
}
I get values form page and save data in database.
After the control is back to the page, old values are displayed.

When i refresh the Page Manaully, i get the updated values.
How can i refresh the page from controller, so that i should avoid manual refresh
  • March 04, 2015
  • Like
  • 0
Our company requires visbility of emails coming through from a particular customer on our email-2-case address during the times specified below: 

Monday to Friday: 17.00 to 09.00 (OOH)
17.00 Friday to 09.00 Monday (OOH)

This is not our business hours but rather for providing OOH support for customers. Is there a way of doing this? 
Hi Guys

I have a problem, one of the guys in company created (via call to salesforce) an enterprise trial org over a month ago and never did setup the password and security question. They only attempted to do that yesterday and the link that's on the email seems to have expired because it does not redirect to the salesforce password setup page.

I have contacted salesforce about this but still have not recieved any feedback regarding how we can salvage the org. Has anyone ever encountered such an issue? is there a way salvage the org? because according to them they purchased licenses for the org 


Now I am tasked with finding a solution to this, any suggestions guys?

Thanks.
Hi All,

I am trying to create a workflow which will update a field when a new record is created new or when a particular field is updated using the formula as below. This formula works when a new record is created but fails when an update happens on it.

Any suggestions?

IF(OR(ISNEW(), ISCHANGED(MDM_DUNS_NUM__c)),"1","2")

thanks in advance
 
Hello all ,
Can any one tell me how to override a standard button with popup message
for example if the user click on new button in Account Page he need to get a popup message "Sorry you account create a new Account"
 
Hai Guyz,

I wanna pull the data from custom field of an account to opportunity field. So How to get this done?
Hello All,
Can anyone tell me how to update a list which contains Duplicate values. As we know that list can hold duplicate values but will not update if it contains duplicate values.
I tried to convert the list to Set or Map to hold unique values but the problem is we cannot perform DML operation on Set ot Map.

Any help is highly appreciated!
here in the below code am getting the list of all objects in an organisation. but i need only to select only few objects like account, contact, solutions etc.. how to get this.

<apex:page controller="dynamic1" >
    <apex:form id="op">
        <apex:pageBlock >
            <apex:pageBlockSection id="od1" columns="1">
                <apex:pageBlockSection >
                <apex:pageBlockSectionItem >
                    <apex:outputLabel value="Object List"></apex:outputLabel>
                    <apex:selectList size="1" value="{!selectedobj}">
                        <apex:selectOptions value="{!objects}" ></apex:selectOptions>
                        <apex:actionSupport action="{!details}" event="onchange" rerender="op"/>
                    </apex:selectList>
                </apex:pageBlockSectionItem>
                    </apex:pageBlockSection>
                <br/>
                <br/>
                <br/>         
                <apex:pageBlockSection >
               <apex:pageBlockSectionItem >
           <apex:outputLabel value="fields List:"></apex:outputLabel>

                    <apex:panelGrid columns="3" id="od" >
                        <apex:panelGroup style="width:40%" >
                            <apex:selectList size="6" value="{!sfields}" multiselect="true" style="width:200px;hieght:150px;">
                                <apex:selectOptions value="{!fnoption}"></apex:selectOptions>
                            </apex:selectList>
                        </apex:panelGroup>
                        <apex:panelGroup style="width:20%;hieght:120px;">
                            <table hieght="120px">
                                <tr><td><apex:commandButton value="Add" action="{!addfields}" style="width:80px;" reRender="od"  /> </td></tr>
                                <tr><td><apex:commandButton value="Remove" action="{!removefields}" style="width:80px;" reRender="od1"  /> </td></tr>
                            </table>
                        </apex:panelGroup>
                        <apex:panelGroup >
                            <apex:selectList size="6"  value="{!rfields}" multiselect="true" style="width:200px;hieght:150px;">
                                <apex:selectOptions value="{!fsoption}"></apex:selectOptions>
                            </apex:selectList>
                        </apex:panelGroup>
                    </apex:panelGrid>
                </apex:pageBlockSectionItem>
                    </apex:pageBlockSection>
                <apex:pageBlockSectionItem >
                    <apex:pageBlockTable value="{!mydata}" var="a" >
                        <apex:repeat value="{!myfields}" var="b">
                            <apex:column value="{!a[b]}"/>
                        </apex:repeat>
                    </apex:pageBlockTable>
                </apex:pageBlockSectionItem>
            </apex:pageBlockSection>
            <br/>
            <br/>
            <br/>
            <apex:commandButton value="click" action="{!querymydata}" reRender="op"/>{!query}
        </apex:pageBlock>    
    </apex:form>
</apex:page>

controller:
-----------------
 public class dynamic1 {
    
    public list<selectoption>objects{set;get;}
    public list<selectoption>fsoption{set;get;}
    public list<selectoption>fnoption{set;get;}
    public list<string> sfields{set;get;}
    public list<string> rfields{set;get;}
    public list<string>objlst{set;get;}
    public list<string>fields{set;get;}
    public set<string>fselected{set;get;}
    public set<string>fnotselected{set;get;}
    public map<string,schema.SObjectField> mfields;
    public map<string,schema.SObjectType> mobjects{set;get;}
    public string selectedobj{set;get;}
    public string objdiscription{set;get;}
    public string query{set;get;}
    public list<string>myfields{set;get;} 
    public list<sobject>mydata{set;get;}
    public dynamic1(){
        myfields=new list<string>();
        mydata=new list<sobject>();
        objects=new list<selectoption>();
        objlst=new list<string>();
        sfields=new list<string>();
        rfields=new list<string>();
        fields=new list<string>();
        fselected=new set<string>();
        fnotselected=new set<string>();
        fsoption=new list<selectoption>();
        fnoption=new list<selectoption>();
        mobjects=schema.getGlobalDescribe();
        objlst.addall(mobjects.keyset());
            objlst.sort();
        selectoption p=new selectoption('none','-none-');
        objects.add(p);
        for(string s:objlst){
            selectoption op=new selectoption(s,s);
            objects.add(op);
        }
        
    }
    
    public void details(){
        schema.DescribeSObjectResult mobj=mobjects.get(selectedobj).getDescribe();
        mfields=mobjects.get(selectedobj).getDescribe().fields.getMap();
        fields.addAll(mfields.keySet());
        fnotselected.addAll(fields);
        show();
    }
    public void show(){
 fnoption.clear();
        fsoption.clear();
        for(string s:fnotselected){
            selectoption op=new selectoption(s,s);
            fnoption.add(op);
        }
        for(string s1:fselected){
            selectoption op1=new selectoption(s1,s1);
            fsoption.add(op1);
            
        }
        
    }
    public void addfields(){
        fnotselected.removeAll(sfields);
        fselected.addAll(sfields);
        show();
    }
    public void removefields(){
        fnotselected.addAll(rfields);
        fselected.removeAll(rfields);
        show();
    }
    public void querymydata(){
         query ='select id';
        myfields.addAll(fselected);
        for(string s:fselected){
            query=query+','+s;
        }
        query=query + ' from ' + selectedobj;
        mydata=database.query(query);
    }
}
Can somebody help with the below issue

I need to add 5 fields to a sales rep account. The fields are
  1. Bonus (currency)
  2. Elite Joining Date (date field)
  3. Match Amount (Currency)
  4. Match Earning (Match Amount * 2)
  5. Total Stash (Bonus + My Stash + Match Earning)
The fields must be able to track history in case the amount is changed on a monthly basis.  For ex:
------------------------------
Month | Match Earning | Bonus
-----------------------------
Jan      | $50                  |  $160
Feb      | $70                 |  $150


I was able to add to add the fields. But was not able to find how to track the changes on the monthly basics?

Thanks
Hi All,

I am developing a desktop application, inside which I want to invoke Salesforce UI using a OCX browser controller. Till now this is working for me. Now what I wanted to is display the Contact details of a particular Contact whose Phone Number or Email I get from the server to which my application will be talking.

I wanted to know if there is way, I can display the Contact details of based on the Phone Number or Email I get? All I can do with the OCX browser controller is create a url string, which I can pass to the OCX browser controller to open that URL. So is there a way I can search a particular Contact and open its details page based on a constructed URL using the Contacts Phone or Email?

Any suggestion on this would be very much appreciated.

Thanks,
Dhiraj
I am experimenting with sending emails with attachments and get the this error message when I run the following code:
System.EmailException: SendEmail failed. First exception on row 0; first error: INVALID_ID_FIELD, Invalid template id.: []

Suggestions?

public class EmailManager {

    // Public method
    public void sendMail(String address, String subject, String body) {
        // Create an email message object
        Messaging.SingleEmailMessage mail = new Messaging.SingleEmailMessage();
        String[] toAddresses = new String[] {address};
        //List<String> docid=new List<String>{'015o00000017GD1'}; // Give the document ID here
        mail.setToAddresses(toAddresses);
        mail.setSubject(subject);
        mail.setPlainTextBody(body);
        //mail.setDocumentAttachments(docid);
        mail.setTargetObjectId('003o0000005g1v8');
        mail.setTemplateID('01Ho0000000TQmj');
        mail.setSaveAsActivity(false);
        
        // Pass this email message to the built-in sendEmail method 
        // of the Messaging class
        Messaging.SendEmailResult[] results = Messaging.sendEmail(
                                 new Messaging.SingleEmailMessage[] { mail });
        
        // Call a helper method to inspect the returned results
        inspectResults(results);
    }
    
    // Helper method
    private static Boolean inspectResults(Messaging.SendEmailResult[] results) {
        Boolean sendResult = true;
        
        // sendEmail returns an array of result objects.
        // Iterate through the list to inspect results. 
        // In this class, the methods send only one email, 
        // so we should have only one result.
        for (Messaging.SendEmailResult res : results) {
            if (res.isSuccess()) {
                System.debug('Email sent successfully');
            }
            else {
                sendResult = false;
                System.debug('The following errors occurred: ' + res.getErrors());                 
            }
        }
        
        return sendResult;
    }

}
Hey Everyone,

I am using custom history object for tracking particular field. But somehow i am getting newValue and oldValue as null value. Can anyone please help me on this. If i do the same with lookfield then it shows newValue and OldValue but for otherfields the value is null.

Regards,
Raj
  • February 11, 2015
  • Like
  • 0
Hi all,

 Once we convert a LEAD by default Account, Contact, Opp. all converted.
But my scenario is: Once we convert a LEAD after 3 hours the Account,contact,Opp, will start to convert. Incase anybody try to convert all these objects at that time we need to get ERROR MESSAGE like this " session will be start after 3 hours".

Help me............

Regards
Viswanadh  
I completed the challenge, earning the Force.com basics and Date Modeling badges, however I did so under a different login than my Salesforce employee login. I was having trouble accessing the developer zone and created a seperate account for it. Can I have the badges under my developer edition login transferred to my normal Salesforce employee login and am I still qualified for the t-shirt giveaway?