I need to pass an instance to (not from) an AppDomain. I've seen a lot of info about how to do the reverse (call create on a domain and use the object locally), but what i want is to pass an instance i already have (not one i create from the domain object), this instance is a MarshalByRefObject and i want to pass it to another domain from my main domain. Is this possible at all?
var MyObject = GetAlreadyPopulatedObject();
AnotherDomain.MakeObjectVisible(MyObject); // this is what i'm trying to do, make the instance i have available somewhere else
// And if it's possible, how would i access it from the other Domain? How can i find it?
The scenario i have is i'm handling data that i create, i want to pass it for manipulation to a plugin in another appdomain, and then to retrieve the modified version and i'm a bit at a loss.