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 (Archive)
Unanswered

Getting error while loading PCF Control on Form in Dynamics 365 Sales

(0) ShareShare
ReportReport
Posted on by 110

Hi ,

I have developed custom PCF Control in Typescript . I have used some React JS code to open React-Modal as popup window in Control Button Click.

This custom PCF Control is running fine when i am running it locally i.e from Visual Studio code. But when i deployed PCF Control to my Dynamics 365 environment.

And tried to access control in CRM Form then getting below error show in screenshot.

4150.pastedimage1592823800123v1.png

i did some analysis and found that when i remove Modal tsx file from my PCF Control then this error is not coming .

So below is my piece of code i wrote it down to call my Modal component. Basically passing one parameter to Modal Component.

<MyModal inputABN = {this.state.inputValue}/>
And below is constructor of My Modal component. 
export class MyModal extends React.Component<ModalProps, any> {
  constructor (props: ModalProps) {
    super(props);
    this.state = {
      showModal: false , inputABN: props.inputABN
    };
............................
So can somebody help me to sort out this issue.
Thanks


Categories:
  • Dynamics 365 Sumit Thakran Profile Picture
    110 on at
    RE: Getting error while loading PCF Control on Form in Dynamics 365 Sales

    Sorry, i couldn't remember fix now as it was long time ago.

  • tayurskiy Profile Picture
    20 on at
    RE: Getting error while loading PCF Control on Form in Dynamics 365 Sales

    What was your solution for fixing it? I have a similar problem when control is loading successfully when I open record from main grid or Recent area. The control is giving me below error when I navigate to cached form from related records.

    Error occured during initialization of control: rsm_RSM.AddressAutocomplete;Message: Could not find/invoke RSM.AddressAutocomplete's constructor

  • Dynamics 365 Sumit Thakran Profile Picture
    110 on at
    RE: Getting error while loading PCF Control on Form in Dynamics 365 Sales

    Thanks for your input,

    I got it sorted out.

  • kojisaiki Profile Picture
    on at
    RE: Getting error while loading PCF Control on Form in Dynamics 365 Sales

    If you provide source code, I can try to build it.

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

Community Spotlight of the Month

Kudos to Mohamed Amine Mahmoudi!

Blog subscriptions now enabled!

Follow your favorite blogs

TechTalk: How Dataverse and Microsoft Fabric powers ...

Explore the latest advancements in data export and integration within ...

Leaderboard > 🔒Ι Microsoft Dynamics CRM (Archived)

Featured topics

Product updates

Dynamics 365 release plans