Problem in connecting with FTPServer

General discussion regarding the development of POCO for contributors.
AnithaSubramani
Posts: 7
Joined: 20 Oct 2008, 14:48

Problem in connecting with FTPServer

Postby AnithaSubramani » 21 Oct 2008, 14:29

Hi All,

We are working with FTPServer in visual studio 2005.When we are running the following code in visual studio 2005

Code: Select all


#include "Poco/URIStreamOpener.h"
#include "Poco/StreamCopier.h"
#include "Poco/Path.h"
#include "Poco/URI.h"
#include "Poco/Exception.h"
#include "Poco/Net/HTTPStreamFactory.h"
#include "Poco/Net/FTPStreamFactory.h"
#include
#include


using Poco::URIStreamOpener;
using Poco::StreamCopier;
using Poco::Path;
using Poco::URI;
using Poco::Exception;
using Poco::Net::HTTPStreamFactory;
using Poco::Net::FTPStreamFactory;


int main(int argc, char** argv)
{
   HTTPStreamFactory::registerFactory();
   FTPStreamFactory::registerFactory();
   
   if (argc != 2)
   {
      Path p(argv[0]);
      std::cerr << "usage: " << p.getBaseName() << " " << std::endl;
      std::cerr << "       Download to standard output." << std::endl;
      std::cerr << "       Works with http, ftp and file URIs." << std::endl;
      return 1;
   }

   try
   {
      URI uri(argv[1]);
      std::auto_ptr pStr(URIStreamOpener::defaultOpener().open(uri));
      StreamCopier::copyStream(*pStr.get(), std::cout);
   }
   catch (Exception& exc)
   {
      std::cerr << exc.displayText() << std::endl;
      return 1;
   }
      
   return 0;
}



we are facing the following error when we are trying to run the below syntax in command prompt .



E:ftpdownloaddebug>ftpdownload ftp://www.abcd.com/username=kkjdk
password=amhjhj
FTP Exception: Login denied: 530 Not logged in, user account has been disabled


Kindly please provide a solution.
Regards,
Anitha

guenter
Posts: 1194
Joined: 11 Jul 2006, 16:27
Location: Austria

Re: Problem in connecting with FTPServer

Postby guenter » 21 Oct 2008, 14:36

> 530 Not logged in, user account has been disabled

How about providing a valid username and password?

AnithaSubramani
Posts: 7
Joined: 20 Oct 2008, 14:48

Re: Problem in connecting with FTPServer

Postby AnithaSubramani » 21 Oct 2008, 14:44

we gave a valid url, user name, and password while trying in the PC for the sake of posting in forums we gave a junk value.please help us

alex
Posts: 1294
Joined: 11 Jul 2006, 16:27
Location: United_States

Re: Re: Problem in connecting with FTPServer

Postby alex » 21 Oct 2008, 17:04

> we gave a valid url, user name, and password while trying in the PC for the sake of posting in forums we gave a junk value.

So what was the error you've got when you have provided valid values?

please help us

It's kind of hard to help if we don't know what the problem is.

AnithaSubramani
Posts: 7
Joined: 20 Oct 2008, 14:48

Re: Problem in connecting with FTPServer

Postby AnithaSubramani » 21 Oct 2008, 17:11

ftpdownload ftp://198.162.67.67/username/password


Return to “Contributors”

Who is online

Users browsing this forum: No registered users and 1 guest

cron