function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
ForceLoverForceLover 

Authorization Required Error Page

Hi Everyone,

 

I created a VF form which will seach for REFID__c(unique) field in lead object if it matches it retrives the details from lead.IT is working fine.I'm using this page in the site here while i'm clicking the seach button it is showing mw the Authorization required page.I checked all the permissions object ,fields,Apex class, VF all are correct.Here is my code

 

<apex:page standardController="Lead" extensions="LeadUpdate" showHeader="false" sidebar="false">

<head>
    <style>
        .startStyle{
            font-size:12px;
            font-weight:bold;
            color:red;
        }     
    </style>
</head>
<apex:image id="logo" value="{!$Resource.CompanyLogo}"  style="align: left;" height="75" width="233"/>
  <apex:sectionHeader title="{!Lead.Name}" subtitle="Lead Form"/>
  <apex:form id="frm">
    <div style="width:1400px; padding-left:5%; ">
    <apex:pageBlock mode="edit" id="block">
 
      <apex:pageBlockButtons location="both">
        <apex:commandButton action="{!save}" value="Save Records" rerender="frm"/>
        <apex:commandButton action="{!cancel}" value="Cancel"/>
      </apex:pageBlockButtons>
      <apex:pageMessages escape="false"/>
 
      <apex:pageBlockSection >
        <apex:pageBlockSectionItem >
          <apex:outputLabel for="searchText" style="font-size:14px">RefID/FileNumber</apex:outputLabel>
          <apex:panelGroup >
          <apex:inputText id="searchText" value="{!searchText}"/>
          <apex:commandButton value="Search" action="{!search}" rerender="block" status="status"/>
          </apex:panelGroup>
        </apex:pageBlockSectionItem>
      </apex:pageBlockSection><br/>
 
      <apex:actionStatus id="status" startText="Searching... please wait..."/>
      <apex:pageBlockSection title="Lead Results" id="resultsBlock" columns="1">
        <apex:pageBlockTable value="{!searchResults}" var="Lead" rendered="{!NOT(ISNULL(searchResults))}">
          <apex:column value="{!Lead.Name}" headerValue="LeadName" width="100"/>
          <apex:column value="{!Lead.Street}" headerValue="Street" width="100"/>
          <apex:column value="{!Lead.City}" headerValue="City" width="100"/>
          <apex:column value="{!Lead.State}" headerValue="State" width="100"/>
        
        <!--  <apex:column headerValue="First Name" width="100">
            <apex:inputField value="{!Lead.FirstName}"/>
          </apex:column>
          <apex:column headerValue="Last Name" width="100">
            <apex:inputField value="{!Lead.LastName}"/>
          </apex:column> -->
          
          <apex:column headerValue="Email" width="100" style="font-size:12px">
            <apex:inputField value="{!Lead.Email}"/>
          </apex:column>
          <apex:column headerValue="Phone" width="100">
            <apex:inputField value="{!Lead.Phone}"/>
          </apex:column>
          <apex:column headerValue="Evening Phone" width="100">
            <apex:inputField value="{!Lead.Evening_Phone__c}"/>
          </apex:column>
          <apex:column headerValue="Preferred Call Time" width="100">
            <apex:inputField value="{!Lead.Preferred_Call_Time__c}"/>
          </apex:column>
          <apex:column headerValue="Notes" width="100">
            <apex:inputField value="{!Lead.Notes__c}"/>
          </apex:column>
          <apex:column headerValue="Do Not Call" width="100">
            <apex:inputField value="{!Lead.DoNotCall}"/>
          </apex:column>
          
        </apex:pageBlockTable>
      </apex:pageBlockSection>
    </apex:pageBlock>
    </div>
  </apex:form>
</apex:page>

 

controller

 

