how to download files (2mb>) [server to client]using networkstream from a mailserver.

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • kishoreforqns
    New Member
    • Aug 2010
    • 3

    #1

    how to download files (2mb>) [server to client]using networkstream from a mailserver.

    how to download files (2mb>) [server to client]using networkstream from a mailserver..

    i can conenct to the mail server, list unread mails, and i can also retreive unread mails. but that till 1.5 mb. how to do this.. what concept i have to use.. how the server is sending the data..

    now i am using the code given for retreive (RETR)

    Thread.Sleep(10 0000);

    byte[] arrResponse = new byte[10000000];
    ntstrm.Read(arr Response, 0, arrResponse.Len gth);

    string str = System.Text.Enc oding.ASCII.Get String(arrRespo nse);

    return str;
  • TRScheel
    Recognized Expert Contributor
    • Apr 2007
    • 638

    #2
    Please use [ code ] blocks for your code, makes it easier to make out.

    Also, the thread.sleep seems a bit weird but maybe thats just out of place and Im not seeing it in context.

    Have you tried getting the data in smaller chunks?

    Comment

    Working...