[ale] File streams on URL - clarification

Joe Knapka jknapka at charter.net
Sun Oct 31 23:11:21 EST 1999


My lord. It's amazing Windows programmers live
long enough to finish typing their code. Much
less debugging it...

-- Joe

Kalin Nakov wrote:
> Java:
> try {
>      URL url = new URL("ftp://ftp.mysite.com/myfile.txt");
>      InputStream input = url.openStream();
> }
> catch (Exception e) {
> }
> 
> Win32 API:
> IMoniker *pmkrRemote = NULL;
> IBindCtx *pbctxBinder = NULL;
> IStream *pstmInput = NULL;
> CreateURLMoniker(NULL, L"ftp://ftp.mysite.com/myfile.txt", &pmkrRemote);
> CreateBindCtx(0, &pbctxBinder);
> pmkrRemote->BindToStorage(pbctxBinder, NULL, IID_IStream, (PVOID*)
> &pstmInput);

-- Joe Knapka
"I won't be havin' with that!" -- Granny Weatherwax






More information about the Ale mailing list