Dynamically modify the content of a web form in SilkPerformer

In today’s post my friend and co-worker Mark McCorkle writes about SilkPerformer’s WebFormValuePairInsert function. This function can be used to dynamically modify the content of a Web form:

WebFormValuePairInsert ( in fForm : form ,
                                           in sLeftValue : string ,
                                           in sRightValue : string ,
                                           in nPosition : number optional ,
                                           in nAttribute : number optional ): boolean ;

Mark writes:
Silk Performer has this function I’ve never had to use before, but considering the number of forms Corillian uses, it has proven be useful in a recent performance test:

WebFormValuePairInsert(ACCOUNTHISTORY, “ctlAccountDownloadFilterList:ctlAccountsDataGrid:_ctl” + strTemp + “:chkSelect”, “on”);

In the above example, in the form “AccountHistory”, I’m adding a dynamically checkbox element and setting it to “on”.

This was helpful in my particular situation because based on the user you log on with, the number of accounts you can select from is dynamic. If I want more than one selected, I can’t hardcode any of that from user to user, so, I’ve got to do it this way. And, it also allows me to perhaps randomly turn them on and off as needed.

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.