Recommended Posts

acarter 1

acarter 1

I'm building a program for work and our current system is a Java Applet. We have several items we want to "load" in, but it takes forever to manually enter in each item into the Java Applet window. A lot of the items are just typing and hitting enter, but there are instances where we have to use function keys, such as F11. From Excel, I saved these items as a Text Tab Delimited file. I currently have a program shown below:

I want to create a "Load" button that will read each column from the text file and enter it on the Java Applet screen. If the radio button for that column is marked Input, it reads it off the text file. If its marked F3 or F11, it presses that key. If its marked OFF, it ignores that column and moves to the next line (starting back at column A for the next line).

Thanks! It looks much more simplified that way. Like I said, I'm a bit of a newbie. I've only done programming for Android applications and never to manipulate a window/java applet. So this is a bit out of my realm.

That may be similar to what I'm looking for, but I need something to read off a text file and automate it. It looks like everything in that would be the same process each time and mine varies by what is in the text file. But thank you though!

Share this post

Link to post

Share on other sites

acarter 1

acarter 1

Correct. instead of paste it would be Send or ControlSend where possible.

So basically your reading an excel file cell by cell into an "array" for instance, using a loop. Then sending the data to your applet the same way.

Either by TAB ing your way to the control and SEND ing the command or ControlSend where possible.

Bill

I think I forgot to mention that the Java Applet is its own window. I've been able to manipulate the window with the WinWaitActive and Send commands, so I don't think using the Java UDF would be necessary. My main concern is getting the radio buttons to correspond with the columns (blank) in Excel for F3 and F11. So I would just need to load the excel into an array, correct? How would I go about telling it which columns to not read and to move to the next line when it hits the "OFF" radio button for that column? And telling it when to stop?