c# - Displaying related, but non-foreign key data in a Silverlight datagrid column -


I have a silverlight application that uses 2 different databases. I have a situation where I have a database There is an ID column in it, and the other is the lookup table in the database. Obviously I can not apply it as a foreign key, and the unit framework will not allow me to create a single data model for two databases, so I Definition of this relationship Injury can not.

When I create an ID column from database 1, I would like to display a field from database 2.

Ideally I would like to define this relationship and would like to use a compulsive path (and I do not know about my model about my ViewModel) a column to which the combo box likes to Can be bound, for example

  & lt; Data: DataGridTextColumn header = "project" binding = "{binding path = ProjectId}" itemsource = "{binding path = data source. Projects, source = {static resource view modelprosy}}" displaymemberpath = "projectname" />  

Any help or criticism of my approach will be appreciated.

My first thought was that you can create custom value converter?

Bind the foreign key value, and give the required property name as the converter parameter, and look in the converter.


Comments

Popular posts from this blog

c# - sqlDecimal to decimal clr stored procedure Unable to cast object of type 'System.Data.SqlTypes.SqlDecimal' to type 'System.IConvertible' -

Calling GetGUIThreadInfo from Outlook VBA -

Obfuscating Python code? -