.dll question about acquiring an object from managed code

I'm trying to call a .dll function from managed code but the application has it's own plugin entry point that takes in a structured object (message) that's passed from the application (It contains a suite to the application, to use as a pointer to functions).

I need to access that assigned (message) as it's a object that I need to use to use some of the application features 'Opening a file' The problem is I cannot get this (message) without passing it from the entry point. I don't have access to the source just an SDK.

Is there a solution to my problem?

Photoshop Plugin explanation:

The Photoshop plug-in manager communicates with your plug-in by loading
the plug-in code into memory if necessary, then calling its entry point. By
convention, the entry point is called "PluginMain":

DllExport SPAPI SPErr PluginMain( char *caller, char *selector, void
*data )

Three arguments are passed to the PluginMain( ) function, collectively they
make up a message. The first two parameters represent the message action,
describing what the plug-in is supposed to do. The caller string identifies the
sender of the message and a general category of action. The selector string
specifies the action to take within the category of action. All plug-ins receive
five message actions: startup, shutdown, reload, unload and about. In addition,
your plug-in may receive additional message actions specific to the
plug-in type. The third parameter is a pointer to a data structure, which
varies depending on the message action. Each time your plug-in is called, it
receives a message action from Photoshop. The message action notifies your
plug-in that an action has happened or tells your plug-in to perform an
action.
Last edited on
Topic archived. No new replies allowed.