public with sharing class LeadUpdate {
 
  private ApexPages.StandardController controller {get; set;}
  public List<Lead> searchResults {get;set;}
  public string searchText {get;set;}
 

  public LeadUpdate(ApexPages.StandardController controller) { }
 

  public PageReference search() {
    String qry = 'select id, name, FirstName, LastName, Status, Ref_ID_File_Number__c, Email, Phone, Street, City, State, Country, PostalCode, TAB_Message__c, Evening_Phone__c, Preferred_Call_Time__c, Notes__c from Lead ' +
      'where Ref_ID_File_Number__c =:searchText order by name';
    searchResults = Database.query(qry);
    if(searchResults.size()==0){

       ApexPages.addmessage(new ApexPages.message(ApexPages.severity.WARNING,'<b>Ref ID could not be found. The syntax is always as follows: AANNNN-NNNNN (A= Alpha/Letter; N= Number) i.e. FL0301-12345</b>'));
       return null;    
    }else{
    
       ApexPages.addmessage(new ApexPages.message(ApexPages.severity.Info,'<b>Please confirm name and address below. Address will be where the letter was received/addressed. If these do not match, you will need to re-verify Ref ID, as it may have been entered incorrectly</b>'));
       return null;
    }
    return null;
  }
 

  public PageReference save() {
   
   if(!(String.isEmpty(searchText))){
          
       try {
      
         list<lead> lstupdate = new list<lead>();
             
             For(Lead le:searchResults){
             
             //le.Id = lead.Id;
             le.Ref_ID_File_Number__c = searchResults[0].Ref_ID_File_Number__c ;
             le.FirstName = searchResults[0].FirstName;
             le.LastName = searchResults[0].LastName;
             le.Email = searchResults[0].Email;
             le.Status = 'Missed Call';
             le.Phone = searchResults[0].Phone;
             le.Evening_Phone__c = searchResults[0].Evening_Phone__c ;
             le.Preferred_Call_Time__c = searchResults[0].Preferred_Call_Time__c;
             le.Notes__c = searchResults[0].Notes__c;
             le.DoNotCall = searchResults[0].DoNotCall;
             le.TAB_Message__c = True;
             le.TAB_Timestamp__c = System.now();
             lstupdate.add(le);
             }
             
             update lstupdate;
      
      ApexPages.addmessage(new ApexPages.message(ApexPages.severity.info,'Record <b>'+searchResults[0].Name+'</b> has been Updated'));
            //creating a task
            Task tsknew = new Task();
            tskNew.WhoId =searchResults[0].id;
            tskNew.Subject = 'Call';
            insert tsknew; 
            
    } Catch (DMLException e) {
      ApexPages.addMessages(e);
      return null;
    }
   
    searchText='';
    searchResults.clear(); 
    return null;
       
  }
  else
  {
       ApexPages.addmessage(new ApexPages.message(ApexPages.severity.info,'Please enter REFID/FileNumber'));
  }
  
  return null;
 
}
  public PageReference cancel() {
       
       pageReference pg1 = new pageReference('/apex/leadform1');
       return(pg1.setredirect(true));
       
  }
 
}

 

prakash_sfdcprakash_sfdc
The Site User will have a profile assigned to it. Something like a Guest User. You need to give access to this page to that profile.

Such error also comes when there is some exception, hence keep an eye on debug logs as well.

The profile assigned to the Site won't be shown in the list of profiles.
Follow the steps:
Develop->Sites->Select Site->Click on Public Access Settings button->Make changes here
ManoharSFManoharSF

I recently worked on similar project to create and then query and update lead from force.com site.

 

after much struggle, I came to know that you cannot query or update standard object records but you can do that on custom object. you can just use create operation.

 

so inorder to achive my requirement, I used a custom object and then was able to perform all these operations.

 

the ultimate goal was to convert that to account and contact, that i achived using custom button and apex code behind in similar lines as Convert Lead operation.

 

Public Access Settings, etc wont help you for leads or any standard object.

 

hope this helps you.

 

 

 

ForceLoverForceLover

Hi,

 

Yeah as i mentioned i given all the permissions ,and as per my knoeledge i'm not getting any error here is my Debug log code

can you tell me where i'm going wrong

 

