Skip to main content
Answer

Cannot be cast to error on report designer form

  • November 19, 2024
  • 2 replies
  • 89 views

Forum|alt.badge.img

Hello - We have a custom AR Invoice form which includes some custom fields created using a customization project. I just added some additional custom fields to this project but with the no coding method and now the previous fields are showing up on the report with an error. At first view, it produces results fine but then when I refresh the errors appear. Is there something I need to change on the customization?

Here is the full error message:

[A]PX.Objects.AR.CCMBSMM_ARRegisterExt cannot be cast to [B]PX.Objects.AR.CCMBSMM_ARRegisterExt.

Type A originates from 'gvuedunh, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null' in the context 'LoadNeither' in a byte array.

Type B originates from 'titsnhbc, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null' in the context 'LoadNeither' in a byte array.

 

Best answer by DipakNilkanth

Hi ​@ashleyb,

Did you name your custom fields the same as standard fields? If so, please rename those fields with the prefix Usr to ensure they are easily categorized as custom fields and to avoid duplicate names.

Have you used this custom DAC in your report? Please verify the field declarations in the report and ensure that you are providing the correct field references.

Additionally, try resetting caches from the Apply Updates screen and restart IIS to clear any cached data that might be causing conflicts.
Hope, it helps!

2 replies

DipakNilkanth
Pro III
Forum|alt.badge.img+13
  • Pro III
  • Answer
  • November 19, 2024

Hi ​@ashleyb,

Did you name your custom fields the same as standard fields? If so, please rename those fields with the prefix Usr to ensure they are easily categorized as custom fields and to avoid duplicate names.

Have you used this custom DAC in your report? Please verify the field declarations in the report and ensure that you are providing the correct field references.

Additionally, try resetting caches from the Apply Updates screen and restart IIS to clear any cached data that might be causing conflicts.
Hope, it helps!


Forum|alt.badge.img
  • Author
  • Varsity II
  • November 21, 2024

Turns out I just needed to restart the application! Thank you for your help!