Web page automation

Ask general questions here.
dxs
Posts: 2
Joined: Wed Nov 01, 2006 9:09 pm

Web page automation

Post by dxs » Wed Nov 01, 2006 9:15 pm

Hi,

I am trying to automate a wedsite and it shows objects when i use Ranorex spy.

I using this code. It is launching notepad and calc, but i when i try to launch IE6 it does not work. Please advice.

using System;
using Ranorex;

namespace Test1
{
/// <summary>
/// Summary description for Class1.
/// </summary>
class Class1
{
/// <summary>
/// The main entry point for the application.
/// </summary>
[STAThread]
static void Main(string[] args)
{
Console.WriteLine("Start Ranorex VS2005 sample1");
Application.Start("iexplore.exe");
//Application.Start("notepad.exe");
//Application.Start("calc.exe");
}
}
}
-Deepak

admin
Site Admin
Site Admin
Posts: 350
Joined: Wed Jul 05, 2006 7:44 pm

Post by admin » Thu Nov 02, 2006 9:02 am

Ranorex can only start an application if the path of it is in the environment variable PATH.
Notepad and calc are in the Windows\System32 directory.
You should add the path of the IE e.g "C:\Program Files\Internet Explorer" to the PATH environment variable as follows (Windows XP):
  • Open the System Properties dialog (My Computer->Properties)
  • Click the Advanced button
  • Click Environment Variables
  • Add the IE path to the PATH environment variable
Gabor Herget
Ranorex Team

dxs
Posts: 2
Joined: Wed Nov 01, 2006 9:09 pm

Post by dxs » Thu Nov 02, 2006 6:13 pm

Thanks for your reply it worked. I also have another question about data verification from the webpages. Can you please post some emaples how to extract data from a table.

Thanks.
-Deepak

admin
Site Admin
Site Admin
Posts: 350
Joined: Wed Jul 05, 2006 7:44 pm

Post by admin » Fri Nov 03, 2006 9:40 am

Take a look at the automate a web page Sample and dump out all elements of the explorerControl. This is shown in the dumping out the element tree Sample.

For further examples send us more detail about your problem.

Gabor Herget
Ranorex Team

User avatar
Support Team
Site Admin
Site Admin
Posts: 11709
Joined: Fri Jul 07, 2006 4:30 pm
Location: Graz, Austria

Post by Support Team » Tue Apr 08, 2008 7:19 am

Please see following link for further information about web automation with Ranorex:

http://www.ranorex.com/products/ranorex ... sting.html

regards,

Christoph
Ranorex Support Team

sam
Posts: 8
Joined: Thu Oct 04, 2007 1:09 am

Post by sam » Sat Jun 14, 2008 11:45 pm

you could use xpath and count the number of table where data are store .when number is know you have to iterate on each table and apply xpath to each cell where data is place .
this need to use the very good ( best) mozilla xpi plug in name web developper ( similar that the ranorex html tool to navigate thrue html hiearchy) that help you to understand how html page is structured even html seem not wellform. so all could be achieve using xpath and rdbms API. Some firefox tool color table limit to help discover repeat structures. this need more code ( enter data in input form , launch button from http server , save html file, apply codec to have xml wellform file, retrieve data , store for each iteration data to another ) .

forget to say that firefox (perhpas ie 7 ) have a xpath editor that let you to know/test which data cell the xpath expression could be view / extract .

xpath is a real language and can support function like those you can find in programming language. regular expression could also be use on all flat file instead xpath which is limited to file that contain tag ( open close).xlink also could be use ....

use this tool ll let ranoorex developper focus of ranorex tool rather than spy tool ( application , web ) . for application think visualstudio have one and some tool specific or not could easy find using search engine to spy the hiearchy of object type/name .


sam