473,738 Members | 8,848 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

real time status

To all,

Not sure on how to approach this but what would be the best practice in
showing status of a query that does an aggregation or count of some sort. if
I were to have a sql statement that does select count(c1) from t1 how would I
be able to show a green, yellow or red light type object that uses my query
to determine a threshold. For example, if my count query went up to 85 then
show red, between 75 to 85 show yellow, between 65 to 75 show green on an
object that would be displayed in a VB.NET web form.

Thanks for any advice,
Michael
Feb 19 '07 #1
5 1140
Hello Michael,

Did you execute the query with a DataCommand or DataAdapter? You may fill
the result into a dataset/datatable. And then put a Label control on the
web form. We can set the Label web control's ForeColor property on based on
result in the dataset, for example:

Label1.ForeColo r =System.Drawing .Color.Red

Hope this help,

Sincerely,

Luke Zhang

Microsoft Online Community Support
=============== =============== =============== =====
Get notification to my posts through email? Please refer to
http://msdn.microsoft.com/subscripti...ult.aspx#notif
ications.

Note: The MSDN Managed Newsgroup support offering is for non-urgent issues
where an initial response from the community or a Microsoft Support
Engineer within 1 business day is acceptable. Please note that each follow
up response may take approximately 2 business days as the support
professional working with you may need further investigation to reach the
most efficient resolution. The offering is not appropriate for situations
that require urgent, real-time or phone-based interactions or complex
project analysis and dump analysis issues. Issues of this nature are best
handled working with a dedicated Microsoft Support Engineer by contacting
Microsoft Customer Support Services (CSS) at
http://msdn.microsoft.com/subscripti...t/default.aspx.
=============== =============== =============== =====

This posting is provided "AS IS" with no warranties, and confers no rights.

Feb 20 '07 #2
Luke,

Thanks for the response. I can certainly can use this code but would I have
to add another control that would be used to post back and get the latest
count from my sql count query? Such as using a button to fill my dataset
again with the latest information from my count query? I would like to see
the label1 control automatically turn colors without a user having to push a
button control to populate the dataset.

Thanks for any help,
Michael

"Luke Zhang [MSFT]" wrote:
Hello Michael,

Did you execute the query with a DataCommand or DataAdapter? You may fill
the result into a dataset/datatable. And then put a Label control on the
web form. We can set the Label web control's ForeColor property on based on
result in the dataset, for example:

Label1.ForeColo r =System.Drawing .Color.Red

Hope this help,

Sincerely,

Luke Zhang

Microsoft Online Community Support
=============== =============== =============== =====
Get notification to my posts through email? Please refer to
http://msdn.microsoft.com/subscripti...ult.aspx#notif
ications.

Note: The MSDN Managed Newsgroup support offering is for non-urgent issues
where an initial response from the community or a Microsoft Support
Engineer within 1 business day is acceptable. Please note that each follow
up response may take approximately 2 business days as the support
professional working with you may need further investigation to reach the
most efficient resolution. The offering is not appropriate for situations
that require urgent, real-time or phone-based interactions or complex
project analysis and dump analysis issues. Issues of this nature are best
handled working with a dedicated Microsoft Support Engineer by contacting
Microsoft Customer Support Services (CSS) at
http://msdn.microsoft.com/subscripti...t/default.aspx.
=============== =============== =============== =====

This posting is provided "AS IS" with no warranties, and confers no rights.

Feb 20 '07 #3
Hello,

Did you want the page be refreshed automatically? You may put following
line at the head of ASPX page:

<meta http-equiv="refresh" content="5" >

In this way, the page will be refreshed in every 5 seconds. And then, you
may add the code about fill the dataset and change the label in Page_Load()
method, so that they can be executed when the page is refreshed.

Sincerely,

Luke Zhang

Microsoft Online Community Support
=============== =============== =============== =====
Get notification to my posts through email? Please refer to
http://msdn.microsoft.com/subscripti...ult.aspx#notif
ications.

Note: The MSDN Managed Newsgroup support offering is for non-urgent issues
where an initial response from the community or a Microsoft Support
Engineer within 1 business day is acceptable. Please note that each follow
up response may take approximately 2 business days as the support
professional working with you may need further investigation to reach the
most efficient resolution. The offering is not appropriate for situations
that require urgent, real-time or phone-based interactions or complex
project analysis and dump analysis issues. Issues of this nature are best
handled working with a dedicated Microsoft Support Engineer by contacting
Microsoft Customer Support Services (CSS) at
http://msdn.microsoft.com/subscripti...t/default.aspx.
=============== =============== =============== =====

This posting is provided "AS IS" with no warranties, and confers no rights.

Feb 22 '07 #4
Thank you Luke! You are a star! Is it possible to make just the control
update every 5 seconds? I'm assuming this is where I would use ajax? Then I
would have the ajax control update five seconds.

Thanks,
Michael

"Luke Zhang [MSFT]" wrote:
Hello,

Did you want the page be refreshed automatically? You may put following
line at the head of ASPX page:

<meta http-equiv="refresh" content="5" >

In this way, the page will be refreshed in every 5 seconds. And then, you
may add the code about fill the dataset and change the label in Page_Load()
method, so that they can be executed when the page is refreshed.

Sincerely,

Luke Zhang

