Thursday, 13 September 2012

Copy TOAD's Schema comparison sync script

TOAD does not allow you to copy the sync scripts created by it's schema comparison tool unless you shell out for the DBA Modules add in. All you can do is print it to a stupid xps file.

In order to get around this I created a small autoit script to copy the output to your clipboard.

Here is the code

Opt("WinTitleMatchMode", 1)

WinActivate("Toad for Oracle")

$Text=ControlGetText("Toad for Oracle","","[CLASS:TAdvToadSyntaxMemo; INSTANCE:1]")


If $Text Then 

   MsgBox(0,"pwnt","Copied to clip board")


   MsgBox(0,"uh oh","Couldn't copy text. Has the schema comparison been run?")


If need be, I might upload the compiled exe file.