this wpf question. have 2 projects in solution, projecta , projectb, projectb referencing projecta. in projecta app.cs class, i've declared property propa (public , static). problem this: how can bind propa xaml in projectb?
obviously
{binding propa,source={x:static application.current}}
won't work, , can't wrap head around problem. appreciated!
update
to clarify confusion, here details. projecta contains viewmodel class needs update app level collection. problem binding collection in xaml window in projectb. solved moving collection projectb app class , firing event viewmodel in projecta. then, in code-behind of window (where set instance of viewmodel data context) subscribe event , act accordingly. mvvm purists might turn green now, little code-behind never hurts!
you cannot. need vise versa reference , circular reference invalid c#.
you can extract third project , have other 2 use it.
Comments
Post a Comment