cancel
Showing results for 
Search instead for 
Did you mean: 

Ho do i calculate the time elapsed before a report is loaded.

Highlighted
Regular Contributor

Ho do i calculate the time elapsed before a report is loaded.

Hi,

 i want to calcualte the number of minutes elapsed before a pdf report opens or loads with TC.

I am using Visual basic for my scripts.

If any body knows , please suggest.


11 REPLIES 11
Highlighted
Regular Contributor

RE: Ho do i calculate the time elapsed before a report is loaded.

Hi this is the path of the image of run report where i click on to load the report it is showing in the name mapping.



Aliases.iexplore.pageFameFinancialAidPrintFafsaRe.formAspnetform.panelCtl00RadsplitterMain.tableRadSplitterCtl00Radsplitter.cellCtl00RadpaneMiddle.panelRadSplitterPaneContentCtl00.panelCtl00Ctl00Radapanlpanel.panelCtl00Radapanl.panelClwycontent.panelSearchcontent.panelClwysearchgrid.panelCtl00Contentplaceholder1Grd.tableCtl00Contentplaceholder1Grd.cell.imagebuttonCtl00Contentplacehold



How can i use the stop watch to get the elapse time to load the report.
Highlighted
Regular Contributor

RE: Ho do i calculate the time elapsed before a report is loaded.

This is the keyword test steps where i am clicking on the image to runt he report.



panelCtl00Contentplaceholder1Rad ClickItem "Search", ... Clicks the 'Search' item of the 'panelCtl00Contentplaceholder1Rad' bar.

imagebuttonCtl00Contentplacehold Click ... Clicks the 'imagebuttonCtl00Contentplacehold' control.
Highlighted
Regular Contributor

RE: Ho do i calculate the time elapsed before a report is loaded.

Hi



I tried this to wait until the property textnodeReportViewer appears . Thta works. But i want to specify the time to wait , so i tried the second statement , it is not working.



Can anybody please tell me how to use the wait property to wait untill that propery appears.



This is what looks like in name mapping.



Object Type: TextNode

Inner text :Report Viewer

Object identification: 0

 




Aliases
.iexplore.pageFameFinancialAidPrintFafsaRe.formAspnetform.panelRadwindowwrapperCtl00Conten.table.cellRwtitlebar.tableRwtitlebarcontrols.cell1.WaitAliasChild(textnodeReportViewer)

 


 


 



 



' if Aliases.iexplore.pageFameFinancialAidPrintFafsaRe.formAspnetform.panelRadwindowwrapperCtl00Conten.table.cellRwtitlebar.tableRwtitlebarcontrols.cell1.WaitChild(textnodeReportViewer,120000).Exists then

 




if



 



Aliases.iexplore.pageFameFinancialAidPrintFafsaRe.formAspnetform.panelRadwindowwrapperCtl00Conten.table.cellRwtitlebar.tableRwtitlebarcontrols.cell1.textnodeReportViewer.Exists Then

 


Highlighted
Regular Contributor

RE: Ho do i calculate the time elapsed before a report is loaded.

I am waiting for this to continue with my script please.



Please let me know in this case how can i use wait property or wait alias child or wait child propery. it is not allowing me to give the time in milli secs..
Highlighted
Contributor

RE: Ho do i calculate the time elapsed before a report is loaded.

You're using the WaitAliasChild method incorrectly. First of all, the child name parameter should be a string. Secondly, the method returns an object that represents the child, if it was found within the time specified, so it is that object's Exist property that you should be checking.



I'm most comfortable with JScript, but you should get the idea from this:

cell = Aliases.iexplore.pageFameFinancialAidPrintFafsaRe.formAspnetform.panelRadwindowwrapperCtl00Conten.table.cellRwtitlebar.tableRwtitlebarcontrols.cell1;

cellContent = cell.WaitAliasChild("textnodeReportViewer", 120000);

if(cellContent.Exists)

{

//found it

}




Highlighted
Contributor

RE: Ho do i calculate the time elapsed before a report is loaded.

By the way, there's really no need to be using such long and unwieldy object names. Aliases are supposed to help you avoid that by letting you specify nice friendly names, and by letting you leave out the levels of the tree that you don't need to refer to.
Highlighted
Regular Contributor

RE: Ho do i calculate the time elapsed before a report is loaded.

Hi Tony,



I got the Alias name by going to name mapping node page and by clicking on the cell1 object i am checking which has that child . That is what it displayed on the top right side.

How else can i get the shorter and friendly name than this. Please suggest .  I will be haapy to use it.

 
Highlighted
Contributor

RE: Ho do i calculate the time elapsed before a report is loaded.

On the name mapping editor, you have an upper and a lower pane. The upper pane shows all the mapped objects. The lower pane shows all the aliases you've created for them. But you don't actually need to create an alias for every object; it's optional. So, if your upper tree shows something like this:

Sys

..iexplore

....pageFameFinancialAidPrintFafsaRe

......formAspnetform

........panelRadwindowwrapperCtl00Conten

..........table

............cellRwtitlebar

..............tableRwtitlebarcontrols

................cell1



Your alias tree doesn't have to show all those objects if you don't want them to. My guess is that you'll never have to deal directly with the "formAspnetform" or "panelRadwindowwrapperCtl00Conten" objects, in which case you could just leave them out and make your alias tree look something like this:

pageFinancialAid

..table

....cell1



Then in scripts you can refer to the cell1 object using the shorter name, Aliases.pageFinancialAid.table.cell1




Highlighted
Regular Contributor

RE: Ho do i calculate the time elapsed before a report is loaded.

Hi Tony,



So you mean we can control how it can appear in the nema mapping under Aliases. Cna you please explai how can i do that.
New Here?
Join us and watch the welcome video:
Announcements
Top Kudoed Authors