I'm writing a custom XML serializer that can generate XML for any WinForm
object at design or run-time. But there are a couple of cases that I can't
handle properly, but the default Code DOM serializer does. I'd appreciate
any info on how to solve these cases:
1. How can I determine that an object needs to be created as a Resource?
For example, I can write property/value pairs or generate a byte array for an
image but the right answer is to use the bytes. Do I need to special case
just images? Is it because it supports ISerializable? Is it because it uses
an ImageConverter and can be converted to a byte[]? What's the best way to
differentiate this case?
2. I've found some Components just exist at design-time and I don't want
these serialized. For example, on a MenuStrip, at design time, there are
some extra items in the 'Items' collection. Namely something called
a'miniToolStrip' that shouldn't be saved. I haven't found the right logic to
filter out these design-time only components....any ideas?
Thanks,
Joe
jokiz - 12 May 2007 03:33 GMT
properties with DesignOnly attribute are serialized at the resource
file.
On Apr 30, 10:48 pm, Joe Burke <JoeBu...@discussions.microsoft.com>
wrote:
> I'm writing a custom XML serializer that can generate XML for any WinForm
> object at design or run-time. But there are a couple of cases that I can't
[quoted text clipped - 16 lines]
> Thanks,
> Joe