Solved

Example of ExtFloodfill

Posted on 1998-10-06
2
486 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
[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 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

Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

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

Suggested Solutions

Have you ever wanted to restrict the users input in a textbox to numbers, and while doing that make sure that they can't 'cheat' by pasting in non-numeric text? Of course you can do that with code you write yourself but it's tedious and error-prone …
Article by: Martin
Here are a few simple, working, games that you can use as-is or as the basis for your own games. Tic-Tac-Toe This is one of the simplest of all games.   The game allows for a choice of who goes first and keeps track of the number of wins for…
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…
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…

730 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