Tip

Client Access Express macro for getting to compile errors quickly

Attaching macros to your customized keyboard layout can really save time -- for example, I frequently want to see the errors generated by my compile while I'm in SEU, so I set up this simple macro to help automate the task.

To create the macro, go into Edit Preferences Macro/Script and press Customize. Go into the File menu, choose New and select VB Script. Paste the code (below) into the "Macro Statements" box, pull down the File menu and Save As ERROR.

Now attach the macro to the keyboard by pulling down Edit, Preferences, Keyboard and choose Customize. Use the mouse to select the E key by clicking on it, and then use the Macro/Script dropdown to pick out the new ERROR macro. Press the "->" button next to Ctrl to set Ctrl E to run the macro. Pull down File, choose Exit, and click the Yes button to save the changes to the keyboard. Hit OK to leave keyboard setup.

To use the new macro, open a source in SEU and press Ctrl E. The macro presses F15, selects option 2 (spool file), presses Enter, then finds *ERR – the first error in the compile listing.


[PCOMM SCRIPT HEADER]
LANGUAGE=VBSCRIPT
DESCRIPTION=
[PCOMM SCRIPT SOURCE]
OPTION EXPLICIT
autECLSession.SetConnectionByName(ThisSessionName)
autECLSession.autECLPS.SendKeys "[pf15]"
autECLSession.autECLOIA.WaitForInputReady
autECLSession.autECLPS.SendKeys "2"
autECLSession.autECLPS.SendKeys "[enter]"
autECLSession.autECLOIA.WaitForInputReady
autECLSession.autECLPS.SendKeys "f *err"
autECLSession.autECLPS.SendKeys "[enter]"

==================================
MORE INFORMATION ON THIS TOPIC
==================================

The Best Web Links: tips, tutorials and more.

Ask your programming questions--or help out your peers by answering them--in our live discussion forums.

Ask the Experts yourself: Our application development gurus are waiting to answer your programming questions.

This was first published in September 2004

There are Comments. Add yours.

 
TIP: Want to include a code block in your comment? Use <pre> or <code> tags around the desired text. Ex: <code>insert code</code>

REGISTER or login:

Forgot Password?
By submitting you agree to receive email from TechTarget and its partners. If you reside outside of the United States, you consent to having your personal data transferred to and processed in the United States. Privacy
Sort by: OldestNewest

Forgot Password?

No problem! Submit your e-mail address below. We'll send you an email containing your password.

Your password has been sent to:

Disclaimer: Our Tips Exchange is a forum for you to share technical advice and expertise with your peers and to learn from other enterprise IT professionals. TechTarget provides the infrastructure to facilitate this sharing of information. However, we cannot guarantee the accuracy or validity of the material submitted. You agree that your use of the Ask The Expert services and your reliance on any questions, answers, information or other materials received through this Web site is at your own risk.