Solved

Example of ExtFloodfill

Posted on 1998-10-06
2
453 Views
Last Modified: 2008-03-10
I cannot use the function Extfloodfill because vb says: entry not found. Maybe the declaration isn't ok, but I read it in a Windows book. I use this declaration:
'declare function extfloodfill lib "gdi32" (...) as integer'
Can anyone send me a working vbp of Extfloodfill?
0
Comment
Question by:cvanbreugel
2 Comments
 
LVL 8

Accepted Solution

by:
MikeP090797 earned 50 total points
ID: 1438461
For VB4-32bit, VB5 or VB6 this will work:

Declare Function ExtFloodFill Lib "gdi32" Alias "ExtFloodFill" (ByVal hdc As Long, ByVal x As Long, ByVal y As Long, ByVal crColor As Long, ByVal wFillType As Long) As Long

If you are using VB4-16bit or VB3, you can get the correct declare from a winapi.txt file located at \VB\Winapi
0
 

Author Comment

by:cvanbreugel
ID: 1438462
Dear Mike,
Thanks for your answer. The function works now, but not as I want.
I wanted to use the function ExtFloodfill to fill  an area in a  picturebox.
Problem: it works only when the border is black. What I want is that
an area is filled, also when the border has another colour, or when
the border has two colours. The description says that it must work,
but it doesn't.
What is my mistake?
Cees
0

Featured Post

How your wiki can always stay up-to-date

Quip doubles as a “living” wiki and a project management tool that evolves with your organization. As you finish projects in Quip, the work remains, easily accessible to all team members, new and old.
- Increase transparency
- Onboard new hires faster
- Access from mobile/offline

Join & Write a Comment

Introduction While answering a recent question (http://www.experts-exchange.com/Q_27402310.html) in the VB classic zone, I wrote some VB code in the (Office) VBA environment, rather than fire up my older PC.  I didn't post completely correct code o…
I was working on a PowerPoint add-in the other day and a client asked me "can you implement a feature which processes a chart when it's pasted into a slide from another deck?". It got me wondering how to hook into built-in ribbon events in Office.
Show developers how to use a criteria form to limit the data that appears on an Access report. It is a common requirement that users can specify the criteria for a report at runtime. The easiest way to accomplish this is using a criteria form that a…
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…

757 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

23 Experts available now in Live!

Get 1:1 Help Now