image at runtime
-
hi i am working on vb, I have a problem in image manipulation Is there any way to know height and width of the image at runtime if anybody knows this please help me. Thanks
-
Hello
Dim pic_image As New Bitmap("c:\sample.jpg") MsgBox(pic_image.Size.Height & "---" & pic_image.Size.Width)
Hope it helps -
Thanks i Think it will worked but could you tell me which reference library i have to use for bitmap Thanks -- modified at 8:16 Thursday 23rd March, 2006
-
Hello You have to reference the System.Drawing library Then in top of your class insert: Imports System.Drawing That's it
-
hi It is working in vb.net but not in vb6.0 because in vb 6.0 there is no any class like bitmap in system.drawing.dll. if you have any other idea so please! Thanks
The simplest way in vb6 is to add aninvisible picture box and do the following to load the picture and obtain the height width PicBox.Picture = LoadPicture("C:\1.jpg") PicBox.AutoSize = True MsgBox PicBox.Width MsgBox PicBox.Height Me.Show "If i was king cigarettes would be free."
-
The simplest way in vb6 is to add aninvisible picture box and do the following to load the picture and obtain the height width PicBox.Picture = LoadPicture("C:\1.jpg") PicBox.AutoSize = True MsgBox PicBox.Width MsgBox PicBox.Height Me.Show "If i was king cigarettes would be free."