retrieve image's width and height
ASP.NET
2
Posts
2
Posters
0
Views
1
Watching
-
how can i retrieve image's width and height. image i saved in database table in sql server in byte format i am aleady retreieving image into a image button
The System.Drawing.Image class exposes width and height properties. How are you retrieving the image (into what kind of structure, I mean)? I assume that if you're storing it as a BLOB in the database, you're retrieving it as a byte[] initially. If so, you should be able to create a memory stream from the byte array, and use the stream to create an Image instance.
The most exciting phrase to hear in science, the one that heralds the most discoveries, is not 'Eureka!' ('I found it!') but 'That's funny...’