• babacandoit
  • NEWBIE
  • 50 Points
  • Member since 2014
  • SalesForce - Developer(Fresher)
  • Extentor Tquila

  • Chatter
    Feed
  • 0
    Best Answers
  • 0
    Likes Received
  • 1
    Likes Given
  • 10
    Questions
  • 9
    Replies
Hi All,

I am want to explore 'Person Account', But I am not able to raise a case to Enable Person Account.

How can Enable Person Account for my Dev Org?

Cheers
Ryan
Hi All,

I am trying to save my records, but they are not getting saved :( Tried a lot..
Lost Hope..Please Help me.. 
When ever I click save. Defalt vales are getting saved. NOT the form vales :(

Please some one Help ME..


<!-- VF PAGE -->
<apex:page showHeader="false" applyBodyTag="false" applyHtmlTag="false"
      sidebar="false" docType="html-5.0" standardStylesheets="false"
     controller="setTargetControllerV3">

<body>   
      <apex:form >
        <div class="col-xs-12" style="padding-top:25px;">
            <div class="list-group">
                <div class="list-group-item" style=" Background-color:rgba(0, 138, 255, 0.8);"  >
                    <font color="white" ><center><h3>Set  Targets  For  Sales  Persons</h3></center></font>
                </div>
               
                <div class="list-group-item" style="padding-top: 50px;">
                  
                    <div class="col-sm-2" id="selectYear">
                        <div style="float:left;padding-right: 5px;line-height: 2.5;">
                          <label class="control-label"><b>Select Year</b></label>  </div>
                           
                             <apex:variable var="year" value="{!YEAR(TODAY())}"/>
                                 <div style="float:right">
                                  <select name="year" id="year" class="form-control" >
                                      <option value="{!year}">{!year}</option>
                                      <option value="{!year+1}">{!year+1}</option>
                                      <option value="{!year+2}">{!year+2}</option>
                                  </select>
                                  </div> 
                             </div>
                
                       <center>    
                        <apex:commandButton value="New" action="{!addUser}" styleClass="btn btn-info" rendered="{!renNew}"/>
                        &nbsp;  &nbsp; &nbsp;  &nbsp;                    
                        <apex:commandButton value="Save" action="{!saveUser}" styleClass="btn   btn-success" id="save" rendered="{!renSave}"/>
                        &nbsp;  &nbsp; &nbsp;  &nbsp;                    
                        <apex:commandButton value="Cancel" action="{!cancel}" styleClass="btn   btn-danger" id="cancel" rendered="{!renSave}"/>
                    </center>
                </div>
               
                 <apex:pageBlock id="frm" rendered="{!renSave}">
                    <div class="list-group-item" id="newOrg" style="padding-top:50px">

                        <table class="tg" style="width:100%">
                                      <tr>
                                        <th class="tg-e3zv">SalesPerson</th>
                                        <th class="tg-031e">Year</th>
                                        <th class="tg-e3zv">Target<br/> amount</th>
                                        <th class="tg-e3zv">Same For Months</th>
                                        <th class="tg-e3zv">Jan</th>
                                        <th class="tg-e3zv">Feb</th>
                                        <th class="tg-e3zv">Mar</th>
                                        <th class="tg-e3zv">Apr</th>
                                        <th class="tg-e3zv">May</th>
                                        <th class="tg-e3zv">Jun</th>
                                        <th class="tg-e3zv">Jul</th>
                                        <th class="tg-e3zv">Aug</th>
                                        <th class="tg-e3zv">Sept</th>
                                        <th class="tg-e3zv">Oct</th>
                                        <th class="tg-e3zv">Nov</th>
                                        <th class="tg-e3zv">Dec</th>
                                      </tr>
                                     <apex:variable value="{!0}" var="countRow"/>
                                     <apex:repeat value="{!targetList}" var="tar" >
                                          <apex:variable var="countRow" value="{!countRow+1}"/>
                                      <tr id="ret">
                                        <td class="tg-031e" style=" width:75px;">
                                          
                                              <select name="users" id="{!countRow}" class="form-control" onClick="copyYear(this.id)">
                                                    <option>-None-</option>
                                                    <apex:repeat value="{!userspList}" var="sp">
                                                          <option value="{!target.Sales_Person__c}">{!sp.name}</option>
                                                    </apex:repeat>  
                                               </select>
                                        </td>

                                        <td class="tg-vn4c"><input value="{!tar.Year__c}" id="yr-{!countRow}" style=" width: 75px; height:30px"/> </td>
                                      
                                        <td class="tg-e3zv"><input id="amt-{!countRow}" style=" width: 75px; height:30px"/></td>
                                       
                                        <td class="tg-vn4c">
                                       
                                        <input type="checkbox" name="check1" onchange="copyTextValue(this,this.id)" id="{!countRow}"/>
                                       </td>
                                      
                                        <td class="tg-031e"><input id="p1-{!countRow}" value="{!tar.Jan_Target__c}" style=" width: 75px; height:30px"/></td>
                                        <td class="tg-vn4c"><input value="{!tar.Feb_Target__c}" style=" width: 75px; height:30px" id="p2-{!countRow}"/></td>
                                        <td class="tg-031e"><input value="{!tar.Mar_Target__c}" style=" width: 75px; height:30px" id="p3-{!countRow}"/></td>
                                        <td class="tg-vn4c"><input value="{!tar.Apr_Target__c}" style=" width: 75px; height:30px" id="p4-{!countRow}"/></td>
                                        <td class="tg-031e"><input value="{!tar.May_Target__c}" style=" width: 75px; height:30px" id="p5-{!countRow}"/></td>
                                        <td class="tg-vn4c"><input value="{!tar.Jun_Target__c}" style=" width: 75px; height:30px" id="p6-{!countRow}"/></td>
                                        <td class="tg-031e"><input value="{!tar.Jul_Target__c}" style=" width: 75px; height:30px" id="p7-{!countRow}"/></td>
                                        <td class="tg-vn4c"><input value="{!tar.Aug_Target__c}" style=" width: 75px; height:30px" id="p8-{!countRow}"/></td>
                                        <td class="tg-031e"><input value="{!tar.Sept_Target__c}" style=" width: 75px; height:30px" id="p9-{!countRow}"/></td>
                                        <td class="tg-vn4c"><input value="{!tar.Oct_Target__c}" style=" width: 75px; height:30px" id="p10-{!countRow}"/></td>
                                        <td class="tg-031e"><input value="{!tar.Nov_Target__c}" style=" width: 75px; height:30px" id="p11-{!countRow}"/></td>
                                        <td class="tg-vn4c"><input value="{!tar.Dec_Target__c}" style=" width: 75px; height:30px" id="p12-{!countRow}"/></td>
                                      </tr>
                                      </apex:repeat>
                            </table>
                    </div>
                </apex:pageBlock>
          
             </div>  
            </div>
          </apex:form>

   <!-- Java script starts Here -->
   <script type="text/javascript">
   function copyYear(count){
  
                var actYear = document.getElementById("year").value;
                document.getElementById("yr-"+count).value = actYear;
   }
  
 
</body>                
</apex:page>

<!--VF ENDS-->


/***********Controller**********/
public with sharing class setTargetControllerV3 {


    public List<Target__c> targetList {get;set;}
    public Target__c target {get;set;}
    public List<User> userspList {get;set;}
    public Boolean renNew { get; set; }
    public boolean renSave { get; set; }

   
    public setTargetControllerV3(){
            targetList = new List<Target__c>();
            renNew=true;
            userspList = [Select  u.Name, u.Id From User u where title='SalesPerson'];       
    }
   
    public void addUser() {
      targetList.add(new Target__c());
      renSave =true;
       //System.debug('targetList==>'+targetList[0]);
    }

     public PageReference cancel() {
        return null;
    }

    public PageReference saveUser() {
  
        insert targetList;
        renSave =false;
        return null;
    }
 
}

Cheers
Baba
Thanks in Don

Hi All,

    I have a requriment,  once the account is Created, the owner of account must changed to the Groupe.
Criteria is based on stated the state of account, Groupe should be assigned.(North, South, East, West) Groupe.

Please, Help me.. How to do ? Is it possible with Configration ? Or I have to go to Workflow or Trigger ?

Thanks in Advance :)
Cheer,
Baba
Hi All,

I am creating a custom Formula-Text-field 'Level of Disount'.
depending on Disount-Range, Level of Disount must be changed,

Here goes the My Formula,

//--->Formula starts here
IF((Discount_Percentage__c >=5 || Discount_Percentage__c<=10) , 'Level-1',
IF((Discount_Percentage__c >=10 || Discount_Percentage__c<=20), 'Level-2',
IF((Discount_Percentage__c >=20 || Discount_Percentage__c<=30), 'Level-3',
IF((Discount_Percentage__c >=30 || Discount_Percentage__c<=40), 'Level-4',
'No Disount'))))
//---Formula End here <---

For all the Discount_Percentage__c it is showing Only Level-1 :(

Thanks in Advance. 

Cheers
Baba
 
Hi All,

  I want create a Time-Dependent Workflow action, for updating the Product's Custom field 'Status' .
if Product-Stauts = 'New' then after 90days the status field must be updated to Old.

what will be the Rule-Criteria and Criteria-Evalution ?

Thanks  in Advance.
Cheers
Baba
Hi All,

I am getting error as  "Error Error: Compile Error: Variable does not exist: hander at line 16 column 9"
for below lines of code ? 

Please some one can help me..

trigger assignSp on Account (before insert, before update, After insert, After Update) {

    AssignSpHandler handler = AssignSpHandler.getInstance();
   
    if(Trigger.isBefore && (Trigger.isInsert ||Trigger.isUpdate)){
        handler.assignSp(Trigger.new);
    }
   
    if(Trigger.isAfter && (Trigger.isInsert ||Trigger.isUpdate)){
        hander.changeContactOwner(Trigger.new, Trigger.oldMap);
   
    }
}

-----
Thanks in advance
Cheers..
Baba
Hi, 

I am trying to creat Master-Deatail Realtionship between the Account and the Order Object.
But when i clicked New Filed in ORDER object, there is no Master-detail Relationship DataType Option :(

Why ? it is not showing ?

Hi All,

  I'm trying to creat a Roll-Up Summary Field as TotalOrderedAmount and NumberOfOrders  in Account object.
But I'm not getting the order  in the Summarized-Object(PickList showing only Oppurtunity) in step3 of the Rollup sammary field creation.

Is Account & Order  has Master - Detail Relationship ? 

Please Help,
Baby-Bud-of SFDC

Thanks- in Advance
Hi, I am working on Order & OrderItem,
I have a custom Field Disount , depending on discount Im updating the unitPrice.
(For example, if dicount is 5%, then unit prise will change from 40 to 38).
My Requriment is to display both the values of the UnitPrice(40 & 38 in my case) .
ie, UnitPrice before updating and UnitPrice after updating.

Hi,

I'm new to salesforce, started coding 2 week back, I am confused whether to go for 'Bootstrap' or Zurb ?? why ?
Hi All,

I am creating a custom Formula-Text-field 'Level of Disount'.
depending on Disount-Range, Level of Disount must be changed,

Here goes the My Formula,

//--->Formula starts here
IF((Discount_Percentage__c >=5 || Discount_Percentage__c<=10) , 'Level-1',
IF((Discount_Percentage__c >=10 || Discount_Percentage__c<=20), 'Level-2',
IF((Discount_Percentage__c >=20 || Discount_Percentage__c<=30), 'Level-3',
IF((Discount_Percentage__c >=30 || Discount_Percentage__c<=40), 'Level-4',
'No Disount'))))
//---Formula End here <---

For all the Discount_Percentage__c it is showing Only Level-1 :(

Thanks in Advance. 

Cheers
Baba
 
Hi All,

  I want create a Time-Dependent Workflow action, for updating the Product's Custom field 'Status' .
if Product-Stauts = 'New' then after 90days the status field must be updated to Old.

what will be the Rule-Criteria and Criteria-Evalution ?

Thanks  in Advance.
Cheers
Baba
Hi All,

I am getting error as  "Error Error: Compile Error: Variable does not exist: hander at line 16 column 9"
for below lines of code ? 

Please some one can help me..

trigger assignSp on Account (before insert, before update, After insert, After Update) {

    AssignSpHandler handler = AssignSpHandler.getInstance();
   
    if(Trigger.isBefore && (Trigger.isInsert ||Trigger.isUpdate)){
        handler.assignSp(Trigger.new);
    }
   
    if(Trigger.isAfter && (Trigger.isInsert ||Trigger.isUpdate)){
        hander.changeContactOwner(Trigger.new, Trigger.oldMap);
   
    }
}

-----
Thanks in advance
Cheers..
Baba
Hi, 

I am trying to creat Master-Deatail Realtionship between the Account and the Order Object.
But when i clicked New Filed in ORDER object, there is no Master-detail Relationship DataType Option :(

Why ? it is not showing ?

Hi All,

  I'm trying to creat a Roll-Up Summary Field as TotalOrderedAmount and NumberOfOrders  in Account object.
But I'm not getting the order  in the Summarized-Object(PickList showing only Oppurtunity) in step3 of the Rollup sammary field creation.

Is Account & Order  has Master - Detail Relationship ? 

Please Help,
Baby-Bud-of SFDC

Thanks- in Advance
Hi, I am working on Order & OrderItem,
I have a custom Field Disount , depending on discount Im updating the unitPrice.
(For example, if dicount is 5%, then unit prise will change from 40 to 38).
My Requriment is to display both the values of the UnitPrice(40 & 38 in my case) .
ie, UnitPrice before updating and UnitPrice after updating.

Hi,

I'm new to salesforce, started coding 2 week back, I am confused whether to go for 'Bootstrap' or Zurb ?? why ?
Hi All,

I am new in salesforce. can anyone please tell in what all ways migration can be done from sandbox to production and exlain.