Changing the function keys (ctrl,alt shift) F1..F12

K

KSO

how can i put some text into these key by C# code ?

In the old days you could do it by the PROMPT command i DOS but it seems NOT
to work any more - the "change key" facility has disappeared.

Can I do the change from C# so that it will stay changed when I start
another program ?

Best regards
KSor, Denmark
 
N

Nicholas Paldino [.NET/C# MVP]

KSor,

What do you mean you want to put some text? Is it that when you hit
those buttons, you would get some text inserted into your application, no
matter what the app? Something tells me that you can't really do this (at
least in windows apps) as every windows app is going to process those keys
individually (for example, hitting a key in one app will have a completely
different effect than hitting the same key in another app).

Or are you trying to do something else?
 
K

KSO

Yes thats what I want - but you say it can't be done - :-(

Thanks !

Nicholas Paldino said:
KSor,

What do you mean you want to put some text? Is it that when you hit
those buttons, you would get some text inserted into your application, no
matter what the app? Something tells me that you can't really do this (at
least in windows apps) as every windows app is going to process those keys
individually (for example, hitting a key in one app will have a completely
different effect than hitting the same key in another app).

Or are you trying to do something else?


--
- Nicholas Paldino [.NET/C# MVP]
- (e-mail address removed)

KSO said:
how can i put some text into these key by C# code ?

In the old days you could do it by the PROMPT command i DOS but it seems
NOT
to work any more - the "change key" facility has disappeared.

Can I do the change from C# so that it will stay changed when I start
another program ?

Best regards
KSor, Denmark
 
N

Nicholas Paldino [.NET/C# MVP]

I wouldn't say that it can't be done, but you would have to have a
general interface for inserting text into any arbitrary application. At
best, you could guess how this could be done (through automation, sending
the WM_SETTEXT windows message, through the accessibility APIs), but it's
not easy.

You might be able to do something using the clipboard though, like
telling the application to paste the contents from the clipboard. Of
course, you should be careful not to overwrite what is currently on the
clipboard.

--
- Nicholas Paldino [.NET/C# MVP]
- (e-mail address removed)

KSO said:
Yes thats what I want - but you say it can't be done - :-(

Thanks !

Nicholas Paldino said:
KSor,

What do you mean you want to put some text? Is it that when you hit
those buttons, you would get some text inserted into your application, no
matter what the app? Something tells me that you can't really do this
(at
least in windows apps) as every windows app is going to process those
keys
individually (for example, hitting a key in one app will have a
completely
different effect than hitting the same key in another app).

Or are you trying to do something else?


--
- Nicholas Paldino [.NET/C# MVP]
- (e-mail address removed)

KSO said:
how can i put some text into these key by C# code ?

In the old days you could do it by the PROMPT command i DOS but it
seems
NOT
to work any more - the "change key" facility has disappeared.

Can I do the change from C# so that it will stay changed when I start
another program ?

Best regards
KSor, Denmark
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top