Re: Type convertsion from string



1: the main purpose of Bag here was to provide something that the
propdesc could talk to; an interface would serve just as well; can
provide example [see later]
2: by using an alternative PropertyDescriptor subclass; can provide
example [see later]
3,5,7: I haven no idea; not really used any of them much...
6: sorry; I was unclear; the first reference to each should have
served as a label, the second reference to each should have served as
a back reference, but *1 was somehow to put the values, and *2 was
somehow to track the properties

---
How to add property to type at runtime
I'll assume (from previous) that this means static? Pretty much can't
AFAIK

or create new type which contains new
regular value property defined at runtime ?
It would have to be Reflection.Emit or dynamic compilation (compiler,
code-dom, etc)

In 3,5,7 and "static" you've added needs that weren't mentioned
originally. I maintain that runtime properties are a very good way to
go *in general*, and most of the native .NET code (including winform/
wpf binding, etc) will copy perfectly with this. However, given the
external factors (mono being a biggie!) I can see how keeping it as
simple as possible would be desirable. I was just trying to offer my
best advice on the (limited) information provided at the time. If you
have different needs, or you simply don't agree (which is fine), then
"compile away". But I genuinely would advise you to parse and white-
list input... I don't know how isolated each user is from each other,
but if user A can create a formula that user B then uses, is similar
to an xss risk? If user A only affects user A then less of a problem.

Anyway, I can (if you want) provide examples for 1, 2 and hopefully 4,
but I don't intend going to the trouble unless you say so - as it
sounds like you may have overriding compatibility issues with this
approach. In which case, sorry to have wasted your time. Better to
have considered both though, I guess!

Marc

.



Relevant Pages

  • Re: VS 2005 pb on web site publish
    ... AssemblyKeyContainerName = ... Reference found at search path location ... Could not resolve this reference. ... If this reference is required by your code, you may get compilation ...
    (microsoft.public.dotnet.framework.aspnet)
  • Re: VS 2005 pb on web site publish
    ... Target "_CheckForInvalidConfigurationAndPlatform" skipped. ... Reference found at search path location ... Could not resolve this reference. ... If this reference is required by your code, you may get compilation ...
    (microsoft.public.dotnet.framework.aspnet)
  • Re: VS 2005 pb on web site publish
    ... Target "_CheckForInvalidConfigurationAndPlatform" skipped. ... Reference found at search path location ... Could not resolve this reference. ... If this reference is required by your code, you may get compilation ...
    (microsoft.public.dotnet.framework.aspnet)
  • Previous message are duplicated
    ... Target "_CheckForInvalidConfigurationAndPlatform" skipped. ... Reference found at search path location ... Could not resolve this reference. ... If this reference is required by your code, you may get compilation ...
    (microsoft.public.dotnet.framework.aspnet)
  • repetitive long and irrelevant warnings in VC++ 2003
    ... If I fix the warning from my code all other warnings mystically disappear. ... I am attaching the output of a compilation. ... reference to class template instantiation 'RWTRegularExpression' being ...
    (microsoft.public.dotnet.languages.vc)