Cursor from BitMap

  • Thread starter Thread starter Guest
  • Start date Start date
Does Herfried support a link that interest me, does it not work.

:-)

Cor
 
Hi,

You can create a bitmap then create the cursor from the bitmap.


Dim bmCur As New Bitmap(60, 60)

Dim g As Graphics = Graphics.FromImage(bmCur)

g.FillRectangle(Brushes.Transparent, 0, 0, 60, 60)

g.DrawEllipse(Pens.Red, 10, 10, 40, 40)

g.DrawEllipse(Pens.Red, 0, 0, 60, 60)

g.DrawEllipse(Pens.Red, 30, 30, 1, 1)

g.DrawEllipse(Pens.Red, 25, 25, 10, 10)

Dim ptrCur As IntPtr = bmCur.GetHicon

Dim cur As Cursor

cur = New Cursor(ptrCur)

Me.Cursor = cur



Ken
 
Herfried,

Sorry I remembered me this one again it is from Ken I took it already in my
HKW brainconnector replacer.

:-)

Cor
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top