Community
Showing results for 
Search instead for 
Do you mean 
Reply

Opportunity Save button event

Tuned Listener
Posts: 6
Country: United States

Opportunity Save button event

Hi,

 

I just wanna know how to capture Opportunity detail Save button click.

 

Any help is greatly appreciated.

 

Thanks.

Employee
Posts: 1,163
Country: USA

Re: Opportunity Save button event

I'm not positive if it's the best way, but opporutnities have an updated event. Here I capture the current opportunity when the view changes to the opportunity detail view.

 

void ActApp_ViewLoaded(object sender, ViewEventArgs e)
{
            if (ActApp.CurrentViewName == "Act.UI.IOpportunityDetailView")
            {
                Opportunity o = ActApp.ApplicationState.CurrentOpportunity;
                o.Updated += new MutableEntity.UpdatedEventHandler(o_Updated);
            }
}

 

 void o_Updated()
{
        //Do stuff here
}

Matthew Wood
Act! SDK Support
Community Moderator
Tuned Listener
Posts: 16
Country: Australia

Re: Opportunity Save button event

Hi I am working on something similiar; I have very similiar code as above, it works if I make changes to opportunity names etc, but if I make changes to opportunity statuses, the method o_Updated() sometimes executed a couple times, randomly it does not even execute. Any help/suggestions would be appreciated. Thanks.