Hello,
I am experiencing problems with UltraTabControl. My project is a gui with one ultratabcontrol, one fixed tabpage and n dynamically added tabpages. The appearance.image of each tabpage is assigned an image loaded from embeddee resource.
The tabpages are showed in Multirows (MultiRowAutoSize). This works fine so far. But as soon as I load an applicationstyling. The application crashes saying that there is not enough memory.
I could reproduce, that this is only in combination of all three factors
I checked if maybe this is a problem of my userdefined style. So I created a new one from scratch using the cherry template. Same effect.
Attached you will find a project to reproduce this.
What can I do to avoid this error. I need these settings in a clients project.
Kind regards
Patrick
Patrick,
This seems to be caused by closing the Stream object before the image can be fully rendered. If you alter the attached sample to not close out the stream, you will see that it works correclty. I looked at the code in Reflector for the constructor of the Bitmap class that takes a stream, and it seems that it will close the stream itself, so you should not have to worry about memory leaks with that either.
-Matt
Ok this works for me but why does this happen only in combination of these thre factors? As soon as I set the TabPageLayout to Single... there is no problem...