I have tried this method but it doesnt work:
Login Script:
Print Script:
'This action only views the report
Can anybody tell me how to make this work? Thanks
Login Script:
Code:
Browser("ExxonMobil Authentication").Page("ExxonMobil Authentication").Sync
Browser("ExxonMobil Authentication").Page("ExxonMobil Authentication").WebEdit("username").Set DataTable("username", dtGlobalSheet)
user = Browser("ExxonMobil Authentication").Page("ExxonMobil Authentication").WebEdit("username").GetROProperty(DataTable("username", dtGlobalSheet))
Browser("ExxonMobil Authentication").Page("ExxonMobil Authentication").WebEdit("password").SetSecure DataTable("pwd", dtGlobalSheet)
Browser("ExxonMobil Authentication").Page("ExxonMobil Authentication").WebButton("Login").Click
Browser("ExxonMobil Authentication").Page("Imperial Oil Limited").SyncPrint Script:
'This action only views the report
Code:
If user = "UserB" Then
msgbox "This action cannot be executed"
Else
Browser("Imperial Oil Limited").Page("Imperial Oil Limited").Frame("_sweview").Link("Print").Click
Browser("Reports").Page("Reports").WebList("s_0_1_7_0").Select DataTable("Report_Name", dtLocalSheet)
Browser("Reports").Page("Reports").Link("Run Now").Click
Browser("Reports").Page("Page").Sync
wait(10)
Browser("Reports").Close
Browser("Imperial Oil Limited").Page("Imperial Oil Limited").Sync
End ifCan anybody tell me how to make this work? Thanks

