G
garyusenet
I could do with something similiar, can you tell me if you think this
would work for me, and if there's any advantage in working with
controls
this way than how I currently am.
At the moment i'm using the treenodes and each treenode needs a unique
entry into my rich text box. After sitting at home with MSDN i've
managed to get this functionality by storing a RTF string in the tag
property of the treenode. On every 'before update' of the treeview I
save the current RTF string from the rich textbox to the tag property
of the selected node. On every 'after update' I pull in the RTF from
the selected tag property into the rich text box.
Would it be better for me to have a new class with a richtext property
or something? or is the way i'm doing it perfectly OK?
Am i right in thinking a new class would mean that i'd create new
objects which would have all the functionality of the treeview control,
all treeview properties etc... but also extra properties / methods that
I specify? If this is the case, would there be a property better suited
to storing richtext that I could create which is different to the
already provided tag property?
My treenode collection will have about 40 nodes, and each node will
have its own richtext associated with it eventually - the richtext is
typically 1-3 pages worth per node.
Should I be storing this info in a database instead of the tag
property? At the moment i'm serialising the treeview and saving to a
file, which conveniently captures the rich text entries too as i'm
storing them in the tag property.
Finally a previous post I was reading about creating your own objects
mentioned common
interface and polymorphism could someone explain this please, i've
never tried creating my own class from an already existing class
before.
Many Thanks.
Gary.
would work for me, and if there's any advantage in working with
controls
this way than how I currently am.
At the moment i'm using the treenodes and each treenode needs a unique
entry into my rich text box. After sitting at home with MSDN i've
managed to get this functionality by storing a RTF string in the tag
property of the treenode. On every 'before update' of the treeview I
save the current RTF string from the rich textbox to the tag property
of the selected node. On every 'after update' I pull in the RTF from
the selected tag property into the rich text box.
Would it be better for me to have a new class with a richtext property
or something? or is the way i'm doing it perfectly OK?
Am i right in thinking a new class would mean that i'd create new
objects which would have all the functionality of the treeview control,
all treeview properties etc... but also extra properties / methods that
I specify? If this is the case, would there be a property better suited
to storing richtext that I could create which is different to the
already provided tag property?
My treenode collection will have about 40 nodes, and each node will
have its own richtext associated with it eventually - the richtext is
typically 1-3 pages worth per node.
Should I be storing this info in a database instead of the tag
property? At the moment i'm serialising the treeview and saving to a
file, which conveniently captures the rich text entries too as i'm
storing them in the tag property.
Finally a previous post I was reading about creating your own objects
mentioned common
interface and polymorphism could someone explain this please, i've
never tried creating my own class from an already existing class
before.
Many Thanks.
Gary.