by Mike Devoe, Guest Writer & Senior Developer
Getting data out of MEDITECH has always been fairly straightforward with tools like the NPR report writer. Getting data back into MEDITECH is quite a different story and often calls for creative solutions such as scripting. The basic idea behind scripting is simple. Just as the scroll in a player-piano eliminates the need for a musician, a script keeps time with the system and eliminates the need for a human typist.
I started my career building MEDITECH scripting tools and scripts nearly 20 years ago. Back then, a mouse was a rodent and I worked exclusively with keystrokes and screens where text lined up nicely in rows and columns. I used to tell myself I’d have to find a new career when scripting tools were no longer needed. I anticipated having to brush up my resume when GUI replaced text based terminal emulation. As the years passed, scripting evolved from a simple player-piano into something more like a sophisticated robot. My scripts began making decisions and even calling out for help when they got into trouble. Still, I thought GUI would eventually kill scripting and I’d have to move on.
As MEDITECH’s Advanced Technology launches us into an all-GUI world of buttons, text boxes and clickable strings of text, it appears I’ll have plenty of job security for years to come. We still need scripting as much today as we needed it in the good old text emulation days.
I must confess that I initially found the thought of scripting in an all-GUI world a bit intimidating. It meant I would have to leave my comfortable world of rows, columns, cursors and keystrokes. I’d have to figure out how to chase a mouse around the screen and find a way to read text that was painted as a picture instead of something you’d normally be able to copy and paste. Even the color of text now has meaning and my scripts might need to base decisions on color. It was all a bit overwhelming yet exciting at the same time.
Looking back, I now find I prefer to write FOCUS/ 6.x scripts over the old text-based scripts. I let the scripting tool’s recorder look over my shoulder as I perform the desired task and it writes syntax-perfect script commands to interact with the mouse controllable screen objects. In the old text world I would have to tell the script recorder what I wanted it to look for before moving on. In an object world, the script recorder already knows. It knows it will need to generate code to wait for the button to arrive on the screen before attempting to click it. Script recordings have become easier and more accurate, leaving me more time to “focus” on turning my navigation recordings into powerful data entry scripts. My player piano’s scroll now drives a whole new orchestra.
![]()
1 response so far ↓
1 It Looks Like Terminal Emulation to Me // Feb 23, 2010 at 9:37 am
[...] a prior posting, I reminisced about my early days as a script programmer when I thought scripting would eventually [...]
Leave a Comment