Why is my drawer.New2() not working?

Discussion in 'Questions (Windows Mobile)' started by willisgt, Mar 24, 2008.

  1. willisgt

    willisgt Active Member Licensed User

    Could someone please tell me why this is producing an error?

    bitmapBKG is a bitmap, and background.bmp is a 24-bit BMP.

    ' ... background image

       bitmapBKG.New1( AppPath & 
    "\background.bmp" )

    "drawerBKG""Drawer" )
       drawerBKG.New2( bitmapBKG.Value, B4PObject(
    5) )   '<-- error happens on this line
       pen.Color = cCyan   
    'Rgb( 0, 128, 0 )
    The error is: 'Object reference not set to an instance of an object'.

    I'm using ImageLib.dll v. 1.0.2860.34398.


  2. Erel

    Erel Administrator Staff Member Licensed User

    B4PObject(5) is actually a reference to the main form.
    You should show the form before this line.
  3. willisgt

    willisgt Active Member Licensed User

    *sigh* It's always the little details...

  4. Hai-DJ

    Hai-DJ New Member Licensed User


    Try this:

    ' ... background image

    ' make a new image with NEW2


    AddObject( "drawerBKG", "Drawer" )
    drawerBKG.New2( bitmapBKG.Value, B4PObject(5) )

    pen.Color = cCyan 'Rgb( 0, 128, 0 )
  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.
    Dismiss Notice