Hi
In this post you have an example how create a custTable lookup on the UIBuilder Class and how assign this to the customer dialogField on the postRun method.
http://axlearn2012.blogspot.com.es/2014/11/110-sobrescribir-los-metodos-de-los.html
At this moment I don't have an Ax2012 but you can check in application searching on the UIBulder Class and postBuild Method..
I think you can recover the value from the range in the postBuild method...you only have to do something like
this.controller().getQuery()...or if you have the query on the contract class this.contract.parmquery()....
and when you have the query you only need to recover the range
may all will be more easy and you only have to use this.getFirstQuery on your lookup method for get the query