Solved

Rotating an Image

Posted on 1998-09-11
3
331 Views
Last Modified: 2010-04-30
How do you rotate an image in visual basic ???
and I mean flat 2D rotation ( like a clock's hands)
not 3D !
0
Comment
Question by:Eagle_232
3 Comments
 

Author Comment

by:Eagle_232
ID: 1434468
Adjusted points to 200
0
 
LVL 1

Accepted Solution

by:
sunj earned 200 total points
ID: 1434469
There is no VB built-in function that can do arbitrary rotation. What you can do is to store the image pixel data into a two-dimensional array and then do the rotation transform yourself. Let me know if you need the formula for the transform. :)
0
 
LVL 4

Expert Comment

by:martinag
ID: 1434470
Have a look at MSKB: http://support.microsoft.com/support/kb/articles/q186/2/60.asp
If you want me to post the code I will.

Note that the example rotates the bitmap in steps by 90 degrees, but it's rather easy to change it to rotate it any degrees you want to.

Martin
0

Featured Post

How to run any project with ease

Manage projects of all sizes how you want. Great for personal to-do lists, project milestones, team priorities and launch plans.
- Combine task lists, docs, spreadsheets, and chat in one
- View and edit from mobile/offline
- Cut down on emails

Join & Write a Comment

Introduction In a recent article (http://www.experts-exchange.com/A_7811-A-Better-Concatenate-Function.html) for the Excel community, I showed an improved version of the Excel Concatenate() function.  While writing that article I realized that no o…
Most everyone who has done any programming in VB6 knows that you can do something in code like Debug.Print MyVar and that when the program runs from the IDE, the value of MyVar will be displayed in the Immediate Window. Less well known is Debug.Asse…
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…
This lesson covers basic error handling code in Microsoft Excel using VBA. This is the first lesson in a 3-part series that uses code to loop through an Excel spreadsheet in VBA and then fix errors, taking advantage of error handling code. This l…

706 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

Need Help in Real-Time?

Connect with top rated Experts

12 Experts available now in Live!

Get 1:1 Help Now