[MaxPlus] Delete all Keys flag issue

Hey Guys, I try to write a script that deletes all keys in maxplus. I know the function deleteKeys of the animatable class. in the API stands: “DeleteKeys(Animatable self, DWORD flags)” but iI have no idea how to find out what kind of flag i should use. Has anyone tips on how to use the api and find out which arguments you should give?

The flags are specified in the SDK documentation ( the c++ one ) Take note that they do not appear to be keyword arguments. I had the same issue with addNewKey and adding a boolean value ( I guess it affects the first flag or all of them at once? ) made it work.

time = MaxPlus.Core.GetCurrentTime()
transform = scene.getSelectedNodes()[0].GetSubAnim( 2 )
transform.AddNewKey( time, True )
MaxPlus.ViewportManager.RedrawViewportsNow( time )

Otherwise, deleting each key in a loop should work:

for t in transform.KeyTimes:
transform.DeleteKeyAtTime( t )