Click here to Skip to main content
15,504,424 members
Home / Discussions / C#
   

C#

 
GeneralRe: Passing boolean parameter to an oracle procedure Pin
NotPolitcallyCorrect26-Jun-13 5:10
NotPolitcallyCorrect26-Jun-13 5:10 
GeneralRe: Passing boolean parameter to an oracle procedure Pin
Subin Mavunkal26-Jun-13 5:36
Subin Mavunkal26-Jun-13 5:36 
AnswerOracle doesn't have a boolean type Pin
Ennis Ray Lynch, Jr.26-Jun-13 7:34
Ennis Ray Lynch, Jr.26-Jun-13 7:34 
QuestionVisual Studio 2010 Database Web Application Pin
Mausam Bharati26-Jun-13 3:17
Mausam Bharati26-Jun-13 3:17 
QuestionHow to Create WCF Rest service in Visual Studio 2012? Pin
Vijay Kanda25-Jun-13 21:55
Vijay Kanda25-Jun-13 21:55 
AnswerRe: How to Create WCF Rest service in Visual Studio 2012? Pin
Richard MacCutchan25-Jun-13 21:57
mveRichard MacCutchan25-Jun-13 21:57 
GeneralRe: How to Create WCF Rest service in Visual Studio 2012? Pin
Vijay Kanda25-Jun-13 23:14
Vijay Kanda25-Jun-13 23:14 
QuestionUpload file using C# Windows service application Pin
susanna.floora25-Jun-13 20:54
susanna.floora25-Jun-13 20:54 
i want to upload a file to ftp server using simple C# widows service application, and this is my code

protected void UploadToFTP(string path, string name)
{

string strLocation = string.Format(ftpfullpath + "/{0}.txt", strNewFtpName);
// FtpWebRequest ftp = (FtpWebRequest)FtpWebRequest.Create("ftp://192.168.10.239/test.txt");
FtpWebRequest ftp = (FtpWebRequest)FtpWebRequest.Create(strLocation);
ftp.Credentials = new NetworkCredential(strFtpUsername, StrftpPassowrd);
ftp.KeepAlive = true;
ftp.UseBinary = true;
ftp.Method = WebRequestMethods.Ftp.UploadFile;
FileStream fs = File.OpenRead(source);
byte[] buffer = new byte[fs.Length];
fs.Read(buffer, 0, buffer.Length);
fs.Close();

Stream ftpstream = ftp.GetRequestStream();
ftpstream.Write(buffer, 0, buffer.Length);
ftpstream.Close();
}

when i test this application .txt file is created in FTP server.
But when i run a window service the .txt file is not created(uploaded) on FTP server. How do i solve this??
SuggestionRe: Upload file using C# Windows service application Pin
Richard MacCutchan25-Jun-13 21:56
mveRichard MacCutchan25-Jun-13 21:56 
GeneralRe: Upload file using C# Windows service application Pin
susanna.floora25-Jun-13 22:00
susanna.floora25-Jun-13 22:00 
GeneralRe: Upload file using C# Windows service application Pin
Richard MacCutchan25-Jun-13 22:26
mveRichard MacCutchan25-Jun-13 22:26 
AnswerRe: Upload file using C# Windows service application Pin
Bernhard Hiller25-Jun-13 22:10
Bernhard Hiller25-Jun-13 22:10 
GeneralRe: Upload file using C# Windows service application Pin
susanna.floora26-Jun-13 0:42
susanna.floora26-Jun-13 0:42 
QuestionMicrosoft Bug Reporting Tool for VS 2012 Pin
Bram van Kampen25-Jun-13 15:13
Bram van Kampen25-Jun-13 15:13 
AnswerRe: Microsoft Bug Reporting Tool for VS 2012 Pin
Ron Beyer25-Jun-13 16:06
professionalRon Beyer25-Jun-13 16:06 
QuestionWindows Service Design - connection pool Pin
nlarson1125-Jun-13 11:52
nlarson1125-Jun-13 11:52 
AnswerRe: Windows Service Design - connection pool Pin
Eddy Vluggen25-Jun-13 23:23
professionalEddy Vluggen25-Jun-13 23:23 
GeneralRe: Windows Service Design - connection pool Pin
nlarson1126-Jun-13 4:40
nlarson1126-Jun-13 4:40 
QuestionRe: Windows Service Design - connection pool Pin
Eddy Vluggen26-Jun-13 7:37
professionalEddy Vluggen26-Jun-13 7:37 
AnswerRe: Windows Service Design - connection pool Pin
nlarson1126-Jun-13 8:48
nlarson1126-Jun-13 8:48 
GeneralRe: Windows Service Design - connection pool Pin
Eddy Vluggen26-Jun-13 23:36
professionalEddy Vluggen26-Jun-13 23:36 
QuestionTree View in List View control Pin
Jai Deo Tiwari25-Jun-13 5:22
Jai Deo Tiwari25-Jun-13 5:22 
AnswerRe: Tree View in List View control Pin
Ingo25-Jun-13 6:27
Ingo25-Jun-13 6:27 
QuestionAuthentication to IP-Cam for streaming Pin
Nick_Frenk24-Jun-13 23:36
Nick_Frenk24-Jun-13 23:36 
SuggestionRe: Authentication to IP-Cam for streaming Pin
Richard MacCutchan25-Jun-13 0:40
mveRichard MacCutchan25-Jun-13 0:40 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.