I think what he is referring to is creating your own custom control that will draw the graphics how you want using the Graphics object provided in the OnPaint method of UserControls.
Programming today is a race between software engineers striving to build bigger and better idiot-proof programs, and the Universe trying to produce bigger and better idiots. So far, the Universe is winning.
the problem is this that I m monitoring a microcontroller through a serial port the serial port have to monitor continuousy. Do some one have any code to monitor the serial port continuosly that when data arrives at the serial port either a character or a number of characters the serial port read it and proces it further .
Also why when I moved toolStrip and menuStrip controls to toolStip Container I added lately all event handlers where removed rendering all menu and tool strip items not working, had to manually double click each item then rename old event handler methods to new created on double click to make all things work again
basically for example event that had click stopped working and new was now click_1 so I had to remove new empty click_1 and rename old click to click_1.
Take a look at the SystemEvents class especially the SessionEnding event.
"Programming today is a race between software engineers striving to build bigger and better idiot-proof programs, and the Universe trying to produce bigger and better idiots. So far, the Universe is winning." - Rick Cook
nevermind.. i think ill give up for now and just use a modified spinlock!
im writing a simple lock-free queue (intended for efficient multithreaded use) and im not sure ive quite figured out the logic behind the use of Interlocked.CompareExchange(). would code like the following produce the correct result of adding a new linked list node to the tail of a list under multithreading conditions??
I dont think this is thread-safe: you perform two operations on the list
2. modify tail (_tail=newNode)
the combined operations should be atomic.
And I dont think you can achieve it with the Interlocked class at all, since inserting
or removing a node to/from a linked list involves modifying two references or pointers,
which is more than any Interlocked method offers.
SO you will need a lock after all.
Last Visit: 31-Dec-99 19:00 Last Update: 31-Jan-23 4:56