27.0 APEX_CODE,DEBUG;APEX_PROFILING,INFO;CALLOUT,INFO;DB,INFO;SYSTEM,DEBUG;VALIDATION,INFO;VISUALFORCE,INFO;WORKFLOW,INFO
07:48:44.036 (36138000)|EXECUTION_STARTED
07:48:44.036 (36185000)|CODE_UNIT_STARTED|[EXTERNAL]|066c00000008l5F|VF: /apex/leadform1
07:48:44.036 (36434000)|VF_DESERIALIZE_VIEWSTATE_BEGIN|066c00000008l5F
07:48:44.053 (53842000)|VF_DESERIALIZE_VIEWSTATE_END
07:48:44.059 (59451000)|CODE_UNIT_STARTED|[EXTERNAL]|01pc000000097l4|LeadUpdate get(searchResults)
07:48:44.059 (59471000)|SYSTEM_MODE_ENTER|true
07:48:44.059 (59489000)|CODE_UNIT_STARTED|[EXTERNAL]|01pc000000097l4|searchResults
07:48:44.059 (59527000)|METHOD_ENTRY|[1]|01pc000000097l4|LeadUpdate.LeadUpdate()
07:48:44.059 (59542000)|SYSTEM_MODE_ENTER|false
07:48:44.059 (59553000)|SYSTEM_MODE_EXIT|false
07:48:44.059 (59564000)|METHOD_EXIT|[1]|LeadUpdate
07:48:44.059 (59574000)|CODE_UNIT_FINISHED|searchResults
07:48:44.059 (59584000)|CODE_UNIT_FINISHED|LeadUpdate get(searchResults)
07:48:44.068 (68668000)|CODE_UNIT_STARTED|[EXTERNAL]|01pc000000097l4|LeadUpdate get(searchText)
07:48:44.068 (68688000)|SYSTEM_MODE_ENTER|true
07:48:44.068 (68699000)|CODE_UNIT_STARTED|[EXTERNAL]|01pc000000097l4|searchText
07:48:44.068 (68713000)|CODE_UNIT_FINISHED|searchText
07:48:44.068 (68721000)|CODE_UNIT_FINISHED|LeadUpdate get(searchText)
07:48:44.071 (71443000)|CODE_UNIT_STARTED|[EXTERNAL]|LeadUpdate set(searchText,DD123-45689)
07:48:44.071 (71462000)|SYSTEM_MODE_ENTER|true
07:48:44.071 (71473000)|CODE_UNIT_STARTED|[EXTERNAL]|LeadUpdate set(searchText,DD123-45689)
07:48:44.071 (71513000)|CODE_UNIT_FINISHED|LeadUpdate set(searchText,DD123-45689)
07:48:44.071 (71523000)|CODE_UNIT_FINISHED|LeadUpdate set(searchText,DD123-45689)
07:48:44.071 (71574000)|CODE_UNIT_STARTED|[EXTERNAL]|01pc000000097l4|LeadUpdate get(searchResults)
07:48:44.071 (71589000)|SYSTEM_MODE_ENTER|true
07:48:44.071 (71598000)|CODE_UNIT_STARTED|[EXTERNAL]|01pc000000097l4|searchResults
07:48:44.071 (71610000)|CODE_UNIT_FINISHED|searchResults
07:48:44.071 (71619000)|CODE_UNIT_FINISHED|LeadUpdate get(searchResults)
07:48:44.074 (74717000)|CODE_UNIT_STARTED|[EXTERNAL]|01pc000000097l4|LeadUpdate invoke(save)
07:48:44.074 (74777000)|SYSTEM_MODE_ENTER|false
07:48:44.074 (74801000)|METHOD_ENTRY|[30]|01pc000000097l4|LeadUpdate.__sfdc_searchText()
07:48:44.074 (74838000)|METHOD_EXIT|[30]|01pc000000097l4|LeadUpdate.__sfdc_searchText()
07:48:44.074 (74866000)|SYSTEM_METHOD_ENTRY|[30]|String.isEmpty(String)
07:48:44.074 (74885000)|SYSTEM_METHOD_EXIT|[30]|String.isEmpty(String)
07:48:44.074 (74944000)|SYSTEM_CONSTRUCTOR_ENTRY|[34]|<init>()
07:48:44.074 (74976000)|SYSTEM_CONSTRUCTOR_EXIT|[34]|<init>()
07:48:44.074 (74993000)|METHOD_ENTRY|[36]|01pc000000097l4|LeadUpdate.__sfdc_searchResults()
07:48:44.075 (75020000)|METHOD_EXIT|[36]|01pc000000097l4|LeadUpdate.__sfdc_searchResults()
07:48:44.075 (75036000)|SYSTEM_METHOD_ENTRY|[36]|LIST<Lead>.iterator()
07:48:44.075 (75277000)|SYSTEM_METHOD_EXIT|[36]|LIST<Lead>.iterator()
07:48:44.075 (75302000)|SYSTEM_METHOD_ENTRY|[36]|system.ListIterator.hasNext()
07:48:44.075 (75322000)|SYSTEM_METHOD_EXIT|[36]|system.ListIterator.hasNext()
07:48:44.075 (75380000)|METHOD_ENTRY|[39]|01pc000000097l4|LeadUpdate.__sfdc_searchResults()
07:48:44.075 (75402000)|METHOD_EXIT|[39]|01pc000000097l4|LeadUpdate.__sfdc_searchResults()
07:48:44.075 (75485000)|METHOD_ENTRY|[40]|01pc000000097l4|LeadUpdate.__sfdc_searchResults()
07:48:44.075 (75508000)|METHOD_EXIT|[40]|01pc000000097l4|LeadUpdate.__sfdc_searchResults()
07:48:44.075 (75581000)|METHOD_ENTRY|[41]|01pc000000097l4|LeadUpdate.__sfdc_searchResults()
07:48:44.075 (75603000)|METHOD_EXIT|[41]|01pc000000097l4|LeadUpdate.__sfdc_searchResults()
07:48:44.075 (75667000)|METHOD_ENTRY|[42]|01pc000000097l4|LeadUpdate.__sfdc_searchResults()
07:48:44.075 (75689000)|METHOD_EXIT|[42]|01pc000000097l4|LeadUpdate.__sfdc_searchResults()
07:48:44.075 (75785000)|METHOD_ENTRY|[44]|01pc000000097l4|LeadUpdate.__sfdc_searchResults()
07:48:44.075 (75806000)|METHOD_EXIT|[44]|01pc000000097l4|LeadUpdate.__sfdc_searchResults()
07:48:44.075 (75873000)|METHOD_ENTRY|[45]|01pc000000097l4|LeadUpdate.__sfdc_searchResults()
07:48:44.075 (75895000)|METHOD_EXIT|[45]|01pc000000097l4|LeadUpdate.__sfdc_searchResults()
07:48:44.075 (75956000)|METHOD_ENTRY|[46]|01pc000000097l4|LeadUpdate.__sfdc_searchResults()
07:48:44.075 (75978000)|METHOD_EXIT|[46]|01pc000000097l4|LeadUpdate.__sfdc_searchResults()
07:48:44.076 (76040000)|METHOD_ENTRY|[47]|01pc000000097l4|LeadUpdate.__sfdc_searchResults()
07:48:44.076 (76062000)|METHOD_EXIT|[47]|01pc000000097l4|LeadUpdate.__sfdc_searchResults()
07:48:44.076 (76130000)|METHOD_ENTRY|[48]|01pc000000097l4|LeadUpdate.__sfdc_searchResults()
07:48:44.076 (76153000)|METHOD_EXIT|[48]|01pc000000097l4|LeadUpdate.__sfdc_searchResults()
07:48:44.076 (76238000)|SYSTEM_METHOD_ENTRY|[50]|System.now()
07:48:44.076 (76271000)|SYSTEM_METHOD_EXIT|[50]|System.now()
07:48:44.076 (76336000)|SYSTEM_METHOD_ENTRY|[51]|LIST<Lead>.add(Object)
07:48:44.076 (76374000)|SYSTEM_METHOD_EXIT|[51]|LIST<Lead>.add(Object)
07:48:44.076 (76387000)|SYSTEM_METHOD_ENTRY|[36]|system.ListIterator.hasNext()
07:48:44.076 (76404000)|SYSTEM_METHOD_EXIT|[36]|system.ListIterator.hasNext()
07:48:44.076 (76486000)|DML_BEGIN|[54]|Op:Update|Type:Lead|Rows:1
07:48:44.168 (168217000)|CODE_UNIT_STARTED|[EXTERNAL]|Validation:Lead:00Qc00000022VPt
07:48:44.168 (168240000)|VALIDATION_RULE|03dE0000000M76C|Change_Owner_Alert
07:48:44.188 (188528000)|VALIDATION_FORMULA|AND(OwnerId <> $User.Id,  $UserRole.Name ='Sales Rep')|OwnerId=005c0000000KP2O , $UserRole.Name=Executive , $User.Id=005c0000000KP2O
07:48:44.188 (188543000)|VALIDATION_PASS
07:48:44.188 (188549000)|CODE_UNIT_FINISHED|Validation:Lead:00Qc00000022VPt
07:48:44.266 (266720000)|ENTERING_MANAGED_PKG|leadconvertchtr
07:48:44.267 (267644000)|SOQL_EXECUTE_BEGIN|[22]|Aggregations:0|select Id, firstname, Name, isConverted, masterRecordId from Lead where Id IN :tmpVar1
07:48:44.284 (284705000)|SOQL_EXECUTE_END|[22]|Rows:1
07:48:44.287 (287687000)|CODE_UNIT_STARTED|[EXTERNAL]|Workflow:Lead
07:48:44.298 (298600000)|WF_RULE_EVAL_BEGIN|Assignment
07:48:44.298 (298627000)|WF_SPOOL_ACTION_BEGIN|Assignment
07:48:44.298 (298636000)|WF_ACTION|.
07:48:44.298 (298648000)|WF_RULE_EVAL_BEGIN|Response
07:48:44.298 (298660000)|WF_RULE_EVAL_BEGIN|Workflow
07:48:44.298 (298697000)|WF_CRITERIA_BEGIN|[Lead: Shah Tresko 00Qc00000022VPt]|Opp Stage Update|01QE0000000M12N|ON_ALL_CHANGES
07:48:44.303 (303808000)|WF_RULE_FILTER|[Lead : Lead Status not equal to null]
07:48:44.303 (303901000)|WF_RULE_EVAL_VALUE|Missed Call
07:48:44.303 (303909000)|WF_CRITERIA_END|true
07:48:44.305 (305128000)|WF_CRITERIA_BEGIN|[Lead: Shah Tresko 00Qc00000022VPt]|Lead Read by Owner Timestamp|01QE0000000Llja|ON_CREATE_OR_TRIGGERING_UPDATE
07:48:44.305 (305262000)|WF_RULE_NOT_EVALUATED
07:48:44.305 (305280000)|WF_CRITERIA_BEGIN|[Lead: Shah Tresko 00Qc00000022VPt]|OwnerId <> LastModifiedById|01QE0000000LcUV|ON_ALL_CHANGES
07:48:44.305 (305777000)|WF_FORMULA|Formula:AND(OwnerId <> LastModifiedById, $UserRole.Name = 'Sales Rep ')|Values:OwnerId=005c0000000KP2O, $UserRole.Name=Executive, LastModifiedById=005c0000000KP2O
07:48:44.305 (305788000)|WF_CRITERIA_END|false
07:48:44.305 (305804000)|WF_CRITERIA_BEGIN|[Lead: Shah Tresko 00Qc00000022VPt]|Lead: Down Payment|01QE0000000LztA|ON_ALL_CHANGES
07:48:44.305 (305832000)|WF_RULE_FILTER|[Lead : Lead Status not equal to null]
07:48:44.305 (305848000)|WF_RULE_EVAL_VALUE|Missed Call
07:48:44.305 (305853000)|WF_CRITERIA_END|true
07:48:44.305 (305869000)|WF_CRITERIA_BEGIN|[Lead: Shah Tresko 00Qc00000022VPt]|Lead: Status Mailed - Missed Call|01QE0000000LztB|ON_ALL_CHANGES
07:48:44.305 (305910000)|WF_RULE_FILTER|[Lead : Lead Status equals New, Mailed] 
AND [Lead : Last Call Result equals Not Available, Left Message]
07:48:44.305 (305932000)|WF_RULE_EVAL_VALUE|Missed Call
07:48:44.305 (305937000)|WF_CRITERIA_END|false
07:48:44.305 (305948000)|WF_CRITERIA_BEGIN|[Lead: Shah Tresko 00Qc00000022VPt]|Lead: Nick Avila Campaign Update|01QE0000000LzoA|ON_CREATE_OR_TRIGGERING_UPDATE
07:48:44.306 (306008000)|WF_RULE_FILTER|[Campaign : Campaign Name equals Nick Avila Self-Gen] 
AND [Campaign : Campaign Name does not contain CMS, Affiliate, In-House, ENCORE VD, LRG] 
AND [Lead : Lead Source not equal to Seminar - Partner, Trade Show, Web, Advertisement, Public Relations, Seminar - Internal, Direct Mail, Partner]
07:48:44.306 (306020000)|WF_CRITERIA_END|false
07:48:44.306 (306040000)|WF_SPOOL_ACTION_BEGIN|Workflow
07:48:44.307 (307180000)|WF_ACTION| Field Update: 2;
07:48:44.307 (307198000)|WF_RULE_EVAL_BEGIN|Escalation
07:48:44.307 (307206000)|WF_RULE_EVAL_END
07:48:44.307 (307272000)|WF_ACTIONS_END| Field Update: 2;
07:48:44.307 (307281000)|CODE_UNIT_FINISHED|Workflow:Lead
07:48:44.309 (309351000)|DML_END|[54]
07:48:44.309 (309557000)|METHOD_ENTRY|[56]|01pc000000097l4|LeadUpdate.__sfdc_searchResults()
07:48:44.309 (309589000)|METHOD_EXIT|[56]|01pc000000097l4|LeadUpdate.__sfdc_searchResults()
07:48:44.309 (309718000)|SYSTEM_METHOD_ENTRY|[56]|ApexPages.addMessage(ApexPages.Message)
07:48:44.309 (309754000)|VF_PAGE_MESSAGE|Record <b>Shah Tresko</b> has been Updated
07:48:44.309 (309766000)|SYSTEM_METHOD_EXIT|[56]|ApexPages.addMessage(ApexPages.Message)
07:48:44.309 (309952000)|METHOD_ENTRY|[59]|01pc000000097l4|LeadUpdate.__sfdc_searchResults()
07:48:44.309 (309978000)|METHOD_EXIT|[59]|01pc000000097l4|LeadUpdate.__sfdc_searchResults()
07:48:44.311 (311704000)|DML_BEGIN|[61]|Op:Insert|Type:Task|Rows:1
07:48:45.108 (1108359000)|CODE_UNIT_STARTED|[EXTERNAL]|01qc00000008YBY|activitycall2 on Task trigger event AfterInsert for [00Tc0000004PzpF]
07:48:45.108 (1108759000)|SYSTEM_CONSTRUCTOR_ENTRY|[2]|<init>(Integer)
07:48:45.108 (1108809000)|SYSTEM_CONSTRUCTOR_EXIT|[2]|<init>(Integer)
07:48:45.108 (1108892000)|SYSTEM_CONSTRUCTOR_ENTRY|[3]|<init>(Integer)
07:48:45.108 (1108929000)|SYSTEM_CONSTRUCTOR_EXIT|[3]|<init>(Integer)
07:48:45.108 (1108977000)|SYSTEM_METHOD_ENTRY|[6]|LIST<Task>.iterator()
07:48:45.109 (1109249000)|SYSTEM_METHOD_EXIT|[6]|LIST<Task>.iterator()
07:48:45.109 (1109282000)|SYSTEM_METHOD_ENTRY|[6]|system.ListIterator.hasNext()
07:48:45.109 (1109312000)|SYSTEM_METHOD_EXIT|[6]|system.ListIterator.hasNext()
07:48:45.109 (1109378000)|SYSTEM_METHOD_ENTRY|[6]|system.ListIterator.hasNext()
07:48:45.109 (1109396000)|SYSTEM_METHOD_EXIT|[6]|system.ListIterator.hasNext()
07:48:45.109 (1109424000)|SYSTEM_METHOD_ENTRY|[15]|SET<Id>.isEmpty()
07:48:45.109 (1109455000)|SYSTEM_METHOD_EXIT|[15]|SET<Id>.isEmpty()
07:48:45.587 (1109483000)|CUMULATIVE_LIMIT_USAGE
07:48:45.587|LIMIT_USAGE_FOR_NS|(default)|
  Number of SOQL queries: 0 out of 100
  Number of query rows: 0 out of 50000
  Number of SOSL queries: 0 out of 20
  Number of DML statements: 2 out of 150
  Number of DML rows: 2 out of 10000
  Number of code statements: 24 out of 200000
  Maximum heap size: 0 out of 6000000
  Number of callouts: 0 out of 10
  Number of Email Invocations: 0 out of 10
  Number of fields describes: 0 out of 100
  Number of record type describes: 0 out of 100
  Number of child relationships describes: 0 out of 100
  Number of picklist describes: 0 out of 100
  Number of future calls: 0 out of 10

