🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: borland.public.cppbuilder.nativeapi
Article #1568

Re: Errors on winhttp.h

#1568
From: Mike Collins
Date: Mon, 16 Jul 2007 12:31
48 lines
2609 bytes
not sure about your compile error, some headers are dependent on others, or 
there may be a situation where you have got some sort of circular reference.

I've never had to look at winhttp.h before but you can do exactly what you 
are trying to do using the wininet api's - these seem to be the prefered 
option now.  I have a working system using the wininet api's to connect to a 
url and download update information - it will be exactly the same for you i 
suppose.

If you want to examin this option and need any help, please feel free to 
post back and i'll send you some pointers.

Regards,

Mike

"Thorsten Kettner" <QUESTIONBYthorsten.kettner@otto.de> wrote in message 
news:469b3cbd$1@newsgroups.borland.com...
>
> Has anyone successfully included winhttp.h yet? I get a lot of
> warnings and errors trying it:
>
> [C++ Warning] winhttp.h(46): W8017 Redefinition of 'BOOLAPI' is
> not identical
> ...
> 'HTTP_VERSION_INFO'
> [C++ Error] wininet.h(462): E2344 Earlier declaration of 
> 'HTTP_VERSION_INFO'
> ...
>
> I tried NO_WIN32_LEAN_AND_MEAN, but that didn't change anything.
> I replaced wininet.hpp by an empty file, as this is the one
> containing HTTP_VERSION_INFO, but then I get the error E2189
> Cannot initialize external variable on this code in winhttp.h:
>
> BOOLAPI
> WinHttpTimeFromSystemTime
> (
>    __in CONST SYSTEMTIME *pst,  // input GMT time
>    __out_ecount(WINHTTP_TIME_FORMAT_BUFSIZE) LPWSTR pwszTime // output 
> string buffer
> );
>
> The thing I actually want to do with winhttp is to call a
> website silently from my code and read its html.
>
> TIA,
> Thorsten. 
Technical Details
Message-ID: <469b54b1@newsgroups.borland.com>
Path: arc1-ca.pugleaf.net!g2news1.google.com!news1.google.com!border1.nntp.dca.giganews.com!border2.nntp.dca.giganews.com!nntp.giganews.com!newspeer1.nwr.nac.net!newsfeeds.ihug.co.nz!ihug.co.nz!newsgroups.borland.com!not-for-mail
References: <469b3cbd$1@newsgroups.borland.com>

Show Full Headers
Complete Article Headers
X-Google-Thread: 10cc67,361f119ea15dcccd
X-Google-Attributes: gid10cc67,public,usenet
X-Google-Language: ENGLISH,ASCII-7-bit
From: "Mike Collins" <its@TheBottomOfThePost>
Newsgroups: borland.public.cppbuilder.nativeapi
References: <469b3cbd$1@newsgroups.borland.com>
Subject: Re: Errors on winhttp.h
Date: Mon, 16 Jul 2007 12:31:49 -0000
Lines: 50
X-Priority: 3
X-MSMail-Priority: Normal
X-Newsreader: Microsoft Outlook Express 6.00.3790.3959
X-RFC2646: Format=Flowed; Original
X-MimeOLE: Produced By Microsoft MimeOLE V6.00.3790.4073
NNTP-Posting-Host: 81.155.207.165
Message-ID: <469b54b1@newsgroups.borland.com>
X-Trace: newsgroups.borland.com 1184584881 81.155.207.165 (16 Jul 2007 04:21:21 -0700)
Path: arc1-ca.pugleaf.net!g2news1.google.com!news1.google.com!border1.nntp.dca.giganews.com!border2.nntp.dca.giganews.com!nntp.giganews.com!newspeer1.nwr.nac.net!newsfeeds.ihug.co.nz!ihug.co.nz!newsgroups.borland.com!not-for-mail
X-Original-Bytes: 2463