Notifications
Clear all

[Closed] How do I prevent this undo-based Max crash?

there should be a workaround. but we have just few information to help you find it.

If I can stop a node from being actually deleted at the time when I “delete” it, I should be able to get it working in the post delete callback using the method we discussed before. You’re saying there is a way to do it, so… what is it?

IMHO max should never crash on a script action. The script should only raise a error.

So IMHO: create a bug report and send CER with the case id…

IMHO max should never crash on a script action. The script should only raise a error.

So I’m curious when you think Max SHOULD crash? lol

I haven’t had a chance to muck about with finding a workaround, I’m swamped with client work for the next few weeks at least…

max should never crash on a script action!

and what is more… MAX SHOULD NEVER CRASH!

I know this is a really CRAZY idea, but bear with me for just a minute.

I think that NO program should ever crash!
Heresy? Madness? Or am I just maybe onto something? You decide!

1 Reply
(@denist)
Joined: 11 months ago

Posts: 0

“The Pink Pony’s Lea” shouldn’t crash

The what now?

Anyway, a day of web coding (which I’d been away from for some time) has left my brain in a sort of pudding-like semi-solid state. That and being generally busy, I’m not going to have time to try and figure this out on my own any time soon.

I could swear that at one point I did actually have something which could prevent nodes from being deleted but I can no longer find it.

i cannot show the code how to make a node undeletable. because it’s a part of some my tools which makes them unique.

but i can tell a theory behind.
#1 it’s not possible to do with pure MXS or MaxSharp (and MCG :))
#2 it’s only c++ SDK solution

now the theory:
using predelete callback set a node which is about to be deleted to state that it’s already deleted. the system does not delete ‘deleted’ node. but the system still fires postdelete event. so using this event set the node back to normal state.

Ah ok. Well, since I have no experience with the SDK and extremely minimal knowledge of c++, I guess it is out of my reach for now. In that case I have to find some other way to achieve the effect I need.

Instead of making the node undeletable, is there any other way I can get past the Max bug? A working way to flag the deleted objects to prevent the script from trying to delete them again?

1 Reply
(@denist)
Joined: 11 months ago

Posts: 0

try to explain your scenario… i don’t really get why you need undeletable nodes. and why you want to have ‘create nodes’ undoable but ‘delete nodes’ not undoable.

 JHN

Have you seen this mxs extension by Kees Rijnen and now maintained by maxplugins, if I’m correct : http://www.maxplugins.de/r2015_files/kees/DeleteProtection_MXS_2015.zip

1 Reply
(@denist)
Joined: 11 months ago

Posts: 0

it only suspends delete button… you still can delete objects with UI or mxs code.
it doesn’t really make a node undeletable

Page 2 / 5