Click here to Skip to main content
15,910,277 members
Home / Discussions / Visual Basic
   

Visual Basic

 
GeneralBen is new to VB.NET Pin
bensoncd14-Jul-03 14:45
bensoncd14-Jul-03 14:45 
GeneralRe: Ben is new to VB.NET Pin
newalfi15-Jul-03 0:16
newalfi15-Jul-03 0:16 
GeneralRe: Ben is new to VB.NET Pin
bensoncd15-Jul-03 13:54
bensoncd15-Jul-03 13:54 
GeneralRe: new to vb Pin
laurarana26-Jun-03 21:26
laurarana26-Jun-03 21:26 
GeneralRe: new to vb Pin
parths30-Jun-03 22:16
parths30-Jun-03 22:16 
QuestionICON ON TITLE? Pin
Jonavis11-Jun-03 5:02
Jonavis11-Jun-03 5:02 
AnswerRe: ICON ON TITLE? Pin
Jason McBurney13-Jun-03 7:03
Jason McBurney13-Jun-03 7:03 
GeneralHelp! Image.FromFile() causes out of memory exception Pin
alman11-Jun-03 3:50
alman11-Jun-03 3:50 
:(Help!

I'm trying to load an icon file into a picturebox using the following code:

PictureBox1.Image = Image.FromFile("cow.ico")

When executed an "Out of Memory Exception" is thrown every single time. My development machine has 1GB of RAM, and when this happens I have well over 1/2GB of physical memeory available, never mind the page file.

The rest of the program isn't very big. There is an array of about 3000 elements in there, but the exception is thrown before that array is initialized or filled.

Could this be a problem with my icon file? I use it in several other places with no problems... It does have every possible icon size/colour depth but is only 49K on the drive.

What is also curious is that this line works fine (it follows the above) when I comment the picturebox line out:

Me.Icon = new Icon("Cow.ico")


-Allan
GeneralRe: Help! Image.FromFile() causes out of memory exception Pin
dynamic11-Jun-03 15:16
dynamic11-Jun-03 15:16 
QuestionHow To Freeze Datagrid Pin
Paras Shah11-Jun-03 1:01
Paras Shah11-Jun-03 1:01 
GeneralSelect Folder Dialog Box Pin
mlatimer10-Jun-03 21:07
mlatimer10-Jun-03 21:07 
GeneralRe: Select Folder Dialog Box Pin
J. Dunlap10-Jun-03 21:45
J. Dunlap10-Jun-03 21:45 
GeneralRe: Select Folder Dialog Box Pin
mlatimer10-Jun-03 22:11
mlatimer10-Jun-03 22:11 
QuestionHow to add multiple rows to Datagrid Pin
AnuPinky10-Jun-03 20:10
AnuPinky10-Jun-03 20:10 
AnswerRe: How to add multiple rows to Datagrid Pin
nisevoli11-Jun-03 6:25
nisevoli11-Jun-03 6:25 
GeneralRe: How to add multiple rows to Datagrid Pin
Anonymous12-Jun-03 8:17
Anonymous12-Jun-03 8:17 
GeneralRe: How to add multiple rows to Datagrid Pin
nisevoli15-Jun-03 14:37
nisevoli15-Jun-03 14:37 
QuestionLightweight controls? Pin
newalfi10-Jun-03 9:47
newalfi10-Jun-03 9:47 
AnswerRe: Lightweight controls? Pin
J. Dunlap10-Jun-03 10:46
J. Dunlap10-Jun-03 10:46 
GeneralRe: Lightweight controls? Pin
newalfi10-Jun-03 19:50
newalfi10-Jun-03 19:50 
GeneralRe: Lightweight controls? Pin
J. Dunlap10-Jun-03 21:41
J. Dunlap10-Jun-03 21:41 
GeneralRe: Lightweight controls? Pin
newalfi11-Jun-03 5:32
newalfi11-Jun-03 5:32 
GeneralShell Extension Handler using VB.NET Pin
AlfredoDS10-Jun-03 0:18
AlfredoDS10-Jun-03 0:18 
GeneralAccess DataGrid from other application Pin
cybrgeek9-Jun-03 14:12
cybrgeek9-Jun-03 14:12 
GeneralMSComm problems Pin
NetDave9-Jun-03 13:55
NetDave9-Jun-03 13:55 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.