Finding Ranorex Path of a System.winforms.forms.control
Posted: Thu Jan 10, 2013 5:30 pm
Hi,
I am trying to make some tools to help in creating wrappers around some of our forms.
I want to find the Ranorex Path for a given System.winforms.forms control say Button such in code
Basically I am trying to find out the code to fill in for the doItBtn_Click event
- Jay
I am trying to make some tools to help in creating wrappers around some of our forms.
I want to find the Ranorex Path for a given System.winforms.forms control say Button such in code
Code: Select all
public class Form1 : System.Windows.Forms.Form
{
public System.Windows.Forms.TextBox myPathTxt = new System.Windows.Forms.TextBox();
public System.Windows.Forms.Button doItBtn = new System.Windows.Forms.Button();
public Form1()
{
this.Size = new Size(200, 100);
this.Text = "Path Finder";
myPathTxt.Location = new Point(10, 10);
doItBtn.Location = new Point(10, 30);
doItBtn.Text = "find path";
this.Controls.Add(myPathTxt);
this.Controls.Add(doItBtn);
doItBtn.Click += new EventHandler(doItBtn_Click);
}
void doItBtn_Click(object sender, EventArgs e)
{
//find Ranorex path for doItBtn
myPathTxt.Text="The path for button";
}
}
- Jay