Click here to Skip to main content
15,923,222 members
Home / Discussions / C#
   

C#

 
QuestionRTF Formatting in C# Pin
allenmpcx30-Dec-05 9:06
allenmpcx30-Dec-05 9:06 
QuestionMail under Visual Studio 2005 Pin
Tyler4530-Dec-05 8:32
Tyler4530-Dec-05 8:32 
AnswerRe: Mail under Visual Studio 2005 Pin
Tyler4531-Dec-05 7:24
Tyler4531-Dec-05 7:24 
QuestionThreading, Suspend() Pin
tray_gator30-Dec-05 7:40
tray_gator30-Dec-05 7:40 
AnswerRe: Threading, Suspend() Pin
Judah Gabriel Himango30-Dec-05 8:08
sponsorJudah Gabriel Himango30-Dec-05 8:08 
GeneralRe: Threading, Suspend() Pin
Jared Parsons30-Dec-05 9:33
Jared Parsons30-Dec-05 9:33 
GeneralRe: Threading, Suspend() Pin
Judah Gabriel Himango30-Dec-05 9:44
sponsorJudah Gabriel Himango30-Dec-05 9:44 
GeneralRe: Threading, Suspend() Pin
tray_gator30-Dec-05 10:07
tray_gator30-Dec-05 10:07 
First of all, thank You very much for your answer. I've understood how to pause a thread, but now I don't understand how to show a form Smile | :) (before: form showed only after thread was finished).
I have a form "mainForm" with button. When I click button: thread "fP" starts.
Button event:
private void fileProccessing_Click(object obj, EventArgs ea)
{
       fP = new Thread(new ThreadStart(fProc));
       fP.Start();
}


Thread:
public void fProc()
{      
       editForm edtFrm = new editForm(); // this Form I want to show
       ...someText...
       if( ... )
       {
            edtFrm.Show(); // so I try to show the form
            edtFrm.cmbBox.DataSource = fieldsBaseD; // bind array to comboBox in this editForm
            
            while (edtFrm.Visible == true)
            {
                Thread.Sleep(0);
            }
       }

}


And in another file I have second form "editForm" (which I want to show)
class editForm : Form
{
    public ComboBox cmbBox;
    private Button buttonOk;
    public Label label1;

    public editForm()
    {
        InitializeComponent();
    }
    
    .... // InitializeComponent function
}


but thats dont work... it tries to show a form and programm becomes to not responding Frown | :(
GeneralRe: Threading, Suspend() Pin
Jared Parsons30-Dec-05 10:30
Jared Parsons30-Dec-05 10:30 
GeneralRe: Threading, Suspend() Pin
tray_gator30-Dec-05 10:44
tray_gator30-Dec-05 10:44 
QuestionI know this noob but.. Pin
wednesday™ -LJX-30-Dec-05 7:29
wednesday™ -LJX-30-Dec-05 7:29 
AnswerRe: I know this noob but.. Pin
Drew McGhie30-Dec-05 8:14
Drew McGhie30-Dec-05 8:14 
AnswerRe: I know this noob but.. Pin
Xodiak30-Dec-05 8:16
Xodiak30-Dec-05 8:16 
QuestionStructure/Memory Question Pin
bpreston30-Dec-05 7:11
bpreston30-Dec-05 7:11 
AnswerRe: Structure/Memory Question Pin
Judah Gabriel Himango30-Dec-05 8:14
sponsorJudah Gabriel Himango30-Dec-05 8:14 
GeneralRe: Structure/Memory Question Pin
Jared Parsons30-Dec-05 9:43
Jared Parsons30-Dec-05 9:43 
GeneralRe: Structure/Memory Question Pin
Judah Gabriel Himango30-Dec-05 9:50
sponsorJudah Gabriel Himango30-Dec-05 9:50 
GeneralRe: Structure/Memory Question Pin
Jared Parsons30-Dec-05 10:15
Jared Parsons30-Dec-05 10:15 
GeneralRe: Structure/Memory Question Pin
bpreston30-Dec-05 11:15
bpreston30-Dec-05 11:15 
QuestionCan´t print multiple pages in C# Pin
naglbitur30-Dec-05 6:48
naglbitur30-Dec-05 6:48 
AnswerRe: Can´t print multiple pages in C# Pin
Brian Van Beek30-Dec-05 6:52
Brian Van Beek30-Dec-05 6:52 
QuestionCna't Write To Hard Disk .Net 1.1 Sercurity Problem Pin
half_ex30-Dec-05 6:14
half_ex30-Dec-05 6:14 
AnswerRe: Cna't Write To Hard Disk .Net 1.1 Sercurity Problem Pin
Jared Parsons30-Dec-05 10:09
Jared Parsons30-Dec-05 10:09 
GeneralRe: Cna't Write To Hard Disk .Net 1.1 Sercurity Problem Pin
half_ex31-Dec-05 6:56
half_ex31-Dec-05 6:56 
GeneralRe: Cna't Write To Hard Disk .Net 1.1 Sercurity Problem Pin
half_ex1-Jan-06 7:16
half_ex1-Jan-06 7:16 

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.