I know that DotNetFactory came in QTP 9.x and pretty useful to do thing which might not be easy in just QTP. But i am wondering how many people out there are using this feature and what are they using it for?
Always, all the time. I usually refer to it as the unpublished killer-feature.
I mostly use it to make my life easier, i.e. shorten task that would take 50 code lines with vbscript to 5 lines in .net.
reporting to windows event-log,
coordinating network data-streams between multiple computers,
Other times I just have to use it, usually when the AUT has an object I want to query, but it's wrapped in an interface VBScript can not access. In these cases I write a small .Net dll that converts the object to a suitable data-type, and return it to QTP. Simple, quick, with no extensibility configuration fuss.
I have tried using it to read collections of a .Net 3 control that is available under a different object - e.g. GridColumnHeaders in GridView object rather than directly in WpfGrid. I wasn't that successful as I was unsure how to reference the 'sender' object.
I will probably resort to XML as a way of including some C# code to do the job. Isn't it a pity that the QTP Custom Server template won't install in C# Express edition?
Up till now I have been using DP structures in library functions to manipulate .Net controls. Are you referring more to the use of .Net assemblies in providing more advanced programming functionality - e.g. arrays?
This is very useful thread you initiated Tarun. I have been .Net developer for two years and now using QTP since last one year. It would be great if everyone will share their points about how they are using this feature.
I would surely investigate and put my R&D results over here. Will be great to hear from all.