Error Happens Once



Hi All.

I have a project (VB6 WinXP) with lots of forms and a user control. Not all,
but some of the forms have one or more usercontrols on them. Everything on
the user control is drawn on to it, it is not the container for other
controls and it's AutoDraw is set to true.
I get "Runtime Error 480, Can't create AutoRedraw Image". But It only ever
happens once when The control needs to be drawn, in Run or design mode. When
the project (in VB) starts there is no problem until I go to the design view
of a form with a usercontrol on it, then I get the error, I click "End" and
that's the last time the error will appear until I shut down VB. Once the
error has appeared it never happens again. If I shut down VB, then open it
without opening a forms design and try to compile the error will happen,
click "End" then I can compile with out problem.
The "Image" size is quite small, only about 20 X 50 pixels so no probs
there.
Forgot to mention, the 'Crash' happens on a line of code that draws
something on the usercontrol, either BitBlt or the UserControls Line method.
The two things I can't figure out are:
Why the error happens in the first place when the image to draw is so small,
and why only once per opening the project.
Is this some kind of bug in VB that I have hit?

Any ideas

Ivar




.



Relevant Pages

  • Re: VS2003: Error Adding Existing Item - does not refer to p
    ... Have you tried selecting the project in Solution Explorer, ... > Specifically, I have copied an existing user control (.ascx, .ascx.cs, ... When I right-click on the UserControls sub-folder in the VS Solution ... > FrontPage newsgroup so I assume it's got something to do with FrontPage ...
    (microsoft.public.dotnet.faqs)
  • Re: Accessing SQL Server from a usercontrol
    ... I would think that you can do your database work ... there, populate some objects, and then pass those to the UserControls to ... > When a user control access SQL Server, what happens if I host it multiple ...
    (microsoft.public.dotnet.framework.aspnet)
  • UserControl as Items in ListBox
    ... Does anyone know how to successfully use a collection of UserControls ... simply needs to select the desired row. ... It appears to be necessary to set DrawMode to OwnerDrawFixed and then ... Sadly, though, the user control ...
    (microsoft.public.dotnet.framework.windowsforms)
  • Re: setting focus to an asp.net web user control
    ... When you usercontrols, the controls inside the userControls will have an id ... lets say your user control has an id like "uc1" ... > But it fails when using web user controls. ...
    (microsoft.public.dotnet.framework.aspnet)
  • Re: Lost Thread/Subprocess
    ... complete re-design of the architecture what is impossible at the moment. ... bits to another object and use it as a Singleton (assuming it has ... A User Control is a UI element and should be used as a UI element. ... but this is just a bandaid for a bad design. ...
    (microsoft.public.dotnet.general)