Your browser does not seem to support JavaScript. As a result, your viewing experience will be diminished, and you have been placed in read-only mode.
Please download a browser that supports JavaScript, or enable it if it's disabled (i.e. NoScript).
Hi, is there a way to use Python to check if there is a link in a User Data field or if it is empty? Thanks.
What do you mean with "use Python"? Are you writing a script, or a plugin, or something else?
You can simply access the user data parameter and see if it is None or not:
None
link = op[c4d.ID_USERDATA,1] if link is None: print("no link") else: print("some object linked")
Also: please post questions on the C4D API in CINEMA 4D DEVELOPMENT.
@Swinn is None did the trick. Thanks.