|
Tarakeshwar Reddy wrote: I would say that, your option of SingleBroadcast to all connected clients would give you the simultaneous broadcast to all the clients. OPC actually checks for all the clients connected and the items subscribed by the client and then send the required data, this would mean some lag of 1/1000 second or even lesser.
Thanks for pointing this out, because it was not evident from the documentation I saw.
As to the "virtually simultaneous" requirement, these people are far from meeting their goal. Achieving the best practical performance subject to the limitations of such a process is as good as it's going to get for them, so that's what I'm interested in establishing. I haven't seen their code yet, so I don't know what they're doing. I assume their poor performance is a consequence of a fundamental problem such as mis-use of TCP/IP. They're having great trouble supporting a handful of clients.
I did find some interesting OPC components, and may write the company to determine if they can solve the problem if it looks like we can't solve the problem ourselves. Except perhaps for the number of clients, it seems this should be relatively simple, and that we should be able to avoid layering such substantial technology over such a simple application.
|
|
|
|
|
Well - this could be a candidate for Sql Notification Services. Basically, you would have your applications register their interest in the data and then the update would be triggered at point A. Mind you, you are going to have a fun job updating that many clients "simultaneously".
Deja View - the feeling that you've seen this post before.
|
|
|
|
|
This was one of my initial suggestions to these people -- the reservation being whether the underlying process can do the job better than a minimalized process we can write ourselves. I would think that to achieve best possible speed, we need to be able to spin off separate threads of execution to handle each callback. Each succeding broadcast then would not have to wait for conclusion of the preceding. Because the few threads available to the .NET thread pool would seem to preclude much advantage from multi-threading in a .NET server implementation, I was hoping that some "easy" integration of an RDBMS might circumvent the minimal available threads of the the thread pool. Is there an RDBMS you might recommend for being particularly strong in this area -- a good candidate for this job?
|
|
|
|
|
Well, we've had some success in this area with SQL Server 2005 and Notification Services. To be honest, MS has invested a lot of money in this technology and done a lot of work on it to ensure its robustness. To get this level of robustness/concurrency in custom code you are going to have to do a lot of work that has already been done for you, and you will have to do an amazing amount of testing.
Deja View - the feeling that you've seen this post before.
|
|
|
|
|
I'll take your advice quite seriously.
Thanks a bunch, Pete. I appreciate it.
|
|
|
|
|
No problem. I'm glad to help.
Deja View - the feeling that you've seen this post before.
|
|
|
|
|
Hi friends,
I have seen something like below in a resource file. Can somebody tell me what is (.)dot notation for.
Name: Value
myButton.Label SubmitButon
Thanks
|
|
|
|
|
The dot signifies an object's member (property, field, method, etc.). The statement would imply the Label property of the myButton object is "SubmitButton".
/ravi
|
|
|
|
|
Thanks for replying. But then how comes in the code when i type name of the resource file i do see this myResource.myButton_Label
|
|
|
|
|
netJP12L wrote: Thanks for replying. But then how comes in the code when i type name of the resource file i do see this myResource.myButton_Label
The code you are seeing (myResource.myButton_Label ) is accessing the string resource through the resource class that Visual Studio auto-generates for you. The auto-generation translates the "." in the resource name to an "_" to make it a legal C# property name.
-----------------------------
In just two days, tomorrow will be yesterday.
|
|
|
|
|
I know how to send a service a command using the ExecuteCommand but i'm wanting to recieve a response back to the client. Any Ideas?
Thanks
Don't be overcome by evil, but overcome evil with good
|
|
|
|
|
I want to write in a Xml file some data, but I have an error because I have the same attribute "ClusterRoute" who appears many times.
XmlTextWriter myXmlTextWriter = new XmlTextWriter(@"c:\\Results.xml", Encoding.UTF8);
myXmlTextWriter.WriteStartDocument();
for (int i = 0; i < clustersList.Count; i++)
{
myXmlTextWriter.WriteStartElement("Clusters");
for (int j = 0; j < clustersList[i].Count; j++)
{
myXmlTextWriter.WriteAttributeString("ClusterRoute", clustersList[i][j].CityID.ToString());
}
myXmlTextWriter.WriteEndElement();
}
myXmlTextWriter.WriteEndDocument();
|
|
|
|
|
you can only have on instance of an attribute per element. That is just how XML works.
led mike
|
|
|
|
|
Hello everyone,
I am using a DataGridView control to display data which is stored in a remote database server. Using filter, I am trying to get the rows of information that I am looking for in the dataset. I was wondering if it is possible to get the data in a specific column/cell rather than the entire data in the row?
The following is the code that I am using for filtering the data in the DataGridView control.
string strText;<br />
string strExpr;<br />
string strSort;<br />
DataRow[] foundRows;<br />
<br />
strExpr = "shop_id >= '4' AND shop_id <= '7'";<br />
strSort = "shop_id ASC";<br />
<br />
foundRows = myTable.Select(strExpr, strSort);<br />
<br />
strText = null;<br />
for (int i = 0; i <= foundRows.GetUpperBound(0); i++)<br />
{<br />
for (int j = 0; j <= foundRows[i].ItemArray.GetUpperBound(0); j++)<br />
{<br />
strText = strText + foundRows[i][j].ToString() + "\t";<br />
}<br />
strText = strText + "\r\n";<br />
textBox.Text = strText;<br />
}
Thank you very much and have a great day.
Khoramdin
-- modified at 11:03 Thursday 10th May, 2007
|
|
|
|
|
You should go look at the C# Articles to get a handle on what you are doing, you are way off base.
led mike
|
|
|
|
|
Hello mike,
Thank you very much for your respond. You could be absolutely correct regarding my approach. But could you be kind enough to tell me where I need to start and what is the right approach? Then I will be able to narrow down my search and find the right approach.
Believe it or not, but I found that approach after reading number of C# articles. I am sure you agree with me when I say there are all sort of articles online. The problem is to find the right one and in order to find the right one I need to have the knowledge to assess the articles. But the point is, if I have the knowledge to make such a distinction then I have reached the level of knowledge that I won't be needing such articles!
Thank you very much and have a great day.
Khoramdin
|
|
|
|
|
Well I meant the C# Database Articles here on CodeProject, try this one[^]
led mike
|
|
|
|
|
Hello mike,
Thanx for the help mate.
Have a great day.
Khoramdin
|
|
|
|
|
Hi,
I need to move(change Location and Z-order) of a window (which is not focused) without activating it. Sometimes the form is on background.
For that, I use :
<br />
[DllImport("user32.dll")]<br />
public static extern int SetWindowPos(IntPtr hWnd, IntPtr hWndInsertAfter, Int32 x, Int32 y, Int32 cx, Int32 cy, Int32 flags);
that works fine, but sometimes it fails. Every time I need to move that specified window (particulary change position and z-order) , i do it like :
Win32Native.SetWindowPos(this.Handle, parentHandle, newPosition.X, newPosition.Y, 0, 0,<br />
(int)Win32Native.SetWindowPosOptions.SWP_NOSIZE |<br />
(int)Win32Native.SetWindowPosOptions.SWP_NOACTIVATE);
Where:
parentHandle - Handle of window that should be (is) allways right behind this window.
newPosition - correctly calculated new desktop position.
Win32Native is my custom class with many user32.dll and other methods, enumerations, structures etc...
I've also tried to put
Win32Native.SetWindowPos(this.Handle, parentHandle, 0, 0, 0, 0,<br />
(int)(Win32Native.SetWindowPosOptions.SWP_FRAMECHANGED |<br />
Win32Native.SetWindowPosOptions.SWP_NOSIZE | <br />
Win32Native.SetWindowPosOptions.SWP_NOZORDER | <br />
Win32Native.SetWindowPosOptions.SWP_NOACTIVATE |<br />
Win32Native.SetWindowPosOptions.SWP_NOMOVE));
and
Application.DoEvents();
right behind, but it didn't help too. It works fine when the parent window (the window thats always right behind this window) is active, but as soon as it is not active (focused), it starts to fail changing this window position.
Do you have any idea why?
|
|
|
|
|
Are you gettng any error codes back? Have you checked GetLastWin32Error[^]? If the call fails, an error code should come back. Look up the error code and see what went wrong.
|
|
|
|
|
That's funny, it always returns 0 == no error occured.
|
|
|
|
|
What happens if you call this function with the same arguments and for the same window but from a c++ program?
|
|
|
|
|
Hi,
I haven't tried that but I can't see the purpose here. Why would I do that? Even if it worked, how would it help in my situation? Are you trying to say that I should write a dll in C++ , import it to C# ...
|
|
|
|
|
Hi all,
I am doing an Day planner using c#.net and MS.ACCESS. My query is how to compare two dates excluding the seconds in c#.
For eg:
Datetime time1 = convert.ToDateTime("06:12:45");
Datetime time2 = convert.ToDateTime("09:25:09");
DateTime.Compare(time1,time2);
In the above i wish to compare time excluding the seconds in both the time format.
Plz any one help, it's urgent
Thanks in advance
Know is Drop, Unknown is Ocean
|
|
|
|
|
If you read the documentation you'll see that DateTime has the following properties and methods:
* Second[^]
* AddSeconds[^] (hint: add a negative number of seconds)
|
|
|
|