In order to prevent OutOfMemoryException errors I want to load large images as needed, rather than loading all into an ImageList array at the start. So i'm initializing a BitMapEx object as follows in App_Start:
bitmapMapEx.New1 (AppPath & "\blank.jpg")
Then I tried executing the following:
Sub LoadImage
s = imageFileArr(imageIndex).imagename 'string
bitmapMapEx.Value = (AppPath & "\" & s)
End Sub
The result is that I get an error message saying the Input string was not in the correct format.
Is my thinking correct - will it prevent the OutOfMemeoryException error? and what is causing the 'Input String' error?
Saj.
bitmapMapEx.New1 (AppPath & "\blank.jpg")
Then I tried executing the following:
Sub LoadImage
s = imageFileArr(imageIndex).imagename 'string
bitmapMapEx.Value = (AppPath & "\" & s)
End Sub
The result is that I get an error message saying the Input string was not in the correct format.
Is my thinking correct - will it prevent the OutOfMemeoryException error? and what is causing the 'Input String' error?
Saj.