I am creating an EF4 model-first application with a WPF UI. One of the controls on my UI is a RichTextDocument, which outputs a WPF FlowDocument. I can either serialize the FlowDocument to a byte array, or extract its XAML markup as a string. I would prefer to use binary serialization, if I can. Here are my questions:
If I serialize to a byte array, how do I specify an entity property as a byte array in the EDM Designer?
If I extract a XAML markup string, can I specify that the EDM Designer create the corresponding database column as a
nvarchar(max)
column?
As to the second question, I assume I could always manually edit the MyModel.edmx.sql file to change the data type from nvarchar(4000)
to nvarchar(max)
before executing it, but I would like to know if it can be done in the Designer.
Thanks for your help.