Marcus' Macro Blog

Tips and News on Macro Recording and Automating Windows with Macro Scheduler
March 20th, 2015 by Marcus Tettmar

We managed to get a few glimpses of the solar eclipse today. In fact the light cloud here in Dorset probably made it safer and easier to see and photograph. Friends in London and the South East were less lucky as the cloud cover was too thick to see anything.

Here are a couple of photos I managed to take:

And a close up as the moon passes out the other side:

March 17th, 2015 by Marcus Tettmar

Regular readers and users know there’s very little you can’t do with Macro Scheduler. We see it being used for all kinds of applications and interfaces. The list is endless. Most solutions we see are unique to the customer’s specific scenario. But here’s something which almost every company could benefit from: Single Sign-on.

Single sign-on (SSO) is a property of access control of multiple related, but independent software systems. With this property a user logs in once and gains access to all systems without being prompted to log in again at each of them.

http://en.wikipedia.org/wiki/Single_sign-on

In many organisations users work with a multitude of disparate systems. A lot of time is wasted logging in and out of these systems.

At one of our clients we’re working on a Single Sign-on pilot driven by Macro Scheduler. This is an interesting and exciting use of Macro Scheduler which will benefit a large number of users across the organisation.

We also aim to have Macro Scheduler maintain the context between the different systems as logging in is only part of the problem. Usually users need to pull up records for the same customer, or order (for example) in each of those systems. If the single sign-on solution does that for them – and monitors when the context changes and mirrors that in the other systems, an awful lot of time can be saved, and chances for error are eliminated.

Macro Scheduler can handle LDAP lookup, access user information from databases, perform WEB/SOAP/COM interactions and, of course, can simulate user input for web and desktop applications which offer no alternative.

Macro Scheduler is an inexpensive and flexible solution which can work with any type of user interface, making it ideal for providing a single sign-on solution.

If you have done something similar with Macro Scheduler I’d be interested to hear from you. Comment below or drop us a line.

March 16th, 2015 by Marcus Tettmar

We have today released Macro Scheduler 14.2.03. This is a minor maintenance release addressing a few small bugs and improvements.

For full details please see the history list here.

Registered Users | New Licenses | Trial Downloads

February 12th, 2015 by Marcus Tettmar

February 6th, 2015 by Marcus Tettmar

We received this email today and I just had to share it …

Macro Scheduler image recognition just saved me 6 hours of mind numbing work and my program took me about 15 minutes to write, test, and start using. Such an AWESOME solution you provide.

Richard A. San Jose, CA USA

For more info on how to use Image Recognition see:
http://help.mjtnet.com/article/39-how-to-use-macro-schedulers-image-recognition-functions

January 23rd, 2015 by Marcus Tettmar

Electric cars and hybrids are becoming more common and it’s great to see more and more of them on the road. My next car, due next month, will be a plug-in hybrid.

I see the industry moving rapidly. Advancements in battery technology and range are happening all the time. If I didn’t have a large family I’d be happy with a small pure-EV with a range of over 200 miles. But I don’t think it will be long before larger family sized cars can do the same. In fact Tesla recently revealed a prototype 7 seater – the Model-X – which promises a range of 270 miles. Right now it’s a bit pricey, but it won’t be long before other manufacturers catch up. I can’t wait.

The same technology is now being tried in other forms of transport. Near my home town of Harwich this month the first battery powered train was tested. Much of our train network has been or is being electrified. But inevitably there are gaps which at present must be filled by diesel engines. A battery powered solution would allow trains to continue to work on electricity through the gaps and recharge when back on overhead power.

Recently I read about a battery powered electric chain ferry in Norway. It has now been sailing for over a year. Great stuff. There’s a chain ferry near us in Poole Harbour. I hope they look to similar technology.

Of course we also need to make sure the electricity used to charge these batteries is not being made by burning coal. But it’s good to see this kind of progress towards a reduction on our dependence on oil, which is sorely needed:

A third of the world’s oil, half of its gas, and 80 percent of its coal reserves must remain unused if we are to have a good chance of avoiding potentially devastating climate change.

January 16th, 2015 by Marcus Tettmar

Well, it’s a new year and with that comes new years resolutions. For MJT Net Ltd I decided we needed to do more to lessen our impact on the environment.

We’ve already made some changes:

Our web sites, mjtnet.com and clipmagic.com, are now hosted in a data center which runs directly on 100% renewable generated electricity.

Web servers run 24/7. So I think switching to green data centers is an important move.

null

For our office electricity we have recently switched to ecotricity who generate all their electricity using renewable sources – the wind, sun and sea. We’re also planning to install our own solar panels this year.

Where possible we will source second hand/reconditioned IT hardware.

We’re not a large company, so these changes may seem minuscule in the grand scheme of things. But it all helps and if everyone did this it will help much more.

January 15th, 2015 by Marcus Tettmar

Our very own Dorian Ellis drove this beautiful MJT liveried virtual car to a 1st in class win at Prague in Forza Motorsport 5:

MJT Macro Car

