|
Set the checked property of the checkbox to true.
Karl
|
|
|
|
|
First you must retrieve the index of the item, suing some find method (I forgot the exact syntax).
Then use somthing lik MyCheckedListbox.Items[idx].Checked=true;
Check the class members documentation for details please.
|
|
|
|
|
use the checked property and then search it using the appropriate index or the string.
Keshav Kamat
India
|
|
|
|
|
i have to do the programming for communication of the data between two computers,does it invlove the socket programming ?????the computers are not on internet ,and can u plz tell me , what is meant by desktop application?????
|
|
|
|
|
Please, please, please, STOP asking questions over and over. Answer the people who respond to you, on the same thread.
If the computers are not on the internet, then they need to be on a private network. There are trivial ways to solve this problem ( you can pass files onto the other machine, and have it watching a directory, for example ).
wrote: what is meant by desktop application?????
A program that runs on a local PC, as opposed to one that runs in a web browser.
It sounds to me like you've been given homework and you're completely lost. There are many ways to do what you want, in the first instance you should refer to your class notes and your teacher, to find out what approach they want you to take.
Christian Graus - Microsoft MVP - C++
Metal Musings - Rex and my new metal blog
"I am working on a project that will convert a FORTRAN code to corresponding C++ code.I am not aware of FORTRAN syntax" ( spotted in the C++/CLI forum )
|
|
|
|
|
Christian Graus wrote: Please, please, please, STOP asking questions over and over. Answer the people who respond to you, on the same thread
And maybe choose a user name that doesn't show up as blank.
|
|
|
|
|
It's not blank. It's a bug in CP.
Dave Kreskowiak
Microsoft MVP - Visual Basic
|
|
|
|
|
Hello experts,
I've always used the Control.Invoke() method when invokation was required.
However, in my current project I need to use the Control.BeginInvoke() method instead.
So here are a few questions...
What does it mean when MSDN documents say:
Executes a delegate asynchronously on the thread that the control's underlying handle was created on. I always thought that asynchronous execution means executing an operation on a new thread. Is that true?
If so, how could an operation be executed "asynchronously on the thread that the control's underlying handle was created on"?
I think my understanding of the term "asynchronous execution" is wrong...
And one more... Should I use Control.EndInvoke() even if I've no need for the returned value?
Thanks in advance,
Shy.
|
|
|
|
|
shyagam wrote: I always thought that asynchronous execution means executing an operation on a new thread. Is that true?
If so, how could an operation be executed "asynchronously on the thread that the control's underlying handle was created on"?
No, that's not true. Asynchronous execution only means that the method starting the execution doesn't wait for the execution to end. If the execution is done on the same computer, a different thread has to be used for the execution, but it doesn't have to be a newly created thread.
shyagam wrote: And one more... Should I use Control.EndInvoke() even if I've no need for the returned value?
No. The EndInvoke only waits for the execution to finish and gets the return value from it.
---
single minded; short sighted; long gone;
|
|
|
|
|
I see...
Thanks a lot!
|
|
|
|
|
shyagam wrote: Executes a delegate asynchronously on the thread that the control's underlying handle was created on.
Just means that if you call BeginInvoke on a different thread than the one that the control is running on, the control will marshal the delegate invocation to its own thread and invoke it there.
Think of the Control as having a message queue somewhere. When you call BeginInvoke on a different thread than the one that the control is running on, the Control puts your deletate on its queue and eventually invokes it from its own thread.
|
|
|
|
|
well if data communication is needed to take place between two computers,what do i need,i mean ,what sort of knowledge is needed.
|
|
|
|
|
Is this a reply to my reply below ? If so, keep on the same thread.
That depends. Are they on a local network ? Are they connected to the Internet ? How will they talk ? What sort of data do you want to pass ? In what direction ?
I'd lean towards writing a web service for this sort of thing, if that is possible. It's just nice and clean. But, it depends on your needs.
Christian Graus - Microsoft MVP - C++
Metal Musings - Rex and my new metal blog
"I am working on a project that will convert a FORTRAN code to corresponding C++ code.I am not aware of FORTRAN syntax" ( spotted in the C++/CLI forum )
|
|
|
|
|
I'm looking for a book for C# that is similar to a book like the Developer's Dictionary series. The Developer's Dictionary series gives you a huge book with practically everything you need to know. I've found my JavaScript: Developer's Dictionary to be EXTREMELY helpful, and I'd like to have a book similar, but on C#. Does anyone know of such a book?
-----
Note: *** Never give me an answer have anything to do with Visual Studio. I don't have this program, and it'll be that way for a long, long time. ***
|
|
|
|
|
You'd do better to refer to msdn.microsoft.com[^], or install the MSDN help that comes with VS, for that sort of help. You'll save a few trees, as well.
And, you can always ask questions here ( but I understand you're asking about a comprehensive reference ).
Christian Graus - Microsoft MVP - C++
Metal Musings - Rex and my new metal blog
"I am working on a project that will convert a FORTRAN code to corresponding C++ code.I am not aware of FORTRAN syntax" ( spotted in the C++/CLI forum )
|
|
|
|
|
try for the complete reference series on C#.
Keshav Kamat
India
|
|
|
|
|
can any one guide me,how can we exchange the data in c#???????????
s_khan
|
|
|
|
|
Who do you want to exchange it with ? If you mean between forms, delegates are the most flexible, but just passing through a constructor or a public property often works.
Christian Graus - Microsoft MVP - C++
Metal Musings - Rex and my new metal blog
"I am working on a project that will convert a FORTRAN code to corresponding C++ code.I am not aware of FORTRAN syntax" ( spotted in the C++/CLI forum )
|
|
|
|
|
Hi,
I was using the return character to evaluate the input of a textbox via the keypress event.
private void textBoxInput_KeyPress(object sender, KeyPressEventArgs e)
{
if (e.KeyChar == '\r')
{
e.Handled = true;
}
}
After turning on autocomple the keypress event is no longer triggered when the pressed key is the return key. Does anyone know a way around this?
Thanks
Karl
|
|
|
|
|
when you use autocomplete and choose a text from the autocomplete list, its sure that it wll not trigger the keypress event because you are not pressing keys onthe keyboard.
try validating the text in the textbox again before you will use it.
Signature has been encrypted
|
|
|
|
|
Thanks for your reply.
It doesn't matter if the text is chosen from the autocomplete list or the person is typing in something completely new. The return key never fires a keypress event anymore. Every other key fires the event. The return key instead causes the text to be highlighted.
I am not sure what you mean by validating the text in the textbox before using it. I currently do not validate the text, anything can be entered in the box.
Thanks.
Karl
|
|
|
|
|
After further investigation it turns out that auto complete only intercepts the keypress event for the return key. The keypress event gets fired appropriately with any other key. The other keyboard events such as keyup and keydown are unaffected by this issue so they can be used as a work around.
If anyone knows more about this issue please reply.
Karl
|
|
|
|
|
from a winform gui control a button or a event should run a command on the cmd.exe in the backend and how to capture the output of it in a string and desplay in a textbox
similarly if i have to issue/get multiple command and its correspondig output in hashtable,
eg, cmd1 its output
cmd2 output
cmd3 output
prashanth,
s/w Engineer,
Syfnosys.
|
|
|
|
|
Process.StandardOutput Property [^]
Take a look at the example.
"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 www.troschuetz.de
|
|
|
|
|