web
You’re offline. This is a read only version of the page.
close
Skip to main content

Notifications

Announcements

No record found.

Community site session details

Community site session details

Session Id :
Microsoft Dynamics CRM (Archived)

Does anyone have better solution for language based JavaScript code?

(0) ShareShare
ReportReport
Posted on by 4,102

Hi,

I have a JavaScript function on Case form in which I am fetching BPF's active stage using XRM object. Below is skeleton of my code:

var activeStage = getActiveStage(); //Identify

if (activeStage === "Identify")

{

//perform some operations

}

It is working fine for English language, but when I change the language to another language, the condition fails.

Any solution ?

In worst case, I will have to create an array and based on language id I will pass the value.

Thanks in advance.

*This post is locked for comments

I have the same question (0)
  • Verified answer
    Siraj M Profile Picture
    on at

    modify your getActiveStage function to return stage id.

    instead of checking with stage name, try checking with stage id

    Regards,

    Siraj

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Responsible AI policies

As AI tools become more common, we’re introducing a Responsible AI Use…

Neeraj Kumar – Community Spotlight

We are honored to recognize Neeraj Kumar as our Community Spotlight honoree for…

Leaderboard > 🔒一 Microsoft Dynamics CRM (Archived)

#1
SA-08121319-0 Profile Picture

SA-08121319-0 4

#1
Calum MacFarlane Profile Picture

Calum MacFarlane 4

#3
Alex Fun Wei Jie Profile Picture

Alex Fun Wei Jie 2

Last 30 days Overall leaderboard

Featured topics

Product updates

Dynamics 365 release plans