The design is courtesy of Chris Henwood. Great work Chris!

December 22nd, 2014 by Marcus Tettmar

Someone asked me how they could buy a Macro Scheduler subscription for a friend, for Christmas and I thought what a great idea!

A monthly subscription costs only $15. Or you can buy a three month subscription for $40.

More info and subscription signups here.

That would make a great Christmas present for someone. You can buy a three month subscription and then cancel before the end of the term and they get three months of uninterrupted, unlimited use. A great way to introduce someone to the power and flexibility of Macro Scheduler.

If you want to buy someone a subscription, use your details when you signup and then forward them the activation email. Keep the subscription going for as long as you want.

December 15th, 2014 by Marcus Tettmar

Just a quick note to wish all our customers and readers of this blog good tidings for this festive season. Whether you celebrate this time of the year or not, we’ll be raising a glass to all of you.

Forum regular JRL has put together this snazzy little Macro Scheduler script. Paste it into a new macro and hit run for some festive cheer:

OnEvent>key_down,VK27,0,Quit
SRT>Quit
  SetControlText>Sparkler,TEdit,1,Complete
  WaitWindowClosed>Sparkler
  Wait>1
  DeleteFile>%temp_dir%Sparkler.scp
  Exit>0
END>Quit

DeleteFile>%temp_dir%Sparkler.scp
LabelToVar>SparkleScript,vScrData

Dialog>Dialog1
object Dialog1: TForm
  BorderStyle = bsNone
  Caption = 'Happy Holidays'
  ClientHeight = 330
  ClientWidth = 780
  Color = 111111
  Position = poScreenCenter
  object Panel3: TPanel
    Left = 0
    Top = 0
    Width = 780
    Height = 330
    BevelEdges = []
    BevelOuter = bvNone
    Caption = 'And a Happy New Year'
    Color = 111111
    Font.Charset = ANSI_CHARSET
    Font.Color = clRed
    Font.Height = -80
    Font.Name = 'Vladimir Script'
    Font.Style = []
    ParentFont = False
    Visible = False
  end
  object Panel2: TPanel
    Left = 0
    Top = 0
    Width = 780
    Height = 330
    BevelEdges = []
    BevelOuter = bvNone
    Caption = 'Merry Christmas'
    Color = 111111
    Font.Charset = ANSI_CHARSET
    Font.Color = clRed
    Font.Height = -96
    Font.Name = 'Old English Text MT'
    Font.Style = []
    ParentFont = False
  end
  object Panel1: TPanel
    Left = 0
    Top = 0
    Width = 780
    Height = 330
    BevelEdges = []
    BevelOuter = bvNone
    Caption = ''
    Color = 111111
  end
end
EndDialog>Dialog1

Show>Dialog1

ExecuteFile>%temp_dir%Sparkler.scp

Let>WIN_USEHANDLE=1
  GetWindowPos>Dialog1.handle,Dia1X,Dia1Y
Let>WIN_USEHANDLE=0
Add>Dia1Y,165
Let>StartY=Dia1Y
Let>YFlag=1
Wait>0.3

Let>kk=0
Repeat>kk
  Add>kk,4
  If>Dia1Y>{%StartY%+20}
    Let>YFlag=0
  EndIf
  If>Dia1Y<{%StartY%-20}
    Let>YFlag=1
  EndIf
  Add>Dia1X,4
  If>YFlag=1
    Add>Dia1Y,8
  Else
    Sub>Dia1Y,8
  EndIf
  Wait>0.025
  If>Dia1X>40
    SetControlText>Sparkler,TEdit,1,%Dia1X%;%Dia1Y%
  EndIf
  SetDialogProperty>Dialog1,Panel1,Left,kk
Until>kk>750

Timer>Begin

GetWindowPos>Sparkler,SparkX,SparkY

Label>Loop
If>{%Dia1X%<%SparkX%+150}
  Add>Dia1X,1
EndIf
If>Dia1Y>StartY
  Sub>Dia1Y,1
EndIf
If>Dia1YDia1Y,1
EndIf
SetControlText>Sparkler,TEdit,1,%Dia1X%;%Dia1Y%
Wait>0.01
Timer>Stop
If>{%Stop%-%Begin%>5000}
  GoSub>Fade
EndIf
Goto>Loop

SRT>Fade
  SetDialogProperty>Dialog1,,AlphaBlend,True
  Let>Fader=255
  Repeat>Fader
    Sub>Fader,5
    SetDialogProperty>Dialog1,,AlphaBlendValue,Fader
    Wait>0.1
  Until>Fader<0
  Let>Fader=255
  SetDialogProperty>Dialog1,Panel3,Visible,True
  SetDialogProperty>Dialog1,Panel2,Visible,False
  SetDialogProperty>Dialog1,,AlphaBlendValue,Fader
  Wait>3
  Timer>Begin
  GetScreenRes>ScreenX,ScreenY
  While>{%Stop%-%Begin%<10000}
    Timer>Stop
    Random>100,Pct
    Add>pct,1
    Let>Dia1X={round(%ScreenX%*(%pct%/100))}
    Random>100,Pct
    Add>pct,1
    Let>Dia1Y={round(%ScreenY%*(%pct%/100))}
    SetControlText>Sparkler,TEdit,1,%Dia1X%;%Dia1Y%
    Sub>Fader,5
    SetDialogProperty>Dialog1,,AlphaBlendValue,Fader
    Wait>0.2
  EndWhile
  SetControlText>Sparkler,TEdit,1,Complete
  WaitWindowClosed>Sparkler
  Wait>1
  DeleteFile>%temp_dir%Sparkler.scp

  Exit>0