Microsoft Online Community Support
=============== =============== =============== =====
Get notification to my posts through email? Please refer to
http://msdn.microsoft.com/subscripti...ult.aspx#notif
ications.

Note: The MSDN Managed Newsgroup support offering is for non-urgent issues
where an initial response from the community or a Microsoft Support
Engineer within 1 business day is acceptable. Please note that each follow
up response may take approximately 2 business days as the support
professional working with you may need further investigation to reach the
most efficient resolution. The offering is not appropriate for situations
that require urgent, real-time or phone-based interactions or complex
project analysis and dump analysis issues. Issues of this nature are best
handled working with a dedicated Microsoft Support Engineer by contacting
Microsoft Customer Support Services (CSS) at
http://msdn.microsoft.com/subscripti...t/default.aspx.
=============== =============== =============== =====

This posting is provided "AS IS" with no warranties, and confers no rights.

Feb 22 '07 #5
Hello Michael,

I am not a professional of ajax, but I think it is positive that there is
an ajax control can do this. If you want to implement this with ajax, you
post this issue in

microsoft.publi c.dotnet.framew ork.aspnet

To see if some one there can help on this.

Sincerely,

Luke Zhang

Microsoft Online Community Support
=============== =============== =============== =====
Get notification to my posts through email? Please refer to
http://msdn.microsoft.com/subscripti...ult.aspx#notif
ications.

Note: The MSDN Managed Newsgroup support offering is for non-urgent issues
where an initial response from the community or a Microsoft Support
Engineer within 1 business day is acceptable. Please note that each follow
up response may take approximately 2 business days as the support
professional working with you may need further investigation to reach the
most efficient resolution. The offering is not appropriate for situations
that require urgent, real-time or phone-based interactions or complex
project analysis and dump analysis issues. Issues of this nature are best
handled working with a dedicated Microsoft Support Engineer by contacting
Microsoft Customer Support Services (CSS) at
http://msdn.microsoft.com/subscripti...t/default.aspx.
=============== =============== =============== =====

This posting is provided "AS IS" with no warranties, and confers no rights.

Feb 23 '07 #6

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

Similar topics

0
1176
by: Ken | last post by:
Hi. I was trying to find out what the status is for the Distributed Real-Time Specification for Java (JSR-050). Seems like there's info out there that goes to 2002 and then stops (see www.drtsj.org). Is there still work being done on this spec? Is there a draft of the spec or one coming soon? Any idea when a final version might be done? Thanks! Ken
18
12591
by: Ken | last post by:
Hi. Can anyone refer me to any articles about the compatibility between c++ polymorphism and real-time programming? I'm currently on a real-time c++ project, and we're having a discussion about whether we should allow polymorphism. Our system is not embedded and does not need to be as real-time as, say, a pacemaker. But it does involve updating displays based on radar input. So a need for something close to real-time is desired...
77
4596
by: Charles Law | last post by:
Hi guys I have a time critical process, running on a worker thread. By "time critical", I mean that certain parts of the process must be completed in a specific time frame. The time when the process starts is not especially important, but it must be complete within a small number of seconds. The operations I am performing do not take a long time (hundreds of milliseconds), but as each part of the process is complete, my worker thread...
1
2158
by: anthony hanson | last post by:
I am trying to write a stored proc the calculates a moving average over three periods. In the following example, I need to stratify the data by personID and RecordID in the #Temp table, but I am not sure how to do it. Right now I am restricting the data I use to build my time series by personID and I get the results I want *by PersonID*. If I can figure out how stratify by personID so I don't have to use this restriction, I'm sure I can...
4
3853
by: Frank Meng | last post by:
Hi. I am trying a csharp sample from http://www.codeproject.com/csharp/socketsincs.asp . (Sorry I didn't post all the source codes here, please get the codes from above link if you want to try). I had some troubles when I started 6 threads (each thread made a separate connection) and sent messages to same server simultaneously. Sometimes, not always, the socket looks like ok, but really it is dead. I don't why it happens.
21
16590
by: rdemyan via AccessMonster.com | last post by:
Is there a way to get the internet date/time. I saw an article that uses WinSock, but WinSock doesn't seem to be available in Access. I want to verify that the date/time on the local PC running my application is correct, so I was hoping I could get the Internet date/time. I understand that there is a NTP protocol to do this. Thanks. --
0
1147
by: tanmay79 | last post by:
Hi, I am currently developing a travel website (C#) where multiple agents book seats online using a graphical view of seats where the availability of seats must be updated in real time as and when they are booked by different agents. The seats booked are stored in a table in a database. The graphic displays seats available in green and reserved in red, but how do I display in realtime the status turning a particular seat red as soon as it...
3
3298
by: SimonPlatten | last post by:
Hi, I'm a software engineer working in the offshore industry, I've been coding in various languages professionally since 1987. In my present employment I am working with control systems in the oil and gas industry. Typically control systems use process control or scada systems to display and log data from various control environments. I am designing an Intranet using AJAX to acquire data from remote servers and present dynamic updates...
2
2577
by: Dale | last post by:
Access 2003 I have an access database used for scoring a high school sporting event. Data is entered as scores are turned in from the different events throughout the day. I would like to display data via multi-media projector in real time, so students & teams know thier status at all times. I am open to ideas about how to achieve this. I have tried reports
0
8969
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
8788
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
9476
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
9208
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
0
8210
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
6751
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
6053
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
4825
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
3279
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

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.