07:48:45.587|LIMIT_USAGE_FOR_NS|leadconvertchtr|
  Number of SOQL queries: 1 out of 100
  Number of query rows: 1 out of 50000
  Number of SOSL queries: 0 out of 20
  Number of DML statements: 0 out of 150
  Number of DML rows: 0 out of 10000
  Number of code statements: 15 out of 200000
  Maximum heap size: 0 out of 6000000
  Number of callouts: 0 out of 10
  Number of Email Invocations: 0 out of 10
  Number of fields describes: 0 out of 100
  Number of record type describes: 0 out of 100
  Number of child relationships describes: 0 out of 100
  Number of picklist describes: 0 out of 100
  Number of future calls: 0 out of 10

07:48:45.587|CUMULATIVE_LIMIT_USAGE_END

07:48:45.109 (1109545000)|CODE_UNIT_FINISHED|activitycall2 on Task trigger event AfterInsert for [00Tc0000004PzpF]
07:48:45.113 (1113733000)|CODE_UNIT_STARTED|[EXTERNAL]|Workflow:Task
07:48:45.123 (1123520000)|WF_RULE_EVAL_BEGIN|Assignment
07:48:45.123 (1123542000)|WF_RULE_EVAL_BEGIN|Response
07:48:45.123 (1123553000)|WF_RULE_EVAL_BEGIN|Workflow
07:48:45.123 (1123575000)|WF_CRITERIA_BEGIN|[Task:  00Tc0000004PzpF]|New Completed Call - Lead update|01QE0000000La9Q|ON_CREATE_OR_TRIGGERING_UPDATE
07:48:45.124 (1124489000)|WF_RULE_FILTER|[Task : Call Duration greater than 0]
07:48:45.124 (1124505000)|WF_RULE_EVAL_VALUE|
07:48:45.124 (1124511000)|WF_CRITERIA_END|false
07:48:45.124 (1124520000)|WF_CRITERIA_BEGIN|[Task:  00Tc0000004PzpF]|WF Update Task Comment|01QE0000000LbMG|ON_ALL_CHANGES
07:48:45.124 (1124727000)|WF_FORMULA|Formula:true|Values:
07:48:45.124 (1124736000)|WF_CRITERIA_END|true
07:48:45.125 (1125887000)|WF_CRITERIA_BEGIN|[Task:  00Tc0000004PzpF]|New Call|01QE0000000LaMe|ON_CREATE_OR_TRIGGERING_UPDATE
07:48:45.125 (1125927000)|WF_RULE_FILTER|[Task : Call Result not equal to null]
07:48:45.125 (1125940000)|WF_RULE_EVAL_VALUE|
07:48:45.125 (1125945000)|WF_CRITERIA_END|true
07:48:45.125 (1125965000)|WF_SPOOL_ACTION_BEGIN|Workflow
07:48:45.126 (1126336000)|WF_ACTION| Field Update: 1;
07:48:45.126 (1126355000)|WF_RULE_EVAL_BEGIN|Escalation
07:48:45.126 (1126362000)|WF_RULE_EVAL_END
07:48:45.126 (1126422000)|WF_ACTIONS_END| Field Update: 1;
07:48:45.126 (1126431000)|CODE_UNIT_FINISHED|Workflow:Task
07:48:45.128 (1128266000)|DML_END|[61]
07:48:45.128 (1128338000)|METHOD_ENTRY|[68]|01pc000000097l4|LeadUpdate.__sfdc_searchText(String)
07:48:45.128 (1128382000)|METHOD_EXIT|[68]|01pc000000097l4|LeadUpdate.__sfdc_searchText(String)
07:48:45.128 (1128396000)|METHOD_ENTRY|[69]|01pc000000097l4|LeadUpdate.__sfdc_searchResults()
07:48:45.128 (1128415000)|METHOD_EXIT|[69]|01pc000000097l4|LeadUpdate.__sfdc_searchResults()
07:48:45.128 (1128432000)|SYSTEM_METHOD_ENTRY|[69]|LIST<Lead>.clear()
07:48:45.128 (1128446000)|SYSTEM_METHOD_EXIT|[69]|LIST<Lead>.clear()
07:48:45.128 (1128461000)|SYSTEM_MODE_EXIT|false
07:48:45.273 (1273081000)|CODE_UNIT_FINISHED|LeadUpdate invoke(save)
07:48:45.274 (1274703000)|VF_APEX_CALL|j_id5|{!save}|PageReference: none
07:48:45.285 (1285446000)|CODE_UNIT_STARTED|[EXTERNAL]|01pc000000097l4|LeadUpdate get(searchResults)
07:48:45.285 (1285468000)|SYSTEM_MODE_ENTER|true
07:48:45.285 (1285479000)|CODE_UNIT_STARTED|[EXTERNAL]|01pc000000097l4|searchResults
07:48:45.285 (1285493000)|CODE_UNIT_FINISHED|searchResults
07:48:45.285 (1285501000)|CODE_UNIT_FINISHED|LeadUpdate get(searchResults)
07:48:45.294 (1294092000)|CODE_UNIT_STARTED|[EXTERNAL]|01pc000000097l4|LeadUpdate get(searchText)
07:48:45.294 (1294111000)|SYSTEM_MODE_ENTER|true
07:48:45.294 (1294122000)|CODE_UNIT_STARTED|[EXTERNAL]|01pc000000097l4|searchText
07:48:45.294 (1294139000)|CODE_UNIT_FINISHED|searchText
07:48:45.294 (1294148000)|CODE_UNIT_FINISHED|LeadUpdate get(searchText)
07:48:45.297 (1297475000)|VF_SERIALIZE_VIEWSTATE_BEGIN|066c00000008l5F
07:48:45.324 (1324316000)|VF_SERIALIZE_VIEWSTATE_END
07:48:45.328 (1328947000)|CODE_UNIT_STARTED|[EXTERNAL]|Generate Metadata
07:48:45.331 (1331312000)|CODE_UNIT_FINISHED|Generate Metadata
07:48:45.813 (1335984000)|CUMULATIVE_LIMIT_USAGE
07:48:45.813|LIMIT_USAGE_FOR_NS|(default)|
  Number of SOQL queries: 0 out of 100
  Number of query rows: 0 out of 50000
  Number of SOSL queries: 0 out of 20
  Number of DML statements: 2 out of 150
  Number of DML rows: 2 out of 10000
  Number of code statements: 27 out of 200000
  Maximum heap size: 0 out of 6000000
  Number of callouts: 0 out of 10
  Number of Email Invocations: 0 out of 10
  Number of fields describes: 0 out of 100
  Number of record type describes: 0 out of 100
  Number of child relationships describes: 0 out of 100
  Number of picklist describes: 0 out of 100
  Number of future calls: 0 out of 10

