Click here to Skip to main content
15,911,711 members
Home / Discussions / C#
   

C#

 
GeneralRe: How to receiving an incoming SMS message? in C# Pin
Christian Graus2-Jun-09 18:20
protectorChristian Graus2-Jun-09 18:20 
AnswerRe: How to receiving an incoming SMS message? in C# Pin
Giorgi Dalakishvili2-Jun-09 19:53
mentorGiorgi Dalakishvili2-Jun-09 19:53 
QuestionFastest way to scan an image for pixel color (black and white) Pin
sebogawa2-Jun-09 15:41
sebogawa2-Jun-09 15:41 
AnswerRe: Fastest way to scan an image for pixel color (black and white) Pin
Luc Pattyn2-Jun-09 15:54
sitebuilderLuc Pattyn2-Jun-09 15:54 
GeneralRe: Fastest way to scan an image for pixel color (black and white) Pin
sebogawa2-Jun-09 16:12
sebogawa2-Jun-09 16:12 
GeneralRe: Fastest way to scan an image for pixel color (black and white) Pin
Alan Balkany3-Jun-09 5:03
Alan Balkany3-Jun-09 5:03 
QuestionBottom-Up Datagrid Pin
eziksoft2-Jun-09 15:17
eziksoft2-Jun-09 15:17 
AnswerRe: Bottom-Up Datagrid Pin
Mycroft Holmes2-Jun-09 17:03
professionalMycroft Holmes2-Jun-09 17:03 
GeneralRe: Bottom-Up Datagrid Pin
eziksoft3-Jun-09 5:28
eziksoft3-Jun-09 5:28 
GeneralRe: Bottom-Up Datagrid Pin
Mycroft Holmes3-Jun-09 14:18
professionalMycroft Holmes3-Jun-09 14:18 
GeneralRe: Bottom-Up Datagrid Pin
eziksoft3-Jun-09 14:20
eziksoft3-Jun-09 14:20 
Questionabout the interface of C# Pin
mctramp1682-Jun-09 14:24
mctramp1682-Jun-09 14:24 
AnswerRe: about the interface of C# Pin
Christian Graus2-Jun-09 14:52
protectorChristian Graus2-Jun-09 14:52 
AnswerRe: about the interface of C# Pin
Richard Blythe2-Jun-09 16:15
Richard Blythe2-Jun-09 16:15 
GeneralRe: about the interface of C# Pin
EliottA3-Jun-09 2:55
EliottA3-Jun-09 2:55 
GeneralRe: about the interface of C# Pin
Richard Blythe3-Jun-09 4:51
Richard Blythe3-Jun-09 4:51 
AnswerRe: about the interface of C# Pin
Pete O'Hanlon2-Jun-09 21:41
mvePete O'Hanlon2-Jun-09 21:41 
AnswerRe: about the interface of C# Pin
Alan Balkany3-Jun-09 5:07
Alan Balkany3-Jun-09 5:07 
GeneralRe: about the interface of C# Pin
mctramp1683-Jun-09 14:37
mctramp1683-Jun-09 14:37 
Questioncross thread operations Pin
spiritboy2-Jun-09 8:58
spiritboy2-Jun-09 8:58 
QuestionRe: cross thread operations Pin
harold aptroot2-Jun-09 9:57
harold aptroot2-Jun-09 9:57 
AnswerRe: cross thread operations Pin
DaveyM692-Jun-09 9:57
professionalDaveyM692-Jun-09 9:57 
GeneralRe: cross thread operations Pin
spiritboy2-Jun-09 12:26
spiritboy2-Jun-09 12:26 
I know the Invoke procedure, but we can use Invoke when we have a Form!(Form.Invoke())
my threads are implemented in Program class where i Run my application(and there is no this.Invoke method!):

look here: my Form1 obj(f) during its lifetime will raise some events! i want to handle those events from thread2 and do the jobs in thread2!
using System;
using System.Collections.Generic;
using System.Linq;
using System.Windows.Forms;
namespace Server
{
    static class Program
    {
        static System.Threading.Thread thread2 = null;
        [STAThread]
        static void Main()
        {
            Application.EnableVisualStyles();
            Application.SetCompatibleTextRenderingDefault(false);
            Application.SetUnhandledExceptionMode(UnhandledExceptionMode.CatchException);
            Form1 f = new Form1();
            thread2 = new System.Threading.Thread(new System.Threading.ThreadStart(worker));
            thread2.IsBackground = true;
            thread2.ApartmentState = System.Threading.ApartmentState.STA;
            thread2.Start();
            try
            {
                f.job1 += new EventHandler(Job1);
                f.job2 += new EventHandler(Job2;
                f.job3 += new EventHandler(Job3);
                Application.Run(f);
            }
            catch(Exception r)
            { 
            }
        }
        static void worker()
        {
            //create a splash screen and update its progress due to events job1,job2 and job3
        }
}

GeneralRe: cross thread operations Pin
Henry Minute2-Jun-09 12:42
Henry Minute2-Jun-09 12:42 
GeneralRe: cross thread operations Pin
S. Senthil Kumar2-Jun-09 19:09
S. Senthil Kumar2-Jun-09 19: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.