Solved

FtpGetFile parameter question

Posted on 2003-12-08
2
616 Views
Last Modified: 2008-03-10
I need to get either a binary or ascii file from a remote server.  I saw postings on EE that the API call could be:

bRC = FtpGetFile(m_hConnect, sRemoteFile, sLocalFile, False, _
                                  INTERNET_FLAG_RELOAD, m_dwFlags, 0)

where I'll set m_dwFlags = FTP_TRANSFER_TYPE_BINARY or to = FTP_TRANSFER_TYPE_ASCII

I read on MS's web site that the INTERNET_FLAG_RELOAD should be or'd w/the m_dwFlags and the 4th parm should be a FILE_ATTRIBUTE_* constant.  So, I changed the API call to be:

bRC = FtpGetFile(m_hConnect, sRemoteFile, sLocalFile, False, _
                         FILE_ATTRIBUTE_NORMAL, m_dwFlags Or INTERNET_FLAG_RELOAD, 0)

What's correct?  Please assign.

Thanks.
0
Comment
Question by:halfondj
  • 2
2 Comments
 
LVL 14

Expert Comment

by:ajexpert
ID: 9896137
0
 
LVL 14

Accepted Solution

by:
ajexpert earned 500 total points
ID: 9896144
0

Featured Post

Better Security Awareness With Threat Intelligence

See how one of the leading financial services organizations uses Recorded Future as part of a holistic threat intelligence program to promote security awareness and proactively and efficiently identify threats.

Join & Write a Comment

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…
Background What I'm presenting in this article is the result of 2 conditions in my work area: We have a SQL Server production environment but no development or test environment; andWe have an MS Access front end using tables in SQL Server but we a…
Show developers how to use a criteria form to limit the data that appears on an Access report. It is a common requirement that users can specify the criteria for a report at runtime. The easiest way to accomplish this is using a criteria form that a…
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…

746 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

Need Help in Real-Time?

Connect with top rated Experts

12 Experts available now in Live!

Get 1:1 Help Now