Click here to Skip to main content
15,906,766 members
Home / Discussions / C#
   

C#

 
AnswerRe: Querystring needed to set to empty Pin
Coding C#12-Aug-09 21:35
Coding C#12-Aug-09 21:35 
QuestionOpen Child Form and threading Pin
Saamir12-Aug-09 3:50
Saamir12-Aug-09 3:50 
AnswerRe: Open Child Form and threading Pin
0x3c012-Aug-09 3:57
0x3c012-Aug-09 3:57 
GeneralRe: Open Child Form and threading Pin
Saamir12-Aug-09 4:05
Saamir12-Aug-09 4:05 
GeneralRe: Open Child Form and threading Pin
0x3c012-Aug-09 4:16
0x3c012-Aug-09 4:16 
GeneralRe: Open Child Form and threading Pin
Saamir12-Aug-09 4:33
Saamir12-Aug-09 4:33 
GeneralRe: Open Child Form and threading Pin
0x3c012-Aug-09 4:49
0x3c012-Aug-09 4:49 
GeneralRe: Open Child Form and threading Pin
Saamir12-Aug-09 5:27
Saamir12-Aug-09 5:27 
Pardon my ignorance as I am not the best in using threads. Currently on load of child form I am calling the runworkerasync method of the background worker with retrieves data and upon completion assigns dataset to grid and formats the grid.

Here is the change I have made and I am getting an error of cross thread operation.

worker1
Async in form load
do work retrieves data from database
Completed calls Worker2Async

Worker2
Async in Completed of Worker1
Do work assigns datagridview datasource to dataset containing data retrieve by worker1
Completed formats the grid

I am getting an error in Do work for Worker 2, when I call datagridview.datasource=dataset, it says cross thread operation... datagridview accessed from a different thread then the one it was created in... Any suggestions, am I doing what you suggested?

Please help

Sameer

GeneralRe: Open Child Form and threading Pin
Dave Kreskowiak12-Aug-09 6:23
mveDave Kreskowiak12-Aug-09 6:23 
GeneralRe: Open Child Form and threading Pin
Saamir12-Aug-09 6:51
Saamir12-Aug-09 6:51 
GeneralRe: Open Child Form and threading Pin
Luc Pattyn12-Aug-09 7:59
sitebuilderLuc Pattyn12-Aug-09 7:59 
QuestionCut,Copy ,Paste Problem... Pin
Rahul DSG12-Aug-09 3:00
Rahul DSG12-Aug-09 3:00 
AnswerRe: Cut,Copy ,Paste Problem... Pin
ricmil4212-Aug-09 3:46
ricmil4212-Aug-09 3:46 
GeneralRe: Cut,Copy ,Paste Problem... Pin
Rahul DSG12-Aug-09 18:38
Rahul DSG12-Aug-09 18:38 
GeneralRe: Cut,Copy ,Paste Problem... Pin
ricmil4213-Aug-09 3:26
ricmil4213-Aug-09 3:26 
GeneralRe: Cut,Copy ,Paste Problem... Pin
Rahul DSG22-Aug-09 3:11
Rahul DSG22-Aug-09 3:11 
GeneralRe: Cut,Copy ,Paste Problem... Pin
ricmil4224-Aug-09 3:19
ricmil4224-Aug-09 3:19 
GeneralRe: Cut,Copy ,Paste Problem... Pin
Rahul DSG30-Aug-09 18:55
Rahul DSG30-Aug-09 18:55 
AnswerRe: Cut,Copy ,Paste Problem... Pin
Andrew Rissing12-Aug-09 3:47
Andrew Rissing12-Aug-09 3:47 
QuestionConnectionString Problem with MSACCESS Pin
M Riaz Bashir12-Aug-09 2:19
M Riaz Bashir12-Aug-09 2:19 
AnswerRe: ConnectionString Problem with MSACCESS Pin
Mike Ellison12-Aug-09 2:43
Mike Ellison12-Aug-09 2:43 
AnswerRe: ConnectionString Problem with MSACCESS Pin
Luc Pattyn12-Aug-09 2:54
sitebuilderLuc Pattyn12-Aug-09 2:54 
QuestionLimit checkedListBox for maximum values [modified] Pin
bonzaiholding12-Aug-09 2:08
bonzaiholding12-Aug-09 2:08 
AnswerRe: Limit checkedListBox for maximum values Pin
Ashfield12-Aug-09 2:09
Ashfield12-Aug-09 2:09 
GeneralRe: Limit checkedListBox for maximum values Pin
bonzaiholding12-Aug-09 2:11
bonzaiholding12-Aug-09 2:11 

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.