<%@ Page Language="C#" MaintainScrollPositionOnPostBack="true"
AutoEventWireup="true" CodeFile="Default.aspx.cs" Inherits="_Default" %>
or appliying it sitewide thru web.config as:
<system.web>
<pages maintainScrollPositionOnPostBack="true">
</pages>
</system.web>
The script file is included in my page as:
<script type="text/javascript" src="/TestWebsite/WebResource.axd?d=X2ApKqYNd-qiVRFcah5bwg2&t=633437918395970000">
Following is the list of some of the commonly used functions present in the library:
WebForm_GetScrollX
WebForm_GetScrollY
WebForm_SetElementX
WebForm_SetElementY
WebForm_GetElementById
WebForm_SetElementWidth
WebForm_SetElementHeight
WebForm_RemoveClassName
WebForm_AppendToClassName
WebForm_GetParentByTagName
WebForm_GetElementByTagName
WebForm_GetElementsByTagName
WebForm_GetElementPosition - another version here
Hope this is helpful.
pushp
2 comments:
Hi Push,
Mahender here..Godd article dude ..
Home page --> Click on the Link (Opens the second Window)
the below scenario on the second window
I have 7 controls on my second page.
First control : Task Origin (Combo Box)
Second Control: Task Category (Combo Box)
Third Control: Task Type (Text field)
Based on the Task Origin selection Task category combo is filled.
Based on the Task Category selection Task type is derived
After entering the correct value in the Task Type filed (By pressing the TAB) its validate the entry in text field and fill the other 4 fields.
I am able to select the value from Task Category and Task Origin but when I type the value for Task type field it’s not deriving the value for other field.
Console.WriteLine("Task Management Page...");
Static_Decl.i.Span(Find.ById("_ctl0_MainContentPlaceHolder_TaskManagementIndex_CreatePanel_lblPanelHdr")).Click();
//Static_Decl.i.WaitForComplete(10000);
var findby = Find.ByTitle("Create Task");
var TaskCreatePage = Browser.AttachTo(Static_Decl.i.GetType(), findby);
//Task Origin
TaskCreatePage.SelectList("_ctl0_MainContentPlaceHolder_wd_wdDdlTaskOrigin").Click();
TaskCreatePage.SelectList(Find.ById("_ctl0_MainContentPlaceHolder_wd_wdDdlTaskOrigin")).Option(Find.ByValue("TFAUTO")).Select();
// Task Category
TaskCreatePage.SelectList("_ctl0_MainContentPlaceHolder_wd_wdLstBoxCategory").Click();
TaskCreatePage.SelectList("_ctl0_MainContentPlaceHolder_wd_wdLstBoxCategory").Option(Find.ByValue("A")).Select();
// Task Type
TaskCreatePage.TextField(Find.ById("_ctl0_MainContentPlaceHolder_wd_wdLstBoxType")).Click();
TaskCreatePage.TextField(Find.ById("_ctl0_MainContentPlaceHolder_wd_wdLstBoxType")).TypeText("TFA");
TaskCreatePage.TextField(Find.ByName("_ctl0:MainContentPlaceHolder:wd:wdLblWorkIdTxt")).Focus();
Can you help me to overcome this issue?
Post a Comment