Clearly the visualBic
class is not the class to be passing to the implementation! As you noted, it has UI specific fields/logic and so is not suitable for living in the "Implementation" project where it would have to for classes in that project to know about it.
The answer to your question is you don't EVER want a reference from "Implementation" to the GUI because that tightly couples the two, completely defeating the purpose of separating them in the first place (even if it was technically possible).
Instead, you need a new object that CAN live in "Implementation" that your GUI fills out and passes to the appropriate function.
My visualBic
: (in GUI assembly)
public class visualBic
{
public String Name {get; set;}
... Bunch of other, potentially GUI stuff
}
BicDTO: (In Implementation assembly)
public class BicDTO
{
public String Name {get; set;}
}
Translation function: (In GUI assembly)
public void SendImplementationData(visualBic data)
{
BicDTO implementationObject = new BicDTO();
implementationObject.Name = data.Name;
implementationRef.SendData(implementationObject);
}
Obviously this is highly generalized, but it should get the point across. Let me know if I can clarify anything else!