T
theis.netronic
Hi,
I have build a custom control with a Bitmap property inside:
System:rawing::Bitmap* myBitmap;
__property System:rawing::Bitmap* get_Bitmap( void )
{return myBitmap;}
__property void set_Bitmap( System:rawing::Bitmap* tmpBitmap)
{myBitmap = tmpBitmap;}
When dragging my control onto a webform the corresponding .aspx file
looks like following:
<cc1:ctrl id="myCtrl1" style="Z-INDEX: 102; LEFT: 48px; POSITION:
absolute;
TOP: 128px" runat="server" Width="536px" Height="224px"
Bitmap="System.Drawing.Bitmap">
</cc1:ctrl>
1) The parser rises at design time the error: "Parser Error: Cannot
create an object of type 'System.Drawing.Bitmap' from its string
representation 'System.Drawing.Bitmap' for the 'Bitmap' property"
What is wrong? Which class- or property-attributes (e.g. ParseChildren
....) must be set? What else is to be done?
2) Is it possible at design time to save values of complex properties
to the the .resx file of the webform? With windows forms controls the
ide (e.g. Visual Studio 2003) uses codeDOMSerialization to do that,
but I didn't succeed in doing it with a web server control.
Thanks.
I have build a custom control with a Bitmap property inside:
System:rawing::Bitmap* myBitmap;
__property System:rawing::Bitmap* get_Bitmap( void )
{return myBitmap;}
__property void set_Bitmap( System:rawing::Bitmap* tmpBitmap)
{myBitmap = tmpBitmap;}
When dragging my control onto a webform the corresponding .aspx file
looks like following:
<cc1:ctrl id="myCtrl1" style="Z-INDEX: 102; LEFT: 48px; POSITION:
absolute;
TOP: 128px" runat="server" Width="536px" Height="224px"
Bitmap="System.Drawing.Bitmap">
</cc1:ctrl>
1) The parser rises at design time the error: "Parser Error: Cannot
create an object of type 'System.Drawing.Bitmap' from its string
representation 'System.Drawing.Bitmap' for the 'Bitmap' property"
What is wrong? Which class- or property-attributes (e.g. ParseChildren
....) must be set? What else is to be done?
2) Is it possible at design time to save values of complex properties
to the the .resx file of the webform? With windows forms controls the
ide (e.g. Visual Studio 2003) uses codeDOMSerialization to do that,
but I didn't succeed in doing it with a web server control.
Thanks.