string filePaths = Path.Combine(AppDomain.CurrentDomain.BaseDirectory, "\\www.google.com\\file\\upload.txt"); using (StreamWriter writer = new StreamWriter(filePaths, true)) { writer.Write("Word "); writer.WriteLine("word 2"); writer.WriteLine("Line"); }
string mydocpath = Environment.GetFolderPath(Environment.SpecialFolder.MyDocuments); string filePath = mydocpath + @"\upload.txt"; WebClient client = new WebClient(); Uri addy = new Uri("www.google.com\\file\\upload.txt"); byte[] arrReturn = client.UploadFile(addy, filePath); Console.WriteLine(arrReturn.ToString());
var
This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)