07:48:45.813|LIMIT_USAGE_FOR_NS|leadconvertchtr|
  Number of SOQL queries: 1 out of 100
  Number of query rows: 1 out of 50000
  Number of SOSL queries: 0 out of 20
  Number of DML statements: 0 out of 150
  Number of DML rows: 0 out of 10000
  Number of code statements: 15 out of 200000
  Maximum heap size: 0 out of 6000000
  Number of callouts: 0 out of 10
  Number of Email Invocations: 0 out of 10
  Number of fields describes: 0 out of 100
  Number of record type describes: 0 out of 100
  Number of child relationships describes: 0 out of 100
  Number of picklist describes: 0 out of 100
  Number of future calls: 0 out of 10

07:48:45.813|CUMULATIVE_LIMIT_USAGE_END

07:48:45.336 (1336040000)|CODE_UNIT_FINISHED|VF: /apex/leadform1
07:48:45.336 (1336053000)|EXECUTION_FINISHED

 

ManoharSFManoharSF

if you really want to use leads object then the options are let them create 2 leads with same values for the couple main fields then use internally duplicate merger

 

options 

 

https://appexchange.salesforce.com/listingDetail?listingId=a0N30000003IYLlEAO (free)

 

or 

https://appexchange.salesforce.com/listingDetail?listingId=a0N300000016cMzEAI (paid)

 

I dint go for these options though as I was able to convince my management to go with custom object.

 

__
Try to login as admin on the site and see if it will show the exception or error