Wednesday, July 3, 2013

AJAX Protocol in Load runner

AJAX (Asynchronous JavaScript and XML) is a technique for creating interactive Web applications. With AJAX, Web pages exchange small packets of data with the server, instead of reloading an entire page. This reduces the amount of time that a user needs to wait when requesting data. It also increases the interactive capabilities and enhances the usability.
Using AJAX, developers can create fast Web pages using Javascript and asynchronous server requests. The requests can originate from user actions,timer events, or other predefined triggers.AJAX components, also known as AJAX controls, are GUI based controls that use the AJAX technique—they send a request to the server when trigger occurs.

For example, a popular AJAX control is a Reorder List control that lets you drag components to a desired position in a list. VuGen’s support for AJAX implementation is based on Microsoft’s ASP.NET AJAX Control Toolkit formerly known as Atlas.

AJAX Supported Frameworks

The supported frameworks for AJAX functions are:
  • Atlas 1.0.10920.0/ASP.NET AJAX—All controls
  • Scriptaculous 1.8—Autocomplete, Reorder List, and Slider


VuGen supports the following frameworks at the engine level. This implies
that VuGen will create standard Web Click and Script steps, but not AJAX
specific functions:
  •  Prototype 1.6
  •  Google Web Toolkit (GWT) 1.4


AJAX Example Script

VuGen uses the control handler layer to create the effect of an operation on a GUI control. During recording, when encountering one of the supported AJAX controls, VuGen generates a function with an ajax_xxx prefix. In the following example, a user selected item number 1 (index=1) in an
Accordion control. VuGen generated an ajax_accordion function.

Note: When you record an AJAX session, VuGen generates standard Web (Click and Script) functions for objects that are not one of the supported AJAX controls. In the example above, the word FILE_PATH was typed into an edit box.

web_browser("Accordion.aspx",

DESCRIPTION,
ACTION,
"Navigate=http://labm1app08/AJAX/Accordion/Accordion.aspx",
LAST);
lr_think_time(5);
ajax_accordion("Accordion",
DESCRIPTION,
"Framework=atlas",
"ID=ctl00_SampleContent_MyAccordion",
ACTION,
"UserAction=SelectIndex",
"Index=1",
LAST);
web_edit_field("free_text_2",
"Snapshot=t18.inf",
DESCRIPTION,
"Type=text",
"Name=free_text",
ACTION,
"SetValue=FILE_PATH",
LAST);

 Note: When you record an AJAX session, VuGen generates standard Web (Click and Script) functions for objects that are not one of the supported AJAX controls. In the example above, the word FILE_PATH was typed into an edit box.

2 comments:

Anonymous said...

Please help me on correlation for below example

Example: i have one application development is using ajax calls for drop down to counties, based on the country selected state will populate, based on the state district populate. here boundaries for all these fields are same did correlation for country, state for district.

how i can work please help?

Anonymous said...

please help on one of our application there are using ajax calls for the drop down

example: based on the country selected state will populate, based on the selection of state ..district drop down values will populate & boundaries also same for all these boundaries