• Fiona Hunter
  • NEWBIE
  • 0 Points
  • Member since 2014


  • Chatter
    Feed
  • 0
    Best Answers
  • 2
    Likes Received
  • 0
    Likes Given
  • 5
    Questions
  • 10
    Replies
Hi
I have a VF Page that loads but any fields that have a forumula in them do not display the text on edit is there anyway to fix this so the values are shown?
Thanks
Fiona
Hi
We have a button on an opportunity that when we click it takes the user to a VF page however i am looking to revert page to teh standard page layout for thsi object can someone explain how and where i can do this please.

Thanks
Fiona
PS - Need it in simple terms no really that technical.
I am looking to find someone that can do some coding for me to rollup counts from Activities.  I.E
shows amount of times the activity shows as No Answer, Answering Machine etc and also updates the lead status aswell.  

Basic functions to allow me to remove some leads from list view after we have attempted them a few times.
 
I will start by saying I have no idea about Apex Code we have not long got salesforce and it was developed for our needs but as i come accross changes required I have found its within a large area of code so hoping someone can help me out.

Wondering if some kind soul can help me out as I am totally lost. I need to roll up information from a custom object to an opportunity. There are already fields that do this currently.

The structure we have is we create an opportunity but instead of adding multiple products it is multiple policies so we have a custom object called policy and dependant on a customers requirements there can be many policies for one opportnity so we currently have fields that calculate the gross premiums over all policies nad places this information onto the opportunity. I now need this to be done on another couple fields but this has been achieved through apex classes as there is not master detail relatonship between the objects.

Part of the Class which relates to what I am describing is below but where would I add additional fields to roll up the max days a policy is live ( there is already a field called days live)


//Roll up of Total Premium sold and average premium sold field
public static void onAfterDelete(List<Policy_Information__c> policyInfoList){
//unique opporutnity Object Ids
Set<Id> opportunityIdSet = new Set<Id>();
Set<Id> proposedProductIdSet = new Set<Id>();
Set<Id> proposalIdSet = new Set<Id>();
List<Proposal__c> proposalList= new List<Proposal__c>();
List<PreSales_Product__c> presalesProductList= new List<PreSales_Product__c>();
//hold list of Opporutnity Record to be update
List<Opportunity> opportunityListUpdatable = new List<Opportunity>();


for(Policy_Information__c policyObj : policyInfoList){
if(policyObj.Back_Office_Status__c=='On Risk'){
opportunityIdSet.add(policyObj.Opportunity__c);
}
}
Map<ID,Decimal> opportunityMap = new Map<ID,Decimal> ();
Map<ID,Decimal> opportunityMapCount = new Map<ID,Decimal> ();
for(AggregateResult q : [select Opportunity__c,sum(Premium__c),count(Id) exp1
from Policy_Information__c where Opportunity__c IN :opportunityIdSet group by Opportunity__c]){
OpportunityMap.put((Id)q.get('Opportunity__c'),(decimal)q.get('expr0'));
opportunityMapCount.put((Id)q.get('Opportunity__c'),(decimal)q.get('exp1'));

}


//Run the for loop on Opportunity using the non-duplicate set of Opportunities Ids
//Get the sum value from the map and create a list of Opportunities to update
for(Opportunity o : [Select Id, Total_Premiums_Sold_Policy__c,Total_Product_Sold_Policy__c,Number_of_Premiums_Sold_Policy__c from Opportunity where Id IN :opportunityIdSet]){
Decimal PremiumSum = OpportunityMap.get(o.Id);
Decimal PremiumCount= opportunityMapCount.get(o.Id);
o.Number_of_Premiums_Sold_Policy__c=PremiumCount;
o.Total_Premiums_Sold_Policy__c = PremiumSum;
o.Total_Product_Sold_Policy__c=PremiumCount;
opportunityListUpdatable.add(o);
}
try{
update opportunityListUpdatable;
}catch(Exception ex) { ex.getMessage(); }
}

}
 
We have recently deployed our salesforce org and require portal to be set up so we can give affiliates acccess to enter leads and view real time stats. 
We have recently deployed our salesforce org and require portal to be set up so we can give affiliates acccess to enter leads and view real time stats. 
Hi
I have a VF Page that loads but any fields that have a forumula in them do not display the text on edit is there anyway to fix this so the values are shown?
Thanks
Fiona
Hi
We have a button on an opportunity that when we click it takes the user to a VF page however i am looking to revert page to teh standard page layout for thsi object can someone explain how and where i can do this please.

Thanks
Fiona
PS - Need it in simple terms no really that technical.
I will start by saying I have no idea about Apex Code we have not long got salesforce and it was developed for our needs but as i come accross changes required I have found its within a large area of code so hoping someone can help me out.

Wondering if some kind soul can help me out as I am totally lost. I need to roll up information from a custom object to an opportunity. There are already fields that do this currently.

The structure we have is we create an opportunity but instead of adding multiple products it is multiple policies so we have a custom object called policy and dependant on a customers requirements there can be many policies for one opportnity so we currently have fields that calculate the gross premiums over all policies nad places this information onto the opportunity. I now need this to be done on another couple fields but this has been achieved through apex classes as there is not master detail relatonship between the objects.

Part of the Class which relates to what I am describing is below but where would I add additional fields to roll up the max days a policy is live ( there is already a field called days live)


//Roll up of Total Premium sold and average premium sold field
public static void onAfterDelete(List<Policy_Information__c> policyInfoList){
//unique opporutnity Object Ids
Set<Id> opportunityIdSet = new Set<Id>();
Set<Id> proposedProductIdSet = new Set<Id>();
Set<Id> proposalIdSet = new Set<Id>();
List<Proposal__c> proposalList= new List<Proposal__c>();
List<PreSales_Product__c> presalesProductList= new List<PreSales_Product__c>();
//hold list of Opporutnity Record to be update
List<Opportunity> opportunityListUpdatable = new List<Opportunity>();


for(Policy_Information__c policyObj : policyInfoList){
if(policyObj.Back_Office_Status__c=='On Risk'){
opportunityIdSet.add(policyObj.Opportunity__c);
}
}
Map<ID,Decimal> opportunityMap = new Map<ID,Decimal> ();
Map<ID,Decimal> opportunityMapCount = new Map<ID,Decimal> ();
for(AggregateResult q : [select Opportunity__c,sum(Premium__c),count(Id) exp1
from Policy_Information__c where Opportunity__c IN :opportunityIdSet group by Opportunity__c]){
OpportunityMap.put((Id)q.get('Opportunity__c'),(decimal)q.get('expr0'));
opportunityMapCount.put((Id)q.get('Opportunity__c'),(decimal)q.get('exp1'));

}


//Run the for loop on Opportunity using the non-duplicate set of Opportunities Ids
//Get the sum value from the map and create a list of Opportunities to update
for(Opportunity o : [Select Id, Total_Premiums_Sold_Policy__c,Total_Product_Sold_Policy__c,Number_of_Premiums_Sold_Policy__c from Opportunity where Id IN :opportunityIdSet]){
Decimal PremiumSum = OpportunityMap.get(o.Id);
Decimal PremiumCount= opportunityMapCount.get(o.Id);
o.Number_of_Premiums_Sold_Policy__c=PremiumCount;
o.Total_Premiums_Sold_Policy__c = PremiumSum;
o.Total_Product_Sold_Policy__c=PremiumCount;
opportunityListUpdatable.add(o);
}
try{
update opportunityListUpdatable;
}catch(Exception ex) { ex.getMessage(); }
}

}
 
We have recently deployed our salesforce org and require portal to be set up so we can give affiliates acccess to enter leads and view real time stats.