Hi,
I noticed in our recent FM upgrade that the method gridRowCount() was removed in FM 2.3.
Is there any replacement method to retrieve the row count?
Thank you.
Hello,
Thank you for reaching out to us.
The gridRowCount
method is still supported for backward compatibility. Kindly note that it is not recommended because the method can be removed in future releases.
You are welcome to contact us in case further questions arise.
Kind regards,
Nadia
I got this message while trying to call the method. How do we make a method call through backward compatibility? How do we enable backward compatibility?
Hello,
Thank you for the response.
You can use the bracket notation to access the deprecated methods and explicitly specify the <any>
type for the pivot.
Please, try the following code:
console.log('flexmonster.gridRowCount()', (<any>this.pivot.flexmonster)['gridRowCount']());
Please let us know if it works for you. Looking forward to your response.
Kind regards,
Nadia
I was not able to use the snippet above,
Is there a JSFiddle you can provide?
Thanks
I changed it to
console.log('flexmonster.gridRowCount()', (this.flexmonster as any)['gridRowCount']());
since we're running on Typescript
and was able to run however, the method still doesn't exist
Hello,
Thank you for your feedback.
The error from your screenshot indicates that this.flexmonster
is null. We recommend checking that the Flexmonster object you access to run gridRowCount
method is not null.
Please let us know if our recommendation helped you to solve the issue.
Best Regards,
Maksym
Hi Maskym,
That's working now, thank you. Ticket can be closed.
Thien D.
Hi, Thien!
Thank you for the reply.
We are glad to hear that everything works fine for you.
Feel free to contact us if more questions arise.
Best Regards,
Maksym