Logo

Hacker’s Guide to Visual FoxPro
An irreverent look at how Visual FoxPro really works. Tells you the inside scoop on every command, function, property, event and method of Visual FoxPro.

Remove

This file method removes things from a project or, more technically, from the Files collection of a project.

Usage

filFile.Remove( [ lDeleteIt ] )

Remove is part of the programmatic control of projects introduced in VFP 6. It lets you take files out of a project and, optionally, delete them as well.

Like the other project methods, Remove interacts with the project hook methods that let you insert custom code to occur around project actions. In this case, QueryRemoveFile is executed before the actual removal and can abort the process.

Example

* Remove the first file from the active project without deleting
_VFP.ActiveProject.Files[1].Remove()

See Also

Add, File, Files, Modify, Project, QueryRemoveFile