|
Message Closed
modified 23-Nov-14 6:45am.
|
|
|
|
|
Hi stancrm,
Thanks for your reply... I shall try this out and get back to you...
Thanks,
Ram
|
|
|
|
|
Hi stancrm,
Just an update on this... I tried to use wirebook to get the stats and I found this out :
The request is going out and reaching google... But the response is not coming back.. That seems to be the problem...
Any idea?
Thanks,
Ram
|
|
|
|
|
Since you said that you have a corporate firewall in the way, I would suspect that this is blocking the responses. If you have a legitimate business reason to access Google Talk, then I suggest you contact your IT department, who may allow such traffic through for you. Otherwise, you are out of luck, probably. You should never use standby on an elephant. It always crashes when you lift the ears. - Mark Wallace
|
|
|
|
|
Hi OriginalGriff,
OriginalGriff wrote: If you have a legitimate business reason to access Google Talk, then I suggest you contact your IT department
I had mentioned in my first post that I am able to connect using Google Talk and initiate a chat... The problem is while trying to replicate that behavior in my application...
If firewall is blocking the response, I would like to have an idea on how Google Talk is able to establish a communication that my application could not...
Pls suggest...
Thanks,
Ram
|
|
|
|
|
Message Closed
modified 23-Nov-14 6:45am.
|
|
|
|
|
No... I havent used it yet... I shall try that also...
Thanks,
Ram
|
|
|
|
|
hi,i have added some data to my listview.i want to add all the list view rows to a dataset or datatable using c#.please help me.give me the logic.
|
|
|
|
|
Message Closed
modified 23-Nov-14 6:45am.
|
|
|
|
|
could u kindly send me the code in c#???
|
|
|
|
|
Hi. I have controls that are being loaded at run time. Initially when they are loaded they appear as they should be but when i minimize the windows form, and restore it, they add extra spaces between them. This curious behaviour is really threatening my sanity because i have gone through the source code (for the 100th time )and there appears to be no problem with it. Below is the source:
private void ShowQuestionsAndAnswers(ArrayList questions, ArrayList answers)
{
groupBox2.Enabled = true;
j = 0;
for (int i = 0; i < questions.Count; i++)
{
tbp.Invalidate();
j = i;
ArrayList ans = new ArrayList();
GroupBox gb = new GroupBox();
gb.Size = new Size(tbp.Width - 100, 150);
tbp.Controls.Add(gb);
TableLayoutPanel tbp2 = new TableLayoutPanel();
tbp2.ColumnCount = 1;
tbp2.AutoSize = true;
gb.Controls.Add(tbp2);
Label newLabel = new Label();
newLabel.Text = (i + 1).ToString() + ". " + questions[i].ToString();
newLabel.AutoSize = true;
newLabel.BringToFront();
newLabel.Size = new Size(1000, 100);
RadioButton rdb1 = new RadioButton();
rdb1.AutoSize = true;
tbp2.SetRow(rdb1, 1);
rdb1.Text = a[0].ToString();
rdb1.Click += new EventHandler(rdb_Click);
RadioButton rdb2 = new RadioButton();
rdb2.AutoSize = true;
tbp2.SetRow(rdb2, 2);
rdb2.Text = a[1].ToString(); ;
rdb2.Click += new EventHandler(rdb_Click);
RadioButton rdb3 = new RadioButton();
rdb3.AutoSize = true;
rdb3.Text = a[2].ToString(); ;
rdb3.Click += new EventHandler(rdb_Click);
RadioButton rdb4 = new RadioButton();
rdb4.AutoSize = true;
rdb4.Text = a[3].ToString();
rdb4.Click += new EventHandler(rdb_Click);
Control[] ctrl = { newLabel,rdb1,rdb2,rdb3,rdb4 };
tbp2.Controls.AddRange(ctrl);
a.RemoveRange(0, 5);
}
Button btnDone = new Button();
btnDone.Text = "Done";
btnDone.Click += new EventHandler(btnDone_Click);
tbp.Controls.Add(btnDone);
StartTimer();
}
What could be the reason for this and how can i solve it?Wamuti: Any man can be an island, but islands to need water around them!
Edmund Burke: No one could make a greater mistake than he who did nothing because he could do only a little.
modified on Thursday, February 18, 2010 3:12 AM
|
|
|
|
|
Do you handle an Resize event? You should never use standby on an elephant. It always crashes when you lift the ears. - Mark Wallace
|
|
|
|
|
Hi,
I am writing an application that can sense the surrounding temperature.
I am thinking to plot the different temperature readings through a dynamic graph(if this is the correct term), every few seconds or even 1 minute.
Like for eg, 3.47pm, temperature reading is 27 degrees, 3.48pm is 28 degrees. 3.49pm is 28.5 degrees and so on and so forth...
The graph will be able to display the temperature (perhaps on the y axis) while the time on the x-axis.
Could anyone give me advise on this? I tried searching on Google but mostly I found are those that are cos/sin graphs.
Thanks,
Daniel
|
|
|
|
|
Message Closed
modified 23-Nov-14 6:46am.
|
|
|
|
|
Thanks for the tip, however, I am looking for something more real-time, how can I approach this?
|
|
|
|
|
Set up a timer, with the appropriate interval, and put a panel or similar on your form.
When the timer tick event fires, use Panel.Invalidate to force a re-draw.
Override the Panel.Paint event and draw your graph. You may wish to set DoubleBuffered to avoid flicker.You should never use standby on an elephant. It always crashes when you lift the ears. - Mark Wallace
|
|
|
|
|
Hello all,
Does anybody know how can I add text to an elliptic line using GDI ?
Thanks,
Berlus
|
|
|
|
|
See here[^]
It's using Bezier, but you can change that bit quite easily.You should never use standby on an elephant. It always crashes when you lift the ears. - Mark Wallace
C/C++ (I dont see a huge difference between them, and the 'benefits' of C++ are questionable, who needs inheritance when you have copy and paste) - fat_boy
|
|
|
|
|
I have one main thread, and many other background thread.
The main usage of those background thread is to query data (quite a number of queries from the web, that's why I make it threads: avoid the lagging of the user interface ).
When it comes to exporting the data in the main thread(the user interface), I need to wait until all the other thread finished.
in my code, I use:
while (QueryThread.threadCount != 0)
{
Thread.CurrentThread.Join(1000);
Console.WriteLine(QueryThread.threadCount);
}
if I comment the while loop out, the program run smoothly, but some of my exported data will have possibility of showing some "unwanted" material since some of the background threads hasn't finished their work.
however, the above while loop is infinite, the threadCount never change, which means during the "Join()" method, no background thread is being ran.
why the background threads are not ran and how can i solve this problem?
Thanks a lot!
|
|
|
|
|
Have you tried to call Join() on your separate working threads in your main thread instead?
For instance in your main thread
Thread t1 = new Thread(DoWork_1);
Thread t2 = new Thread(DoWork_2);
Thread t3 = new Thread(DoWork_3);
t1.Start();
t2.Start();
t3.Start();
t1.Join();
t2.Join();
t3.Join();
Console.WriteLine("All threads done");
|
|
|
|
|
|
You are using background threads to keep the UI responsive, which is good. But then you are blocking in this method. I suggest you disable exporting in your UI until you know all the data is ready.
You will still have to detect when your background threads have completed and the data is ready to be exported, which is a similar requirement to the code you posted. So you will still have to get the threads to signal they have completed. Setting an int counter to the number of threads and having them decrement it when they complete is as good a solution as any. You will also have to invoke a method on your UI thread when all the threads have completed, which would re-enable your export functionality.
You need to find out why QueryThread.threadCount is not being decremented. The code you posted will not stop background threads from running, so you have another problem somewhere.
One possibility is that you have not declared threadCount as volatile . Does the code work in a Debug build ( without optimizations ) ?
Nick----------------------------------
Be excellent to each other
|
|
|
|
|
HideIvy wrote: Thread.CurrentThread.Join(1000);
Why did you write this?
|
|
|
|
|
|
Thanks all.
I am not clear enough about threads before.
I changed my implementation to a Producer-Consumer model now.
And things go well =]
|
|
|
|