c# - Set dynamic images to Autogenerated columns in WPF Datagrid -


datagrid declared that

<datagrid x:name="dgdirectories"                    autogeneratecolumns="true" /> 

it dynamically populated using dgdirectories.itemsource property ienumerable of dto object. object contains byte[] property dynamic image (does not exist on hdd). want show images in grid.

i've tried convert byte[] bitmapimage , pass data anyway grid creates datagridtextcolumn type.

probably can done easier have small experience using wpf... please me display images in column

p.s.: i'm newbie in wpf.

xaml code dynamic pathname binding

<datagrid x:name="datagrid1" autogeneratecolumns="false">         <datagrid.columns>             <datagridtemplatecolumn>                 <datagridtemplatecolumn.celltemplate>                     <datatemplate>                         <image source="{binding imagefilepath}" />                     </datatemplate>                 </datagridtemplatecolumn.celltemplate>             </datagridtemplatecolumn>         </datagrid.columns>     </datagrid> 

now start code behind logic uri object instantiated ienumerable list of file paths... hope suffice


Comments

Popular posts from this blog

authentication - Mongodb revoke acccess to connect test database -

ios - Realm over CoreData should I use NSFetchedResultController or a Dictionary? -

r - Update two sets of radiobuttons reactively - shiny -