Inside Sabertooth
Learn how Sabertooth uses 3ds Max to create 3D interactive projects, including HBO Go’s Game of Thrones interactive experience
  • 1/3
You are here: Forum Home / Autodesk® Softimage® / XSI SDK / Deleting a CustomProperty from c# causes problems.
  RSS 2.0 ATOM  

Deleting a CustomProperty from c# causes problems.
Rate this thread
 
30186
 
Permlink of this thread  
avatar
  • Location: Copenhagen
  • Total Posts: 50
  • Joined: 22 February 2008 02:47 AM

Hi there

I need to be able to have a customProperty delete itself in c#. I can make this rather suicidal stunt work in jScript as I guess jScript is very forgiving, but XSI crashes if I try the same thing in c#.

The crash is ofcourse because the thread is still running when the property is deleted from the scene.

Is there anyone who have a suggestion on how to do this (other than just keep the code in jscript).

Cheers
Jacob



Replies: 0
avatar
  • mslaf
  • Posted: 10 April 2009 08:01 AM

[quote=RedBjarne;21341]Hi there

I need to be able to have a customProperty delete itself in c#. I can make this rather suicidal stunt work in jScript as I guess jScript is very forgiving, but XSI crashes if I try the same thing in c#.

The crash is ofcourse because the thread is still running when the property is deleted from the scene.

Is there anyone who have a suggestion on how to do this (other than just keep the code in jscript).

Cheers
Jacob

You’ve got two choices:

- use CreateObject method to create ‘temporary’ CP that will be destroyed when it’s closed.
- use the custom command or menu callback to create and delete CP from there.



Replies: 0