× The internal search function is temporarily non-functional. The current search engine is no longer viable and we are researching alternatives.
As a stop gap measure, we are using Google's custom search engine service.
If you know of an easy to use, open source, search engine ... please contact support@midrange.com.



Hi

I have done lots of work with macros. Maybe I can help.

Which screen do you want to run the macro from? Maybe different screens? If you can get the cursor to the same place every time, then you should be able to use cursor movement to get to the message line.

But this might be a problem, because andy F-key will blow away the message. OK, then you need to use VBA for your macro. With VBA you can ask for the string at any location on the screen, then massage it as you need to.

You also have an issue with varying length for the job spec. A VBA macro will make this easier to deal with.

So here's my suggestion - record a macro that does something like what you want - maybe even from the screen with the message -
1. drag across the job info
2. then go to a command line
3. clear it
4. type wrkjob plus a space
5. then paste
6. then hit enter

Then end recording. Now you will convert the macro to a VBA type.
1. Go out to the iSeries Access program group and look for utilities or some such, one will be to convert macros
2. Find your just-recorded macro
3. Take the option to convert it

Now to edit the converted macro - go into you emulator and go to the Edit menu option - somewhere there is an option to work with macros - you will find a place to edit them. Find yours, open it for editing, then see what it is doing in the copy function. You will want to go to the help text there, to see what other functions you can use, including getting a string of a certain length at the screen location you specify. Then you might need to scan for a space - or there's a function to get only a "word" with no spaces. Whatever, then you can see what else it is doing, including writing a string to a location on the screen.

HTH
Vern

On 3/28/2011 9:57 AM, Gqcy wrote:
I am trying to create a macro to:
"WRKJOB "<concat. the job#/user/jobname from the Line 25
CPC1221 message (Job ... submitted to job queue)

Can someone provide me with an example of a macro doing something like this?

Thanks

As an Amazon Associate we earn from qualifying purchases.

This thread ...

Replies:

Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

This mailing list archive is Copyright 1997-2024 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].

Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.