Download the free trial version
Basic4android Video
Features
Tutorials and manuals
Showcase
Screenshots

Go Back   Android Development Forum - Basic4android > Basic4ppc (Windows Mobile) > Questions (Windows Mobile)
Documentation Wiki Register Members List B4P Search Today's Posts Mark Forums Read

Questions (Windows Mobile) Post any question regarding Basic4ppc.

Why is my drawer.New2() not working?

Reply
 
LinkBack Thread Tools Display Modes
  #1 (permalink)  
Old 03-24-2008, 05:41 PM
willisgt's Avatar
Senior Member
 
Join Date: Aug 2007
Location: Nacogdoches, Texas USA
Posts: 162
Default Why is my drawer.New2() not working?

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

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

Code:
    ' ... background image

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

AddObject( 
"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.


Gary

__________________
PC: Windows XP Pro SP3 / Basic4PPC v6.5
PPC: HTC 8925 (AT&T Tilt) / Windows Mobile 6
Reply With Quote
  #2 (permalink)  
Old 03-24-2008, 06:23 PM
Erel's Avatar
Administrator
 
Join Date: Apr 2007
Posts: 15,733
Awards Showcase
Basic4ppc Founder 
Total Awards: 1
Default

B4PObject(5) is actually a reference to the main form.
You should show the form before this line.
Reply With Quote
  #3 (permalink)  
Old 03-24-2008, 07:50 PM
willisgt's Avatar
Senior Member
 
Join Date: Aug 2007
Location: Nacogdoches, Texas USA
Posts: 162
Default

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

__________________
PC: Windows XP Pro SP3 / Basic4PPC v6.5
PPC: HTC 8925 (AT&T Tilt) / Windows Mobile 6
Reply With Quote
  #4 (permalink)  
Old 06-29-2008, 10:27 AM
Newbie
 
Join Date: May 2008
Posts: 1
Default drawer.New2

Try this:

' ... background image

' make a new image with NEW2

bitmapBKG.New2(width,height)

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

pen.Color = cCyan 'Rgb( 0, 128, 0 )
Reply With Quote
Reply


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are Off
Refbacks are On

Similar Threads
Thread Thread Starter Forum Replies Last Post
Working with VGA screens Erel Tutorials 29 04-30-2009 12:38 AM
working with FormExDesktop_1.2 Cableguy Questions (Windows Mobile) 20 01-28-2008 06:02 PM
Background-Color on Bitmap.new2 Roadrunner Bug Reports 1 12-08-2007 03:08 PM
Drawer overlay each other possible? MM2forever Questions (Windows Mobile) 2 08-24-2007 06:29 AM
drawer with thick line hung Basic4ppc Wishlist 2 07-19-2007 01:38 PM


All times are GMT. The time now is 09:06 AM.


Powered by vBulletin® Version 3.6.12
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.
Search Engine Friendly URLs by vBSEO 3.3.0