• Rajat Singh 46
  • NEWBIE
  • 0 Points
  • Member since 2022

  • Chatter
    Feed
  • 0
    Best Answers
  • 0
    Likes Received
  • 0
    Likes Given
  • 0
    Questions
  • 3
    Replies
Hi, I am using Standard Lead layout and i have a requirement to call a Sync service and based on response of that service, allow or Stop the Lead to Save . The Problem is, i cannot call the sync service from Before insert trigger. What are my options ? if I create a lightning component and override Standard Save button, can i just add my additional logic and reuse rest of the standard save functionality ?  Or shall i user a lightning component to Call the Sync service but then how do i stop the Save if required based on the response of the service.

Please help urgently.

Thanks
Hi there!

I've been asked to restrict the valid Close Dates for Opporunities to the last day of the month when the Stage is not Closed Won/Lost.

I've found a fromula that does a great job restricting the dates in general, but I can't figure out how to add the additional condition that it should only apply the date limitation when the Opportunity is in certain stages.

IF( 
    MONTH( CloseDate ) = 12,
    DATE( YEAR( CloseDate ) + 1, 1, 1 ),
    DATE( YEAR( CloseDate ), MONTH( CloseDate ) + 1, 1 )
  ) - 1 
)

Any help/insight would be greatly appreciated!