c# - Modern UI passing parameters in Link -


i'm using modern ui, , have usercontrol viewmodel,... need reuse , need same usercontrol but, managing other data, idea send parameter in uri, in userpage constructor , set in viewmodel , problem how parameter in constructor of user control? or there better aproach? send parameters user controls in modernui ?

        this.menu = new linkgroupcollection();          linkgroup reportes = new linkgroup() { displayname = "show report", groupkey = "1" };         reportes.links.add(new link() { displayname = "see report", source = new system.uri("/views/reportes.xaml", urikind.relative) });         reportes.links.add(new link() { displayname = "process something", source = new system.uri("/views/process.xaml?tipo=1", urikind.relative) });         this.menu.add(reportes);         linkgroup abmreporte = new linkgroup() { displayname = "report", groupkey = "1" };         abmreporte.links.add(new link() { displayname="manage  reports",source=new system.uri("/views/reporte.xaml", urikind.relative) });         this.menu.add(abmreporte); 

you can see in code "views/process.xaml?tipo=1" way guess may done guessing. part of code witch viewmodel constructor, menu collection binding "menulinkgroups" collection on xaml of main modernwindow

any great thanks


Comments

Popular posts from this blog

android - InAppBilling registering BroadcastReceiver in AndroidManifest -

python Tkinter Capturing keyboard events save as one single string -

sql server - Why does Linq-to-SQL add unnecessary COUNT()? -