473,804 Members | 2,116 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

how can i make a background thread ??

jam
dear all,

could anyone help me about telling me how can i make a background thread
displaying loading... when I cam calling a console application??

thanks..

jam
Nov 16 '05 #1
2 5471
Hi,

I guess you just want to perform a long-running operation in the background
and display notification to the user on the progress.

For this you could go for threading, asynchronous method invocation, or the
BackgroundWorke r component (Whidbey).

Heres the overview of async calls
http://msdn.microsoft.com/library/en...ngOverview.asp

Threading basics
http://msdn.microsoft.com/library/en...dingbasics.asp

Whibey's BackgroundWorke r component:
http://www.codeproject.com/csharp/backgroundworker.asp

HTH,
Rakesh Rajan

"jam" wrote:
dear all,

could anyone help me about telling me how can i make a background thread
displaying loading... when I cam calling a console application??

thanks..

jam

Nov 16 '05 #2
Hi,

You declare a thread as background setting Thread.IsBackgr ound to true.
what you want is a little different and more complex , IIRC this was
discussed like two weeks ago, how to have a progress bar active while the
background thread perform a lenthly operation.
Do a search in google
Cheers,

--
Ignacio Machin,
ignacio.machin AT dot.state.fl.us
Florida Department Of Transportation

"jam" <hk***@hotmail. com> wrote in message
news:eE******** ******@TK2MSFTN GP10.phx.gbl...
dear all,

could anyone help me about telling me how can i make a background thread
displaying loading... when I cam calling a console application??

thanks..

jam

Nov 16 '05 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

1
323
by: Ahsan | last post by:
I have created some background threads so that when the application aborts all the threads should be automatically aborted. But the problem is that when I make a thread background thread I am unable to correctly find its thread state as the thread state property always return 12. If I make the thread foreground the thread state property works just fine. Please help me in finding the solution.
0
1656
by: Gomaw Beoyr | last post by:
Hello The book "C# Black Book" chapter about Threads says that a "background thread" cannot communicate directly with a visual element, e.g. a label, and thus has to use the BeginInvoke method, otherwise an exception will be thrown. The book also says: "Because a thread has its own process space, the addres of an object in one thread is not useful in another thread."
0
1735
by: JC Voon | last post by:
Hi All: I'm new in Threading and Web Services, can someone please verify my code, i'm not sure whether this is the correct way, althought it is partially work, but some time it will raise exception at FillDatatable dr.AcceptChanges, and also the XTraGridControl will not response when click on the column header to do sorting and filtering. What i'm trying to do is very simple, i just want to retrieve a very large table from web service...
1
1301
by: Flack | last post by:
Hey guys, Here is the scenario: I have the main form open and a background thread is running. The background thread sometimes needs access to the main forms graphics object and gets it by calling Graphics g = CreateGraphics(). Now, I close my main form while the background thread is running and when the background thread gets to the CreateGraphics() line, it throws an
1
4253
by: JEB | last post by:
I know that with Web Services, you should be doing everything in a stateless environment. However, I have three methods out of over 100 that need state. I have the client cookie container, WebMethod with Session enabled = true, the works. However, my issue is I am running logic on a background thread in a managed thread pool and I cannot access the session. I cannot pass all the data into the thread either. Is there a way to access...
33
2009
by: bonk | last post by:
I have an application that needs to perform some background work, i.e. Logging, wich must not block the main thread. How would I basically design such a scenario? It is obvious that I should do that on an extra thread but I think it is a bad idea to spawn a new thread everytime a log-message is written and let it die once the message was written. But how do I keep a thread alive and trigger the log-messages and pass the string to that...
7
10073
by: John J. Hughes II | last post by:
I have a DataGridView with a TextBoxColumn. I setting the data source to a List<stringvalue in a static class. The list is filled from a background thread. So far all is fine and it works great, at least on my system. The reason I am doing this is some customers are pulling from VPN connections which are slow. This allows the list of rows in the data grid to appear a little quicker while the list which are not used as soon load in...
8
5375
by: =?Utf-8?B?R3JlZyBMYXJzZW4=?= | last post by:
I'm trying to figure out how to modify a panel (panel1) from a backgroundworker thread. But can't get the panel to show the new controls added by the backgroundwork task. Here is my code. In this code there is a panel panel1, that I populate with a lable in the foreground. Then when I click on "button1" a backgroundworker thread in async mode is started. When the backgoundworker thread completes the thread returns a panel to populate...
4
2018
by: Claire | last post by:
Hi, I'm writing an internal mail system module for my project. There may be several thousand 'users' on site, and I need the whole list for filtering, so I decided to load up the users in the main form of the module in a background thread I used to read in this list the first time it was required, but as there's usually a "dead" period between opening the main form and actually needing the list it seemed a good idea to do it this way to...
4
1873
by: Marina Levit | last post by:
I am trying to do some processing on a background thread while keeping the UI painting. However, this is a generic server side call routine - and it needs to block until the server side call completes. So the idea is, a server side call begins, it gets spun off on another thread to keep the UI painting - but, the code flow cannot return to the caller until the server side call completes, because the caller expects the data. The only way...
0
9595
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
10354
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
1
10359
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
9177
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
1
7643
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
6870
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
5536
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
1
4314
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
3
3005
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.