END>Fade

/*
SparkleScript:
Let>size=200

OnEvent>key_down,vk27,0,Quit

SRT>Quit
  Exit>0
END>Quit

Dialog>Dialog2
object Dialog2: TForm
  BorderStyle = bsNone
  Caption = 'Sparkler'
  Color = 1
  TransparentColor = True
  TransparentColorValue = 1
  object Panel1: TPanel
    Left = 0
    Top = 0
    BevelOuter = bvNone
    Caption = 'Panel1'
    Color = 1
    TabOrder = 0
  end
  object Edit1: TEdit
    Text = '-1000;-1000'
    Visible = False
  end
end
EndDialog>Dialog2

Let>WIN_USEHANDLE=1
  MoveWindow>Dialog2.handle,-1000,-1000
Let>WIN_USEHANDLE=0
AddDialogHandler>Dialog2,,OnClose,Quit
SetDialogProperty>Dialog2,,ClientHeight,size
SetDialogProperty>Dialog2,,ClientWidth,size
SetDialogProperty>Dialog2,Panel1,Height,size
SetDialogProperty>Dialog2,Panel1,Width,size
SetDialogProperty>Dialog2,,AlphaBlend,True
SetDialogProperty>Dialog2,,AlphaBlendValue,0
Show>Dialog2

Let>halfSize={round(%size%/2)}
Let>85Per={round(%halfSize%*0.85)}
Let>15Per={round(%halfSize%*0.15)}
Let>ang2=0
Let>kk=0
SetDialogProperty>Dialog2,,AlphaBlendValue,255
Repeat>kk
  GetDialogProperty>Dialog2,Edit1,Text,vPos
  If>vPos=Complete
    Let>kk=-100
    Goto>Done
  EndIf
  Separate>vPos,;,Cur
  Sub>Cur_1,%halfSize%
  Sub>Cur_2,%halfSize%
  MoveWindow>Sparkler,Cur_1,Cur_2
  Add>kk,1
  Random>85Per,res
  Add>res,%15Per%
  Random>50,color
  Add>Color,45500
  Random>90,ang2
  Let>ang2=%ang2%*4
  GoSub>Angle,Dialog2,Panel1,ang2,%halfSize%,%halfSize%,%halfSize%,4,1
  Random>90,ang3
  Let>ang3=%ang3%*4
  GoSub>Angle,Dialog2,Panel1,ang3,%halfSize%,%halfSize%,%halfSize%,4,1
  Random>90,ang
  Let>ang=%ang%*4
  SetDialogProperty>Dialog2,Panel1,caption,space
  GoSub>Angle,Dialog2,Panel1,ang,%halfSize%,%halfSize%,res,2,color
  Label>Done
Until>kk<0

//Angle Usage:
//GoSub>Angle,Dialog,Object,Angle(in degrees),XStart,YStart,Length,PenSize,PenColor
//Requires Drawline subroutine
SRT>Angle
  Let>DegreeAngle=Angle_var_3
  Let>XStart=Angle_var_4
  Let>Ystart=Angle_var_5
  Let>LineLength=Angle_var_6
  Let>RadAngle={%DegreeAngle%*(pi/180)}
  Let>XEnd={trunc((cos(%RadAngle%))*%LineLength%)}
  Let>YEnd={trunc((sin(%RadAngle%))*%LineLength%)}
  Let>XEnd=%XEnd%+%XStart%
  Let>YEnd=%YEnd%+%YStart%
  GoSub>DrawLine,%Angle_var_1%.%Angle_var_2%.Handle,Angle_var_7,Angle_var_8,XStart,YStart,XEnd,YEnd
END>Angle

SRT>DrawLine
  LibFunc>user32,GetDC,HDC,%DrawLine_var_1%
  LibFunc>gdi32,CreatePen,Penres,0,%DrawLine_var_2%,%DrawLine_var_3%
  LibFunc>gdi32,SelectObject,SOPres,hdc,Penres
  Libfunc>gdi32,MoveToEx,mtres,HDC,%DrawLine_var_4%,%DrawLine_var_5%,0
  LibFunc>gdi32,LineTo,ltres,hdc,%DrawLine_var_6%,%DrawLine_var_7%
  LibFunc>gdi32,DeleteObject,DOres,Penres
  LibFunc>user32,ReleaseDC,RDCres,HDC_1,HDC
END>DrawLine
*/

Enjoy! :-)

      Get FREE Consultation



      Archives

  • Categories