Click here to Skip to main content
15,903,724 members
Home / Discussions / C#
   

C#

 
Questionignore special chars in string Pin
michaelgr130-May-10 7:11
michaelgr130-May-10 7:11 
AnswerRe: ignore special chars in string Pin
Hamed Musavi30-May-10 7:14
Hamed Musavi30-May-10 7:14 
AnswerRe: ignore special chars in string Pin
Abhinav S30-May-10 7:31
Abhinav S30-May-10 7:31 
GeneralRe: ignore special chars in string Pin
yu-jian30-May-10 15:06
yu-jian30-May-10 15:06 
AnswerRe: ignore special chars in string Pin
Abhinav S30-May-10 18:25
Abhinav S30-May-10 18:25 
GeneralRe: ignore special chars in string Pin
yu-jian31-May-10 1:38
yu-jian31-May-10 1:38 
QuestionCopy Excel columns or rows into an Array in C sharp programme Pin
Kutilya30-May-10 0:47
Kutilya30-May-10 0:47 
AnswerRe: Copy Excel columns or rows into an Array in C sharp programme Pin
Garth J Lancaster30-May-10 1:33
professionalGarth J Lancaster30-May-10 1:33 
AnswerRe: Copy Excel columns or rows into an Array in C sharp programme Pin
Richard MacCutchan30-May-10 1:57
mveRichard MacCutchan30-May-10 1:57 
QuestionCrystal Report Giving Error At Runtime Pin
Sanket.Patil29-May-10 23:30
Sanket.Patil29-May-10 23:30 
AnswerRe: Crystal Report Giving Error At Runtime Pin
Abhinav S29-May-10 23:57
Abhinav S29-May-10 23:57 
GeneralRe: Crystal Report Giving Error At Runtime Pin
Sanket.Patil30-May-10 0:11
Sanket.Patil30-May-10 0:11 
GeneralRe: Crystal Report Giving Error At Runtime Pin
Abhinav S30-May-10 3:02
Abhinav S30-May-10 3:02 
QuestionOOPS Pin
NetQuestions29-May-10 21:43
NetQuestions29-May-10 21:43 
AnswerRe: OOPS Pin
Richard MacCutchan29-May-10 21:45
mveRichard MacCutchan29-May-10 21:45 
AnswerRe: OOPS Pin
Md. Marufuzzaman29-May-10 22:40
professionalMd. Marufuzzaman29-May-10 22:40 
AnswerRe: OOPS Pin
Abhinav S29-May-10 23:13
Abhinav S29-May-10 23:13 
AnswerRe: OOPS PinPopular
Luc Pattyn30-May-10 2:47
sitebuilderLuc Pattyn30-May-10 2:47 
GeneralRe: OOPS Pin
NetQuestions1-Jun-10 20:06
NetQuestions1-Jun-10 20:06 
QuestionHow to write a utf8 string in a unicode text file using c#? Pin
svt gdwl29-May-10 18:49
svt gdwl29-May-10 18:49 
AnswerRe: How to write a utf8 string in a unicode text file using c#? Pin
Abhinav S29-May-10 21:15
Abhinav S29-May-10 21:15 
AnswerRe: How to write a utf8 string in a unicode text file using c#? Pin
Luc Pattyn30-May-10 2:06
sitebuilderLuc Pattyn30-May-10 2:06 
QuestionDisplay multiple images Pin
ruknil29-May-10 7:49
ruknil29-May-10 7:49 
I need to display multiple images from a folder by using four image boxes.
The pictures should display according to change. I was put "FileSystemWatcher" to identify the file change and display images according to that. but when execution it does't go inside the "public void OnChanged" function.
but no image will display.

does anyone know how to solve this issue. or any other method for display latest four images from a folder..

Thank you.

This is my code

public partial class Form1 : Form<br />
    {<br />
        FileSystemWatcher watcher = new FileSystemWatcher();<br />
<br />
        public Form1()<br />
        {<br />
<br />
            InitializeComponent();<br />
<br />
            watcher.Path = @"f:\My FYP\FYP_Update 2.1\New_Traffic_Pics";<br />
            watcher.Created += new FileSystemEventHandler(OnChanged);<br />
            LoadLatestImage();<br />
            <br />
        }<br />
<br />
        public void LoadLatestImage()<br />
        {<br />
            <br />
            <br />
        <br />
            watcher.NotifyFilter = NotifyFilters.LastWrite;<br />
           <br />
            watcher.Filter = "*.jpg";<br />
                        <br />
  <br />
        }<br />
<br />
        public void OnChanged(object source, FileSystemEventArgs e)<br />
        {<br />
            pictureBox1.ImageLocation = e.FullPath;<br />
        }<br />
<br />
<br />
        private void Form1_Load(object sender, EventArgs e)<br />
        {<br />
            <br />
        }<br />
<br />
        private void pictureBox1_Click(object sender, EventArgs e)<br />
        {<br />
            <br />
        }<br />
<br />
        private void timer1_Tick(object sender, EventArgs e)<br />
        {<br />
            LoadLatestImage();<br />
        }<br />
<br />
       <br />
    }

AnswerRe: Display multiple images Pin
Luc Pattyn29-May-10 10:07
sitebuilderLuc Pattyn29-May-10 10:07 
AnswerRe: Display multiple images Pin
#realJSOP30-May-10 0:33
professional#realJSOP30-May-10 0:33 

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.