473,386 Members | 1,654 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,386 software developers and data experts.

Read another applications textboxes (VB 2005)

Hi everyone,
I have created my first real life application, that runs in the system tray
and monitors changes to the clipboard, then depending on the content it may
search our stock file and display the current stock situation in a balloon
(using balloontiptext).

I now want to add extra functionality to my program by making it read text
from any other application without the user having to copy text to the
clipboard.

I have a timer that runs every couple of seconds and I have managed to get
the windows title from any program that is currently running, into a
variable in my application, but I can't figure out how to read other fields
on the users application (ideally which ever has the focus)

Ideally I want to copy the entire content of an email body into a vairable
in my application, so I can then search it for product codes, and then if
necessary provide stock info in a bubble.

Can anyone help ?, sample code much appreciated as I am new to VB.net and I
have previously only worked with MSAccess VBA.

Thanks

Paul
Oct 18 '06 #1
4 2613
The down and dirty way I'd try to do it would be by simulating a mouse
click in the text box, then sending a "ctrl-A" for select all, then
"ctrl-c" for copy - your app should take care of the rest. I would
image this would be disruptive to an end user though.

Brad
Paul wrote:
Hi everyone,
I have created my first real life application, that runs in the system tray
and monitors changes to the clipboard, then depending on the content it may
search our stock file and display the current stock situation in a balloon
(using balloontiptext).

I now want to add extra functionality to my program by making it read text
from any other application without the user having to copy text to the
clipboard.

I have a timer that runs every couple of seconds and I have managed to get
the windows title from any program that is currently running, into a
variable in my application, but I can't figure out how to read other fields
on the users application (ideally which ever has the focus)

Ideally I want to copy the entire content of an email body into a vairable
in my application, so I can then search it for product codes, and then if
necessary provide stock info in a bubble.

Can anyone help ?, sample code much appreciated as I am new to VB.net and I
have previously only worked with MSAccess VBA.

Thanks

Paul
Oct 18 '06 #2
Thanks Brad,
I've just tried this, but its unusable, and I cant find a command to
de-select all, so I used the END key.

This would also prevent the user from being to use the clipboard for what
they want it for.

Any other suggestions much appreciated.

Paul
"Blarneystone" <Br*******@gmail.comwrote in message
news:11*********************@m73g2000cwd.googlegro ups.com...
The down and dirty way I'd try to do it would be by simulating a mouse
click in the text box, then sending a "ctrl-A" for select all, then
"ctrl-c" for copy - your app should take care of the rest. I would
image this would be disruptive to an end user though.

Brad
Paul wrote:
>Hi everyone,
I have created my first real life application, that runs in the system
tray
and monitors changes to the clipboard, then depending on the content it
may
search our stock file and display the current stock situation in a
balloon
(using balloontiptext).

I now want to add extra functionality to my program by making it read
text
from any other application without the user having to copy text to the
clipboard.

I have a timer that runs every couple of seconds and I have managed to
get
the windows title from any program that is currently running, into a
variable in my application, but I can't figure out how to read other
fields
on the users application (ideally which ever has the focus)

Ideally I want to copy the entire content of an email body into a
vairable
in my application, so I can then search it for product codes, and then if
necessary provide stock info in a bubble.

Can anyone help ?, sample code much appreciated as I am new to VB.net and
I
have previously only worked with MSAccess VBA.

Thanks

Paul

Oct 18 '06 #3
You may take a look at the following thread:

http://groups.google.com/group/micro...97ddccb84315be

Thanks,

Seth Rowe
Paul wrote:
Thanks Brad,
I've just tried this, but its unusable, and I cant find a command to
de-select all, so I used the END key.

This would also prevent the user from being to use the clipboard for what
they want it for.

Any other suggestions much appreciated.

Paul
"Blarneystone" <Br*******@gmail.comwrote in message
news:11*********************@m73g2000cwd.googlegro ups.com...
The down and dirty way I'd try to do it would be by simulating a mouse
click in the text box, then sending a "ctrl-A" for select all, then
"ctrl-c" for copy - your app should take care of the rest. I would
image this would be disruptive to an end user though.

Brad
Paul wrote:
Hi everyone,
I have created my first real life application, that runs in the system
tray
and monitors changes to the clipboard, then depending on the content it
may
search our stock file and display the current stock situation in a
balloon
(using balloontiptext).

I now want to add extra functionality to my program by making it read
text
from any other application without the user having to copy text to the
clipboard.

I have a timer that runs every couple of seconds and I have managed to
get
the windows title from any program that is currently running, into a
variable in my application, but I can't figure out how to read other
fields
on the users application (ideally which ever has the focus)

Ideally I want to copy the entire content of an email body into a
vairable
in my application, so I can then search it for product codes, and then if
necessary provide stock info in a bubble.

Can anyone help ?, sample code much appreciated as I am new to VB.net and
I
have previously only worked with MSAccess VBA.

Thanks

Paul
Oct 18 '06 #4
I have read this but I still can't manage to get it to work (Mainly because
I'm a beginner who's bitten off more than I can chew !)

Any chance anyone out there can supply a .NET example of how to take the
text from a notepad txt file when it has focus and put it in a vairable in
my app, I should be able to convert that to work with my app then.

Again a big Thanks to all.

Paul
"rowe_newsgroups" <ro********@yahoo.comwrote in message
news:11**********************@k70g2000cwa.googlegr oups.com...
You may take a look at the following thread:

http://groups.google.com/group/micro...97ddccb84315be

Thanks,

Seth Rowe
Paul wrote:
>Thanks Brad,
I've just tried this, but its unusable, and I cant find a command to
de-select all, so I used the END key.

This would also prevent the user from being to use the clipboard for what
they want it for.

Any other suggestions much appreciated.

Paul
"Blarneystone" <Br*******@gmail.comwrote in message
news:11*********************@m73g2000cwd.googlegr oups.com...
The down and dirty way I'd try to do it would be by simulating a mouse
click in the text box, then sending a "ctrl-A" for select all, then
"ctrl-c" for copy - your app should take care of the rest. I would
image this would be disruptive to an end user though.

Brad
Paul wrote:
Hi everyone,
I have created my first real life application, that runs in the system
tray
and monitors changes to the clipboard, then depending on the content
it
may
search our stock file and display the current stock situation in a
balloon
(using balloontiptext).

I now want to add extra functionality to my program by making it read
text
from any other application without the user having to copy text to the
clipboard.

I have a timer that runs every couple of seconds and I have managed to
get
the windows title from any program that is currently running, into a
variable in my application, but I can't figure out how to read other
fields
on the users application (ideally which ever has the focus)

Ideally I want to copy the entire content of an email body into a
vairable
in my application, so I can then search it for product codes, and then
if
necessary provide stock info in a bubble.

Can anyone help ?, sample code much appreciated as I am new to VB.net
and
I
have previously only worked with MSAccess VBA.

Thanks

Paul

Oct 19 '06 #5

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

1
by: Tolgay Gül | last post by:
I need some codes that able to send and read data by serialport in VB.Net 2005 beta 2. I wrote some codes and It can send data via serialport but It cannot read what I send. I have looked up on...
4
by: Usarian Skiff | last post by:
Is it possible to enter data into other applications' textboxes and datagrids? I want to automate our production control software (like a macro). It's written in VB6, and I have access to the...
4
by: Skc | last post by:
We have a developer who has made an application in Visual Studio 2003 and this will not work in our version of Visual Studio 2002. Error message: Solution file loading error: The selected file...
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.