Error while changing the Import Load (FRF) - Interpolation Type using mechanical scripting.

Naveen Kumar Begari
Naveen Kumar Begari Member Posts: 102
10 Comments 5 Likes First Answer First Anniversary
**

FRF - Fluids Results File.

I have few scripts as below, but getting an error in PyMechanical - Embedded instance. But works well in Mechanical Standalone.

  1. Imported_Load.PropertyByName("SourceLoad").InternalValue = 2
  2. Imported_Load.Properties[1].InternalValue = 2

Any suggestions on below error.

Comments

  • James Derrick
    James Derrick Administrator, Employee Posts: 357
    Ancient Membership 100 Comments 100 Likes 25 Answers
    admin

    it says it's a type mismatch, could this just be that it's expecting a float and you're providing an integer but in the standalone application it automatically makes the conversion?

  • Naveen Kumar Begari
    Naveen Kumar Begari Member Posts: 102
    10 Comments 5 Likes First Answer First Anniversary
    **

    Hello @James Derrick
    No, Standalone is not automatically converting.

    obj.GetType() ----> Int

    FYR:

  • James Derrick
    James Derrick Administrator, Employee Posts: 357
    Ancient Membership 100 Comments 100 Likes 25 Answers
    admin

    What about Properties[46]? That's where the problem is right?

  • Naveen Kumar Begari
    Naveen Kumar Begari Member Posts: 102
    10 Comments 5 Likes First Answer First Anniversary
    **

    Same as above. Not yet fixed.

    Yes. Problem at that point.

    If we fix one, remaining we can replicate it @James Derrick