Connecting Tech Pros Worldwide Help | Site Map

Compile Errors

 
LinkBack Thread Tools Search this Thread
  #1  
Old December 29th, 2006, 09:45 AM
Roger Vale
Guest
 
Posts: n/a
Default Compile Errors

Hi all

Visual studio 2005
windows mobile application

I am getting this from the imediate window A first chance exception of type
'System.InvalidCastException' occurred in System.Drawing.dll

Now the program still runs but this error seems to appear every time i swap
an image from a file

Code i am using is as follows

Dim leftImage As Bitmap


leftImage = New Bitmap(boardImagesPath +
CStr(boardPositionP1 - 1) + ".jpg")
leftPb.Image = leftImage


I dont know if this is enough information any help would be great

Thanks in advance

Roger


  #2  
Old December 29th, 2006, 12:05 PM
Jan Hyde
Guest
 
Posts: n/a
Default Re: Compile Errors

"Roger Vale" <roger.vale@btinternet.com>'s wild thoughts
were released on Fri, 29 Dec 2006 10:40:18 -0000 bearing the
following fruit:
Quote:
>Hi all
>
>Visual studio 2005
You need to ask in a 'dotnet' group, this group is for VB
'classic'

J
Quote:
>windows mobile application
>
>I am getting this from the imediate window A first chance exception of type
>'System.InvalidCastException' occurred in System.Drawing.dll
>
>Now the program still runs but this error seems to appear every time i swap
>an image from a file
>
>Code i am using is as follows
>
>Dim leftImage As Bitmap
>
>
leftImage = New Bitmap(boardImagesPath +
>CStr(boardPositionP1 - 1) + ".jpg")
leftPb.Image = leftImage
>
>
>I dont know if this is enough information any help would be great
>
>Thanks in advance
>
>Roger

Jan Hyde (VB MVP)

--
Show me a piano falling down a mineshaft and I'll show you A-flat minor

(Karen Mascew)

 

Bookmarks

Thread Tools Search this Thread
Search this Thread:

Advanced Search

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

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

Popular Articles

What is Bytes?

We are a network of experts and professionals in IT and software development that help one another with answers to tough questions and share insights. Get the best answers to your questions from over 220,662 network members.