Click here to Skip to main content
15,889,335 members
Home / Discussions / C#
   

C#

 
AnswerRe: how to delete a row in database Pin
Hamid_RT18-Sep-06 9:30
Hamid_RT18-Sep-06 9:30 
QuestionAdding Child Controls to UserControl at design time Pin
TofuBug2417-Sep-06 19:34
TofuBug2417-Sep-06 19:34 
AnswerRe: Adding Child Controls to UserControl at design time Pin
Martin#17-Sep-06 21:22
Martin#17-Sep-06 21:22 
GeneralRe: Adding Child Controls to UserControl at design time Pin
TofuBug2418-Sep-06 1:22
TofuBug2418-Sep-06 1:22 
QuestionDeleting a file Pin
saqib8217-Sep-06 19:27
saqib8217-Sep-06 19:27 
AnswerRe: Deleting a file Pin
Jakob Farian Krarup17-Sep-06 19:54
Jakob Farian Krarup17-Sep-06 19:54 
GeneralRe: Deleting a file Pin
Christian Graus17-Sep-06 20:22
protectorChristian Graus17-Sep-06 20:22 
GeneralRe: Deleting a file Pin
Jakob Farian Krarup17-Sep-06 21:26
Jakob Farian Krarup17-Sep-06 21:26 
Hehe... that's what you get for replying to a forum post before the first cup'o'mocca in the morning Smile | :)

You're right of course Wink | ;-)

Corrected code reads:
using System;
using System.IO;
namespace Testing{  
  public class Test
  {
    public static void Main()
    {
      FileStream fs = null;
      try
      {
        fs = new FileStream(@"c:\test.txt", FileMode.Create);
        byte[] content =  new System.Text.UTF8Encoding(true).GetBytes("Hi there!");
        fs.Write(content, 0, 9);
      }
      catch (IOException ioe)
      {
        Console.WriteLine("Something happened");
      }
      finally
      {
        if(fs != null)
          fs.Close();
      }
    }
  }
}



Thx for the correction Christian!

Kind regards - Jakob Cool | :cool:
*********************************************
Three kinds of people in the world:
- Those who can count..
- Those who can't!

10 kinds of people in the world:
- Those who understand binary
- Those who don't

GeneralRe: Deleting a file Pin
saqib8217-Sep-06 20:51
saqib8217-Sep-06 20:51 
GeneralRe: Deleting a file Pin
Jakob Farian Krarup17-Sep-06 21:27
Jakob Farian Krarup17-Sep-06 21:27 
QuestionMobile projects in C# Pin
yousafzai17-Sep-06 19:17
yousafzai17-Sep-06 19:17 
AnswerRe: Mobile projects in C# Pin
Jakob Farian Krarup17-Sep-06 19:34
Jakob Farian Krarup17-Sep-06 19:34 
QuestionFile Transfer Pin
Madhumathiid17-Sep-06 18:45
Madhumathiid17-Sep-06 18:45 
AnswerRe: File Transfer Pin
Jakob Farian Krarup17-Sep-06 19:25
Jakob Farian Krarup17-Sep-06 19:25 
QuestionXML parsing in c# Pin
aruna_koride17-Sep-06 17:07
aruna_koride17-Sep-06 17:07 
AnswerRe: XML parsing in c# Pin
Bob Nadler18-Sep-06 17:30
Bob Nadler18-Sep-06 17:30 
QuestionRe: XML parsing in c# Pin
aruna_koride18-Sep-06 18:32
aruna_koride18-Sep-06 18:32 
QuestionMainForm not here for working in Code? Pin
xenotronic00717-Sep-06 15:38
xenotronic00717-Sep-06 15:38 
AnswerRe: MainForm not here for working in Code? Pin
Christian Graus17-Sep-06 15:48
protectorChristian Graus17-Sep-06 15:48 
GeneralRe: MainForm not here for working in Code? Pin
xenotronic00718-Sep-06 13:25
xenotronic00718-Sep-06 13:25 
GeneralRe: MainForm not here for working in Code? Pin
Christian Graus18-Sep-06 13:45
protectorChristian Graus18-Sep-06 13:45 
QuestionAdd LinkLabel to panal Pin
Muller217-Sep-06 7:38
Muller217-Sep-06 7:38 
AnswerRe: Add LinkLabel to panal Pin
Stefan Troschuetz17-Sep-06 8:18
Stefan Troschuetz17-Sep-06 8:18 
QuestionList collection all elements the same! Help! Pin
TommySu17-Sep-06 7:26
TommySu17-Sep-06 7:26 
AnswerRe: List collection all elements the same! Help! Pin
Stefan Troschuetz17-Sep-06 8:09
Stefan Troschuetz17-Sep-06 8:09 

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.