recognizing the same element in different form

Technology specific object identification, supported applications, web technologies, and 3rd party controls.
coyootje
Posts: 2
Joined: Wed Jul 13, 2016 1:10 pm

recognizing the same element in different form

Post by coyootje » Wed Jul 13, 2016 1:24 pm

Hi there,

I'm currently using the evaluation version of Ranorex in order to convince my company of its uses.
We're getting very close to buying it, but there are two issues we keep running into:

1: A case gets a new repository list when its reopened.
2: Ranorex keeps messing up clicks on buttons, the only way to fix this is by adding a move to every step.

I'll further explain the issues down here.

1:
Within the AUT (a case management system) are a couple of different features, the most important one being making new cases. Whenever I make a new case and start entering information into it, it'll work fine. However, sometimes I have to close the case to do other things for a bit. Whenever I come back to the case and start adding things again, the case gets placed in a new repository list. This means I'll end up with two repository lists with the exact same elements, which can be very confusing. Is there any way to merge these lists, so that it'll just always work?

2:
My colleague has a trial key as well, and I'm trying to teach him how to work with Ranorex. Both our Ranorex installations run on a client that has to be reached via remote desktop connection (they're installed on the client). Whenever I record a test script, everything runs just fine. However, when my colleague tries to do the same, it's like a whole different experience. Ranorex starts to miss clicks on buttons, it'll just move towards it and get stuck afterwards because the button didn't get pressed. The only way I've found so far to fix this is by adding moves before every step with the same coordinates as the mouse click. Is there any way to fix this? I've searched around for a bit but it's tough to find the reason why it behaves differently.


I really hope there's some way to fix this, my company's going to make the decision about Ranorex in two days and I'm afraid they'll decide not to because of these two issues. Thanks in advance!

User avatar
Support Team
Site Admin
Site Admin
Posts: 12145
Joined: Fri Jul 07, 2006 4:30 pm
Location: Houston, Texas, USA
Contact:

Re: recognizing the same element in different form

Post by Support Team » Thu Jul 14, 2016 2:58 pm

Hi coyootje,

Welcome to our Ranorex Forum. Unfortunately it is hard to analyze such issues without having detailed information about the application under test. Therefore, it would be great if you could attach a Ranorex snapshot made before and after re-opening the case in your application.
Concerning the second point,
May I ask you if you already have de-activated the setting 'Use asynchronous dispatching of mouse and keyboard events' which can be found in the Advanced tab in the global settings?

PS: If you don't want to upload your Snapshots in this public forum, you can send it to [email protected]

Regards,
Markus (S)

coyootje
Posts: 2
Joined: Wed Jul 13, 2016 1:10 pm

Re: recognizing the same element in different form

Post by coyootje » Fri Jul 15, 2016 10:41 am

Hey Markus,

thanks for the quick reply!
I've been doing some research myself and I seem to have found the issues causing both the problems. The first problem was caused by the fact that the form names are different, even though the screens look the same. I fixed this by changing the identifying factor of the repository element (the base screen) for both screens.

The second problem seems to be caused by the fact that the second client has less RAM memory than the other. I'm going to test allocating some extra RAM to the second client to see if this fixes it.

The purchase of Ranorex seems to be a done deal. I do have another question however:
Our test reports are stored in a shared folder; after running the tests a mail is sent to notify my colleagues about the completion of the test and where to find the test report. I want to add some more functionality to the email though: is there an easy way to add the test status (fail or success) to the email? I'd prefer it to be something along the lines of:

"There's been a testrun on the nightly build. The test was completed with the status STATUS. The test report can be found here (TEST REPORT LOCATION)."

The test report location is static so that's no problem, but adding the status is a little tricky. I'm not that good at coding (I only have a SendEmail module because it was shared on the forum :D ) so a bit of help would be hugely appreciated.

Edit: I'll be able to provide the SendMailGmail code module that we're using for the emails in a bit. It might help clarify the kind of changes that are needed in order to make it work. I'll upload them in 1-1,5 hours.

Edit 2: here you go!

Code: Select all

        public void SendMail()  
        {  
        	var fromAddress = new MailAddress("company email", "Automatic test Ranorex");            
            const string fromPassword = "Password";  
            const string subject = "testrun Ranorex";  
            const string body = "message";  
            SmtpClient smtp = new SmtpClient()
            {  
                Host = "smtp.gmail.com",  
                Port = 587,  
                EnableSsl = true,  
                DeliveryMethod = SmtpDeliveryMethod.Network,  
                UseDefaultCredentials = false,  
                Credentials = new NetworkCredential(fromAddress.Address, fromPassword)  
            };  

			var message = new MailMessage();
            message.From = fromAddress;
            message.To.Add(new MailAddress("email 1", "name 1"));
            message.To.Add(new MailAddress("email 2", "name 2"));
            message.To.Add(new MailAddress("email 3", "name 3"));
            message.Subject = subject;
            message.Body = body;
            smtp.Send(message);

User avatar
Support Team
Site Admin
Site Admin
Posts: 12145
Joined: Fri Jul 07, 2006 4:30 pm
Location: Houston, Texas, USA
Contact:

Re: recognizing the same element in different form

Post by Support Team » Tue Jul 19, 2016 12:14 pm

Hi coyootje,

Thank you for your update. I'm glad that you were able to overcome your initial issues.

Concerning the status of a test run. Unfortunately this would require usage of our internal API. Nevertheless, if you would get in touch with me by email ([email protected]), we could discuss this scenario in more detail.

Thank you for your understanding.

Regards,
Markus (S)