Skip to main content

How I geeked my Metastock with AutoHotKey

One thing about Metastock that drives me crazy is lack of keyboard shortcuts. And if there are any; I am not aware of any of them. So, finally, I decided to geek myself out of this headache.

1. Downloaded and installed a software called AutoHotKey (http://www.autohotkey.com/download/)
2. Noted down the screen co-ordinates of the "clicks" I wanted to convert into keyboard shortcuts
3. Updated the default script file with a very simple one line commands for executing the clicks
4. Now, the keyboard shortcuts work well, I dont have to click

The syntax of the script:

#IfWinActive ahk_class MetaStockMainWnd
#z::Click 892,651
#IfWinActive

Where MetaStockMainWnd defines the active window where the 'clicks' should be made. If this window is not active, these keyboard commands will not work. so, these commands will work only if the Metastock window is active. "#z" stands for Windows + Z. The coordinates are for the zoom-reset button.

My starting script is as follows:

#IfWinActive ahk_class MetaStockMainWnd
#z::Click 892,651
#x::Click 910,651
#C::Click 927,651
#V::Click 950,651
#N::Click 966,651
#P::Click 15,99
#L::Click 15,150
#k::Click 14,121
#o::Click 14,171
#d::Click 264,61
#IfWinActive

Keyboard shortcuts and mnemonics:

[In Metastock buttons in order from left to right]

Zoom reset - Windows + Z (for Undo Zoom)
Zoom Out - Windows + X
Zoom In - Windows + C (for Closer look)
Previous - Windows + V (for pre_V_ious)
Next - Windows + N (for Next)
Scrip selector - Windows + S (for Scrips)

Other clicks:

Pointer - Windows + P (for Pointer)
Line - Windows + L (Line!)
Crosshair - Windows + K (for Krosshairs)
Horizontal - Windows + O (for O_rizontal line)
Data window - Windows + D (for Data)

Limitations of this script:

AutoHotKey's Click function works based on screen cooridinates. I have configured it to my screen resolution (1024x768). If your co-ordinates are different the results will be different.
The keys can be configured using the script file. It's a 1-second job.

A serious limitation:

One serious limitation of this is, which I have not tested though, if another window pops up while the computer executing the order, the 'click' will be made in that window. To me it simply means, this should not be used simlutaneously with the live trading/banking screen.

Comments

Popular posts from this blog

Cognitive rules of business presentations

In his recent book, Clear and to the Point, Kosslyn explained that the four rules of PowerPoint are: The Goldilocks Rule, The Rudolph Rule, The Rule of Four, and the Birds of a Feather Rule. Here's how they work. The Goldilocks Rule refers to presenting the "just right" amount of data. Never include more information than your audience needs in a visual image. As an example, Kosslyn showed two graphs of real estate prices over time. One included ten different numbers, one for each year. The other included two numbers: a peak price, and the current price. For the purposes of a presentation about today's prices relative to peak price, those numbers were the only ones necessary. The Rudolph Rule refers to simple ways you can make information stand out and guide your audience to important details -- the way Rudolph the reindeer's red nose stood out from the other reindeers' and led them. If you're presenting a piece of relevant data in a list, why not mak...

Monetary inflation, Spiritual devaluation

Its been sometime I have been trying to make some special people understand the evils of inflation. Inflation is an abstract subject most of us dont know about, let alone understand the technicalities amidst jargons. I have in my previous post have briefly touched the social part of inflation but never in a concentrated way. I understand what my friends mean when they say "tell me in layman’s language." It is not a heartening sign, that they avoid technicalities. But it could well be that knowing where they stand, their role and understanding the social changes in the light of inflation may motivate them to understand the term "inflation." This is just to highlight the brief points. First and the foremost, is there any link between inflation numbers and society. Yes. The relation is same as the relation between society and money. What is money? Money is an easy means of exchange. If I am selling my horses to a pig-farmer and I am not interested in taking pigs in ret...

Unprecedented External Demand Shock Underway

India’s export growth averaged 24.8% over the last three years, driven by strong global growth. However, over the last three months, export growth has decelerated sharply. While until recently the strong demand from emerging markets including Latin America, Emerging Europe, the Middle East and Africa ensured that export growth remained healthy, over the last three months disruptions in the macro environment of these economies have been evident. Apart from weakening demand, exports have also been affected by the lack of availability of foreign trade credit and inventory liquidation. India’s exports declined by 12.1%Y in October 2008 compared with 10.4% in September and 26.9% in August. While we expect some improvement in the second half of 2009, exports are likely to be unusually weak over the next six months. We now expect exports to decline by 5.3%Y in 2009 compared with 12.7% in 2008 (estimated) and 23.1% in 2007 Excerpt source