An Opportunity is a Salesforce Standard Object that represents a sale or pending deal.
2
votes
2answers
37 views
Get Opportunity's Account
Question
Why I can't access to opportunity account name on apex/vf ?
Backgound
I'm creating a opportunity VF page, extending the standarcontroller:
<apex:page standardController="Opportunity" ...
1
vote
3answers
51 views
Cloning Opportunities
I have a quick question that I hope you can help me with. I have built a trigger that seems to work theoretically. When we have a partner op go to a win, I need the op to be cloned with a new stage, ...
2
votes
1answer
26 views
How to convert leads without setting opportunity to closed won?
Whenever I convert Leads, and create an Opportunity on the go, all these Opportunities get the status Closed Won. I could not find where to change that, as it's obviously nonsense.
How to change ...
1
vote
1answer
18 views
How to create formula with choices list?
I want to create a priorization system within my opportunities. It should be a field showing the output of amount * probability * boost-factor. Boost factor is supposed to be a gut feeling about the ...
1
vote
2answers
44 views
Using Apex Managed Sharing to share an opportunity
Here's the use case. When a lead is converted to an Opportunity, I want to automatically share the opportunity with the previous owner of the lead. This is needed because upon conversion, the ...
2
votes
2answers
40 views
After Delete - Need To “Cleanup” When An Opp Is Deleted
I have a hole in the logic of a huge Trigger that "piggybacks" data from Opportunities to Account (summarized). If someone touches an Opp, this trigger fires and checks ALL OPPS under that Account ...
2
votes
3answers
162 views
Make Validation Rule bypass if TRIGGER is run?
Is there a way to make a Validation Rule BYPASS via it's logic when a Trigger is doing it's job?
I've already tried various methods including
setting a hidden field on the object in the Trigger ...
4
votes
5answers
118 views
Run Trigger As A Specific User (or Profile)?
Is this possible? I'm not finding help, Google or otherwise, for this.
Situation:
A trigger runs and cycles through groups of Opportunities. Some of these Opportunities are Closed Won, and most ...
2
votes
1answer
41 views
Cyclic Trigger Calls
I am trying to stop a cyclic situation between two triggers. Trigger B is the primary - it runs when an Opp is edited (to put some data on the ACCOUNT). Trigger A was written so that if the Account ...
2
votes
2answers
41 views
Call an Opportunity Trigger from an Account Trigger (looping through all Opps)
This seems like a "relatively simple" venture to me, but at my experience level, I'm highly challenged to get it done. I've touched on a variation of it before.
I have a lengthy Trigger (appx 500 ...
0
votes
2answers
95 views
Trigger on updating account field based on opp field
I have written this trigger up update an field on the account if the field on any opportunity related to the account is checked. At first I had the check box being updated by a workflow but I thought ...
0
votes
1answer
51 views
Opportunity Updates related Service contract Trigger
I have a custom button that creates a "Renewal" record type opportunity from a Service Contract. I would like to display the opportunity stage on the related service contract ("Expired service ...
1
vote
1answer
57 views
Cases related list on Opportunity not displaying some case records
We have a custom lookup on Case object to the Opportunity object. On this field, the related list label is named 'Cases'. We added the related list Cases to the Opportunity page layout.
The user ...
3
votes
1answer
49 views
Related List on OpportunityLineItem
I'm looking at something using QuoteLineItems and OpportunityLineItems. The quoting/selling application is only interested in seeing high level "summary" products; however, there is a need to be able ...
3
votes
1answer
165 views
Odd error when inserting Chatter post from Opportunity trigger
I have a trigger on my Opportunity object that executes after insert and simply posts a new FeedItem to a specific group within my instance when the Opportunity record Stage is set to "Signed". Here ...
2
votes
2answers
151 views
Populate lookup field on Object after Clicking a custom button and creating record on different object
I would like to create a custom button on service contract to create an opportunity. I want to populate a lookup field between service contract and opportunity (So I will be able to use it for some ...
1
vote
1answer
29 views
How to Change the Opportunity Amount
Once I add Products to the Opportunity I can no longer edit the Opportunity's Amount field. Is it possible to change that amount so that it is saved on the Opportunity as a different amount? Possibly ...
3
votes
2answers
79 views
Upload and attach a file to an account or opportunity
So I was wondering how I can attach a file to an account. Basically what we do is sell a product online that requires an agreement. When they buy the product, we generate a pdf of the agreement and ...
4
votes
1answer
155 views
REQUIRED_FIELD_MISSING, Required fields are missing: [Name]: [Name]
when i trying to insert opportunity in my testclass i am getting an error
Test_opportunityTrigger.Test_opportunityTrigger: line 24, column 1
22:28:17.312 ...
2
votes
2answers
57 views
Task deletes with Opportunity with Opp deleted? (Parent/Grandparent relationship?)
I'd appreciate it if someone "in the know" could verify this and let me know if there is a way to RECTIFY this.
A lead is created. A task is linked to that Lead.
The lead is converted to an ...
0
votes
1answer
52 views
Relation between lead, Account, oppurtunity and contact
Please explain me the relation between these 4 sobjects. How lead, Account, Opportunity and Contact are related to each other.
1
vote
1answer
56 views
How to enter opportunities in NPSP's opportunity tab?
I am using the Non-Profit-Starter-Pack (NPSP) with the 1-to-1 model.
I want to create an opportunity from the opportunity tab. I tried to insert a field for contact here, but cannot find it when ...
0
votes
1answer
35 views
Write to Parent record without declaring it in an Apex Trigger?
In the following example, where it says "xxxxxx", is it possible to write to a field on ACCOUNT (parent) within this code, somehow referencing it from the Opportunity that is currently being touched? ...
2
votes
1answer
128 views
Account Merge - Opportunity is not updated / touched?
Could someone who knows better verify:
I just tested and it seems to me that if I merge -
Account 1 with 2 opps (destination)
Account 2 with 3 opps
...that the resultant Account 1 with all ...
0
votes
1answer
149 views
Copy Opportunity Products to Contract Line Items
I have created a flow does several actions:
create a new Service contract with user input (start date, end date, name)
create a new license key to send to end user
change the opportunity to closed ...
5
votes
2answers
135 views
Required fields are missing:
I am writing a test class. When i run my test class i am getting an error
System.DmlException: Insert failed. First exception on row 0; first error: REQUIRED_FIELD_MISSING, Required fields are ...
3
votes
1answer
59 views
How to Ensure Some Users Always Add Products when Creating Opportunities
We've got several departments using Salesforce and while we'd like everyone to use products with opportunities we can't currently do this across the board. However, for the departments that do use ...
2
votes
3answers
73 views
Setting SystemModstamp for OpportunityHistory
I have some logic where I have to send emails about Opportunities that have certain OpportunityHistory objects at certain date times.
I would like to test this but it means I need to be able to ...
0
votes
1answer
117 views
Trigger on OpportunityTeamMember has an error
Since there is no out of the box solution to send email notifications to users when they are added/removed from an Opportunity team, I wrote a trigger. So far I have code to handle the addition. This ...
1
vote
1answer
240 views
Opportunity Team email notification - Is Trigger the only way?
I have another situation that I need to write a trigger for and I am wondering if there is an out of the box solution I can use.
Basically when a team member is added or deleted from an Opportunity ...
1
vote
3answers
178 views
How to get the opportunity owner name instead of owner ID
I am posting to chatter using an apex trigger whenever the opportunity stage changes to a certain value. The problem I'm having is that I'm trying to concatenate the opportunity owner name with some ...
1
vote
2answers
157 views
Count Custom Button Clicks
I've added a custom button to the opportunity layout. I would like to count the number of times this button was clicked.
!REQUIRESCRIPT("/soap/ajax/26.0/connection.js")} //adds the proper code ...
0
votes
0answers
61 views
Expose SF data in Wordpress
I'm using wordpress as a partner portal. Portal users are created independently from Salesforce, but they are also exist in SF as contacts (so when they are created in Wordpress manually, I can add ...
2
votes
2answers
393 views
Trigger to create task/email when Opportunity is updated with a certain stage
I am trying to create a trigger (possibly After Update) such that it is fired when an Opportunity is updated with a certain stage. It should create a task and send an email to a user. The email should ...
1
vote
3answers
209 views
Single Object Approval Processes run separately
I want to have a number of different approval processes run off Opportunities for things like discount approval, credit check and a compliance check. Is there a way I can set these up as separate ...
2
votes
3answers
83 views
Updating a GROUP of accounts in lieu of ONE account (“update”)
I do not wish to paste the HUGE trigger this is related to (several hundred lines). However, a long time ago when it was first written, I believe it was MEANT to update "all accounts affected" with ...
1
vote
2answers
163 views
Does a user need to be the Account Owner to add Opportunity Team Members
I am trying to use standard Opportunity Team Member functionality and it doesn't seem to match the documentation.
I have the following sharing model
account: public read/write
opportunity: private
...
1
vote
1answer
203 views
Change Opportunity Currency after adding a Opp Line Item
We have enabled multiple currency in our org, and allow the user to set the currency on the Opportunity record. The user is able to change the value of the Currency field on the Opportunity object if ...
5
votes
4answers
1k views
Is it possible to remove/hide the “New” button?
When you click on the Opportunities tab, (assuming you haven't modified standard salesforce layout), you see a "Recent Opportunities" list. At the top of the list, there is a "New" button.
Is ...
3
votes
4answers
153 views
How can I identify whether an Opportunity is a renewal?
My sales team would like a clear flag on Opportunity records indicating whether the Opp is a renewal or a new opportunity. The information should be displayed on the Opp record, and also available ...
3
votes
1answer
177 views
How do you change an Opportunity's Record Type in the web UI?
Originally our org only had one record type for opportunities but we've since added a second. I want to manually change a few opportunities to this new type. However, the Opportunity Record Type field ...



