Thanks Alex for your reply.
I have upgraded to 2.2.1 (Thanks).
Still ranorex is not detecting the buttons when I compile.
I have attached the repository.
This is the error log:
2009/12/15 13:21:18.203 FAILURE Validation Element for item 'BT_MyFace_LOL' does not exist (Failed to find item 'BT_MyFace_LOL' within the specified timeout of 10s.).
2009/12/15 13:21:18.203 ERROR User Ranorex.ValidationException: Element for item 'BT_MyFace_LOL' does not exist (Failed to find item 'BT_MyFace_LOL' within the specified timeout of 10s.).
at Ranorex.Validate.IsTrue(Boolean condition, String message, Boolean exceptionOnFail)
at Ranorex.Validate.Exists(RepoItemInfo itemInfo, String message, Boolean exceptionOnFail)
at Ranorex.Validate.Exists(RepoItemInfo itemInfo)
at Search_Assistant.verify.VerifyToolbar() in c:\Documents and Settings\ishtiaq\My Documents\Ranorex Scripts\XP\IE7\Search_Assistant\Search_Assistant\verify.UserCode.cs:line 40
at Search_Assistant.verify.Start() in c:\Documents and Settings\ishtiaq\My Documents\Ranorex Scripts\XP\IE7\Search_Assistant\Search_Assistant\verify.cs:line 37
at Search_Assistant.Program.Main(String[] args) in c:\Documents and Settings\ishtiaq\My Documents\Ranorex Scripts\XP\IE7\Search_Assistant\Search_Assistant\Program.cs:line 37
Repository:
Code: Select all
///////////////////////////////////////////////////////////////////////////////
//
// This file was automatically generated by RANOREX.
// DO NOT MODIFY THIS FILE! It is regenerated by the designer.
// All your modifications will be lost!
// http://www.ranorex.com
//
///////////////////////////////////////////////////////////////////////////////
using System;
using System.Collections.Generic;
using System.Text;
using System.Drawing;
using Ranorex;
using Ranorex.Core;
using Ranorex.Core.Repository;
namespace Search_Assistant
{
/// <summary>
/// The class representing the Search_AssistantRepository element repository.
/// </summary>
[System.CodeDom.Compiler.GeneratedCode("Ranorex", "2.2.0")]
public partial class Search_AssistantRepository : RepoGenBaseFolder
{
static Search_AssistantRepository instance;
/// <summary>
/// Gets the singleton class instance representing the Search_AssistantRepository element repository.
/// </summary>
public static Search_AssistantRepository Instance {
get { return instance; }
}
/// <summary>
/// Repository class static constructor.
/// </summary>
static Search_AssistantRepository()
{
instance = new Search_AssistantRepository();
}
Search_AssistantRepositoryFolders.BrowserWindowAppFolder _browserwindow;
Search_AssistantRepositoryFolders.File_DownloadAppFolder _file_download;
Search_AssistantRepositoryFolders.Security_WarningAppFolder _security_warning;
Search_AssistantRepositoryFolders.Terms_and_ConditionsAppFolder _terms_and_conditions;
Search_AssistantRepositoryFolders.MyWebTattooAppFolder _mywebtattoo;
/// <summary>
/// Repository class constructor.
/// </summary>
private Search_AssistantRepository() : base("Search_AssistantRepository", "", null, 30000, false)
{
_browserwindow = new Search_AssistantRepositoryFolders.BrowserWindowAppFolder(null);
_file_download = new Search_AssistantRepositoryFolders.File_DownloadAppFolder(null);
_security_warning = new Search_AssistantRepositoryFolders.Security_WarningAppFolder(null);
_terms_and_conditions = new Search_AssistantRepositoryFolders.Terms_and_ConditionsAppFolder(null);
_mywebtattoo = new Search_AssistantRepositoryFolders.MyWebTattooAppFolder(null);
}
/// <summary>
/// The BrowserWindow folder.
/// </summary>
public virtual Search_AssistantRepositoryFolders.BrowserWindowAppFolder BrowserWindow
{
get { return _browserwindow; }
}
/// <summary>
/// The File_Download folder.
/// </summary>
public virtual Search_AssistantRepositoryFolders.File_DownloadAppFolder File_Download
{
get { return _file_download; }
}
/// <summary>
/// The Security_Warning folder.
/// </summary>
public virtual Search_AssistantRepositoryFolders.Security_WarningAppFolder Security_Warning
{
get { return _security_warning; }
}
/// <summary>
/// The Terms_and_Conditions folder.
/// </summary>
public virtual Search_AssistantRepositoryFolders.Terms_and_ConditionsAppFolder Terms_and_Conditions
{
get { return _terms_and_conditions; }
}
/// <summary>
/// The MyWebTattoo folder.
/// </summary>
public virtual Search_AssistantRepositoryFolders.MyWebTattooAppFolder MyWebTattoo
{
get { return _mywebtattoo; }
}
}
/// <summary>
/// Inner folder classes.
/// </summary>
public partial class Search_AssistantRepositoryFolders
{
/// <summary>
/// The BrowserWindowAppFolder folder.
/// </summary>
public partial class BrowserWindowAppFolder : RepoGenBaseFolder
{
private Search_AssistantRepositoryFolders.FBS_barFolder _fbs_bar;
private RepoItemInfo _url_barInfo;
private RepoItemInfo _tb_barInfo;
private RepoItemInfo _sr_barInfo;
private RepoItemInfo _no_resultInfo;
private RepoItemInfo _yes_resultInfo;
private RepoItemInfo _wholetoolbarInfo;
private RepoItemInfo _selfInfo;
/// <summary>
/// Creates a new BrowserWindow folder.
/// </summary>
public BrowserWindowAppFolder(RepoGenBaseFolder parentFolder) :
base("BrowserWindow", "/form[@title~'Windows Internet Explorer']", null, 30000, true)
{
_fbs_bar = new Search_AssistantRepositoryFolders.FBS_barFolder(this);
_url_barInfo = new RepoItemInfo(this, "URL_bar", "element[@class='WorkerW']/form/element[@controlid='41477']/combobox/text[@controlid='41477']", 10000, null);
_tb_barInfo = new RepoItemInfo(this, "TB_bar", "element[@class='InternetToolbarHost']/*/*/*/element[@controlid='1025']/text[@controlid='1001']", 10000, null);
_sr_barInfo = new RepoItemInfo(this, "SR_bar", "element[@class='WorkerW']/*/element[@class='UniversalSearchBand']/*/*/text[@class='Edit']", 10000, null);
_no_resultInfo = new RepoItemInfo(this, "no_result", ".//div[@innertext~'^Sorry,\\ no\\ search\\ results\\ ']", 10000, null);
_yes_resultInfo = new RepoItemInfo(this, "yes_result", ".//p[@innertext='Search Results by: ']", 10000, null);
_wholetoolbarInfo = new RepoItemInfo(this, "WholeToolbar", ".//toolbar[@accessiblerole='ToolBar']", 10000, null);
_selfInfo = new RepoItemInfo(this, "Self", "", 30000, null);
}
/// <summary>
/// The URL_bar item.
/// </summary>
public virtual Ranorex.Text URL_bar
{
get
{
return _url_barInfo.CreateAdapter<Ranorex.Text>(true);
}
}
/// <summary>
/// The URL_bar item info.
/// </summary>
public virtual RepoItemInfo URL_barInfo
{
get
{
return _url_barInfo;
}
}
/// <summary>
/// The TB_bar item.
/// </summary>
public virtual Ranorex.Text TB_bar
{
get
{
return _tb_barInfo.CreateAdapter<Ranorex.Text>(true);
}
}
/// <summary>
/// The TB_bar item info.
/// </summary>
public virtual RepoItemInfo TB_barInfo
{
get
{
return _tb_barInfo;
}
}
/// <summary>
/// The SR_bar item.
/// </summary>
public virtual Ranorex.Text SR_bar
{
get
{
return _sr_barInfo.CreateAdapter<Ranorex.Text>(true);
}
}
/// <summary>
/// The SR_bar item info.
/// </summary>
public virtual RepoItemInfo SR_barInfo
{
get
{
return _sr_barInfo;
}
}
/// <summary>
/// The no_result item.
/// </summary>
public virtual Ranorex.DivTag no_result
{
get
{
return _no_resultInfo.CreateAdapter<Ranorex.DivTag>(true);
}
}
/// <summary>
/// The no_result item info.
/// </summary>
public virtual RepoItemInfo no_resultInfo
{
get
{
return _no_resultInfo;
}
}
/// <summary>
/// The yes_result item.
/// </summary>
public virtual Ranorex.PTag yes_result
{
get
{
return _yes_resultInfo.CreateAdapter<Ranorex.PTag>(true);
}
}
/// <summary>
/// The yes_result item info.
/// </summary>
public virtual RepoItemInfo yes_resultInfo
{
get
{
return _yes_resultInfo;
}
}
/// <summary>
/// The WholeToolbar item.
/// </summary>
public virtual Ranorex.ToolBar WholeToolbar
{
get
{
return _wholetoolbarInfo.CreateAdapter<Ranorex.ToolBar>(true);
}
}
/// <summary>
/// The WholeToolbar item info.
/// </summary>
public virtual RepoItemInfo WholeToolbarInfo
{
get
{
return _wholetoolbarInfo;
}
}
/// <summary>
/// The Self item.
/// </summary>
public virtual Ranorex.Form Self
{
get
{
return _selfInfo.CreateAdapter<Ranorex.Form>(true);
}
}
/// <summary>
/// The Self item info.
/// </summary>
public virtual RepoItemInfo SelfInfo
{
get
{
return _selfInfo;
}
}
/// <summary>
/// The FBS_bar folder.
/// </summary>
public virtual Search_AssistantRepositoryFolders.FBS_barFolder FBS_bar
{
get { return _fbs_bar; }
}
}
/// <summary>
/// The FBS_barFolder folder.
/// </summary>
public partial class FBS_barFolder : RepoGenBaseFolder
{
private RepoItemInfo _bt_add_buttonsInfo;
private RepoItemInfo _bt_myface_lolInfo;
private RepoItemInfo _bt_tattoodleInfo;
private RepoItemInfo _bt_wallpaperInfo;
private RepoItemInfo _bt_tattoosInfo;
private RepoItemInfo _bt_tattoonsInfo;
private RepoItemInfo _selfInfo;
/// <summary>
/// Creates a new FBS_bar folder.
/// </summary>
public FBS_barFolder(RepoGenBaseFolder parentFolder) :
base("FBS_bar", "element[@class='InternetToolbarHost']/*/*/*/toolbar", parentFolder, 10000, false)
{
_bt_add_buttonsInfo = new RepoItemInfo(this, "BT_Add_Buttons", "button[@accessiblename='Add Buttons']", 10000, null);
_bt_myface_lolInfo = new RepoItemInfo(this, "BT_MyFace_LOL", "button[@accessiblename='MyFace LOL']", 10000, null);
_bt_tattoodleInfo = new RepoItemInfo(this, "BT_Tattoodle", "button[@accessiblename='Tattoodle']", 10000, null);
_bt_wallpaperInfo = new RepoItemInfo(this, "BT_Wallpaper", "button[@accessiblename='Wallpaper']", 10000, null);
_bt_tattoosInfo = new RepoItemInfo(this, "BT_Tattoos", "button[@accessiblename='Tattoos']", 10000, null);
_bt_tattoonsInfo = new RepoItemInfo(this, "BT_Tattoons", ".//button[6]", 10000, null);
_selfInfo = new RepoItemInfo(this, "Self", "", 10000, null);
}
/// <summary>
/// The BT_Add_Buttons item.
/// </summary>
public virtual Ranorex.Button BT_Add_Buttons
{
get
{
return _bt_add_buttonsInfo.CreateAdapter<Ranorex.Button>(true);
}
}
/// <summary>
/// The BT_Add_Buttons item info.
/// </summary>
public virtual RepoItemInfo BT_Add_ButtonsInfo
{
get
{
return _bt_add_buttonsInfo;
}
}
/// <summary>
/// The BT_MyFace_LOL item.
/// </summary>
public virtual Ranorex.Button BT_MyFace_LOL
{
get
{
return _bt_myface_lolInfo.CreateAdapter<Ranorex.Button>(true);
}
}
/// <summary>
/// The BT_MyFace_LOL item info.
/// </summary>
public virtual RepoItemInfo BT_MyFace_LOLInfo
{
get
{
return _bt_myface_lolInfo;
}
}
/// <summary>
/// The BT_Tattoodle item.
/// </summary>
public virtual Ranorex.Button BT_Tattoodle
{
get
{
return _bt_tattoodleInfo.CreateAdapter<Ranorex.Button>(true);
}
}
/// <summary>
/// The BT_Tattoodle item info.
/// </summary>
public virtual RepoItemInfo BT_TattoodleInfo
{
get
{
return _bt_tattoodleInfo;
}
}
/// <summary>
/// The BT_Wallpaper item.
/// </summary>
public virtual Ranorex.Button BT_Wallpaper
{
get
{
return _bt_wallpaperInfo.CreateAdapter<Ranorex.Button>(true);
}
}
/// <summary>
/// The BT_Wallpaper item info.
/// </summary>
public virtual RepoItemInfo BT_WallpaperInfo
{
get
{
return _bt_wallpaperInfo;
}
}
/// <summary>
/// The BT_Tattoos item.
/// </summary>
public virtual Ranorex.Button BT_Tattoos
{
get
{
return _bt_tattoosInfo.CreateAdapter<Ranorex.Button>(true);
}
}
/// <summary>
/// The BT_Tattoos item info.
/// </summary>
public virtual RepoItemInfo BT_TattoosInfo
{
get
{
return _bt_tattoosInfo;
}
}
/// <summary>
/// The BT_Tattoons item.
/// </summary>
public virtual Ranorex.Button BT_Tattoons
{
get
{
return _bt_tattoonsInfo.CreateAdapter<Ranorex.Button>(true);
}
}
/// <summary>
/// The BT_Tattoons item info.
/// </summary>
public virtual RepoItemInfo BT_TattoonsInfo
{
get
{
return _bt_tattoonsInfo;
}
}
/// <summary>
/// The Self item.
/// </summary>
public virtual Ranorex.ToolBar Self
{
get
{
return _selfInfo.CreateAdapter<Ranorex.ToolBar>(true);
}
}
/// <summary>
/// The Self item info.
/// </summary>
public virtual RepoItemInfo SelfInfo
{
get
{
return _selfInfo;
}
}
}
/// <summary>
/// The File_DownloadAppFolder folder.
/// </summary>
public partial class File_DownloadAppFolder : RepoGenBaseFolder
{
private RepoItemInfo _btrunInfo;
private RepoItemInfo _selfInfo;
/// <summary>
/// Creates a new File_Download folder.
/// </summary>
public File_DownloadAppFolder(RepoGenBaseFolder parentFolder) :
base("File_Download", "/form[@title~'^File Download']", null, 30000, true)
{
_btrunInfo = new RepoItemInfo(this, "BTrun", "button[@text='&Run']", 10000, null);
_selfInfo = new RepoItemInfo(this, "Self", "", 30000, null);
}
/// <summary>
/// The BTrun item.
/// </summary>
public virtual Ranorex.Button BTrun
{
get
{
return _btrunInfo.CreateAdapter<Ranorex.Button>(true);
}
}
/// <summary>
/// The BTrun item info.
/// </summary>
public virtual RepoItemInfo BTrunInfo
{
get
{
return _btrunInfo;
}
}
/// <summary>
/// The Self item.
/// </summary>
public virtual Ranorex.Form Self
{
get
{
return _selfInfo.CreateAdapter<Ranorex.Form>(true);
}
}
/// <summary>
/// The Self item info.
/// </summary>
public virtual RepoItemInfo SelfInfo
{
get
{
return _selfInfo;
}
}
}
/// <summary>
/// The Security_WarningAppFolder folder.
/// </summary>
public partial class Security_WarningAppFolder : RepoGenBaseFolder
{
private RepoItemInfo _btrun2Info;
private RepoItemInfo _selfInfo;
/// <summary>
/// Creates a new Security_Warning folder.
/// </summary>
public Security_WarningAppFolder(RepoGenBaseFolder parentFolder) :
base("Security_Warning", "/form[@title~'Security Warning']", null, 30000, true)
{
_btrun2Info = new RepoItemInfo(this, "BTrun2", "button[@text='&Run']", 10000, null);
_selfInfo = new RepoItemInfo(this, "Self", "", 30000, null);
}
/// <summary>
/// The BTrun2 item.
/// </summary>
public virtual Ranorex.Button BTrun2
{
get
{
return _btrun2Info.CreateAdapter<Ranorex.Button>(true);
}
}
/// <summary>
/// The BTrun2 item info.
/// </summary>
public virtual RepoItemInfo BTrun2Info
{
get
{
return _btrun2Info;
}
}
/// <summary>
/// The Self item.
/// </summary>
public virtual Ranorex.Form Self
{
get
{
return _selfInfo.CreateAdapter<Ranorex.Form>(true);
}
}
/// <summary>
/// The Self item info.
/// </summary>
public virtual RepoItemInfo SelfInfo
{
get
{
return _selfInfo;
}
}
}
/// <summary>
/// The Terms_and_ConditionsAppFolder folder.
/// </summary>
public partial class Terms_and_ConditionsAppFolder : RepoGenBaseFolder
{
private RepoItemInfo _btiagreeInfo;
private RepoItemInfo _btnextInfo;
private RepoItemInfo _selfInfo;
/// <summary>
/// Creates a new Terms_and_Conditions folder.
/// </summary>
public Terms_and_ConditionsAppFolder(RepoGenBaseFolder parentFolder) :
base("Terms_and_Conditions", "/form[@title='My Web Tattoo']", null, 30000, true)
{
_btiagreeInfo = new RepoItemInfo(this, "BTiagree", "button[@text='I Agree']", 10000, null);
_btnextInfo = new RepoItemInfo(this, "BTnext", "button[@text='Next']", 10000, null);
_selfInfo = new RepoItemInfo(this, "Self", "", 30000, null);
}
/// <summary>
/// The BTiagree item.
/// </summary>
public virtual Ranorex.Button BTiagree
{
get
{
return _btiagreeInfo.CreateAdapter<Ranorex.Button>(true);
}
}
/// <summary>
/// The BTiagree item info.
/// </summary>
public virtual RepoItemInfo BTiagreeInfo
{
get
{
return _btiagreeInfo;
}
}
/// <summary>
/// The BTnext item.
/// </summary>
public virtual Ranorex.Button BTnext
{
get
{
return _btnextInfo.CreateAdapter<Ranorex.Button>(true);
}
}
/// <summary>
/// The BTnext item info.
/// </summary>
public virtual RepoItemInfo BTnextInfo
{
get
{
return _btnextInfo;
}
}
/// <summary>
/// The Self item.
/// </summary>
public virtual Ranorex.Form Self
{
get
{
return _selfInfo.CreateAdapter<Ranorex.Form>(true);
}
}
/// <summary>
/// The Self item info.
/// </summary>
public virtual RepoItemInfo SelfInfo
{
get
{
return _selfInfo;
}
}
}
/// <summary>
/// The MyWebTattooAppFolder folder.
/// </summary>
public partial class MyWebTattooAppFolder : RepoGenBaseFolder
{
private RepoItemInfo _btclickhereInfo;
private RepoItemInfo _selfInfo;
/// <summary>
/// Creates a new MyWebTattoo folder.
/// </summary>
public MyWebTattooAppFolder(RepoGenBaseFolder parentFolder) :
base("MyWebTattoo", "/dom[@caption='My Web Tattoo']", null, 30000, true)
{
_btclickhereInfo = new RepoItemInfo(this, "BTclickhere", "body/form/div[@id='pnltop']/div[@id='container']/div/div[@id='button']/input[@id='ibClickHere']", 10000, null);
_selfInfo = new RepoItemInfo(this, "Self", "", 30000, null);
}
/// <summary>
/// The BTclickhere item.
/// </summary>
public virtual Ranorex.InputTag BTclickhere
{
get
{
return _btclickhereInfo.CreateAdapter<Ranorex.InputTag>(true);
}
}
/// <summary>
/// The BTclickhere item info.
/// </summary>
public virtual RepoItemInfo BTclickhereInfo
{
get
{
return _btclickhereInfo;
}
}
/// <summary>
/// The Self item.
/// </summary>
public virtual Ranorex.WebDocument Self
{
get
{
return _selfInfo.CreateAdapter<Ranorex.WebDocument>(true);
}
}
/// <summary>
/// The Self item info.
/// </summary>
public virtual RepoItemInfo SelfInfo
{
get
{
return _selfInfo;
}
}
}
}
}
Thanks.