Title: How to publish a Frontpage-Web
uses comobj;
procedure TForm1.PublishTheWeb(dir, dest, un, pw: string);
{ dir:
// location of the local web to publish
{ dest
// destination URL, where the web to publish
{ un
// username
{ pw
// password
const
FpPublishNone = 0;
FpPublishIncremental = 1;
FpPublishAddToExistingWeb = 2;
FpPublishCopySubwebs = 4;
var
fp: OLEVariant;
web: OLEVariant;
begin
try
// create an instance of frontpage
fp := CreateOleObject('Frontpage.Application');
// open the web to publish
web := fp.Webs.Open(dir);
// before the web can be published, you should open an Internet connection
// using rasdial.exe
// see Delphi-Tip "...establish a connection to the internet ?"
// or you set your Internetoptions to connect automatically to the Internet
{ open the Internet-connection}
// publish it
web.Publish(dest, FpPublishAddToExistingWeb, un, pw)
except
ShowMessage('Can''t load FrontPage.')
end;
end;