XamDataGrid w/ Drag & Drop, Module Communication

Oct 6, 2008 at 8:16 PM
Hi All,

I have a general architecture question regarding some application wide behaviours I need to 'add' to the XamDataGrid.

I have a number of instance of the XamDataGrid used in various modules.  At the moment the grids are simply declared in the XAML of each view that uses a grid.  Each of these grids needs to support dragging files out (copy) of the grid into other applications or maybe windows explorer.  The grids also need to support other specific functions that require a reference to a class in a module, lets say for arguments sake ModuleA, ClassA.

All my UserControls live in a UserControls.dll that is referenced by each module that needs to access a user control.  If I wrap a XamDataGrid into a user control how could I go about getting a reference to IClassA?  I can't add a reference from UserControls.dll to Infrastructure.dll since there is already a reference from Infrastructure.dll to UserControls.dll.

Would it make more sense to create a XamDataGridController object in the Infrastructure.dll, implement the logic in there and leave the view to forward mouse events to this object?

Any ideas or pointers would be really apprecaited.