Solved

How can I get the size of a bitmap using GetBitmapDimensionEx?

Posted on 2001-06-13
2
319 Views
Last Modified: 2012-05-05
Thank you !
0
Comment
Question by:turbosoft
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
2 Comments
 
LVL 10

Expert Comment

by:caraf_g
ID: 6184989
http://msdn.microsoft.com/library/psdk/gdi/bitmaps_1l4o.htm

http://msdn.microsoft.com/library/psdk/gdi/bitmaps_2ghe.htm

in VB: (private can be public in certain circumstances)

Private Type SIZE
    cx As Long
    cy As Long
End Type


Private Declare Function GetBitmapDimensionEx Lib "gdi32" Alias "GetBitmapDimensionEx" (ByVal hBitmap As Long, lpDimension As SIZE) As Long

0
 
LVL 5

Accepted Solution

by:
AndrewDev earned 50 total points
ID: 6184995
Here is the MSDN documentation

http://msdn.microsoft.com/library/psdk/gdi/bitmaps_1l4o.htm

However the example of its use is not VB. So I don't know how much help it will be. It also states that the retrieved dimensions must have been set by the SetBitmapDimensionEx function. So unless you know this has been used I doubt it will be much use.

What are you trying to do once you have got the dimensions, there are various tools for manipulating bitmaps which I am sure we can help with, if you give us a bit more information.
Regards
Andrew
0

Featured Post

SharePoint Admin?

Enable Your Employees To Focus On The Core With Intuitive Onscreen Guidance That is With You At The Moment of Need.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

I’ve seen a number of people looking for examples of how to access web services from VB6.  I’ve been using a test harness I built in VB6 (using many resources I found online) that I use for small projects to work out how to communicate with web serv…
If you need to start windows update installation remotely or as a scheduled task you will find this very helpful.
As developers, we are not limited to the functions provided by the VBA language. In addition, we can call the functions that are part of the Windows operating system. These functions are part of the Windows API (Application Programming Interface). U…
Get people started with the process of using Access VBA to control Excel using automation, Microsoft Access can control other applications. An example is the ability to programmatically talk to Excel. Using automation, an Access application can laun…

726 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question