Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Archived » Jubula » Read Hour and save in Variable.
Read Hour and save in Variable. [message #1437045] Fri, 03 October 2014 20:31 Go to next message
Plinio Froener is currently offline Plinio FroenerFriend
Messages: 13
Registered: May 2014
Junior Member
Hi All,

I want get information of the TIME in machine and save in variable using Jubula.

e.g. now is 15:25:00

VAR1=15
VAR2=25
After that i want to use this variables on the testcases.

Is that possible?

,
thanks in advanced.
Re: Read Hour and save in Variable. [message #1438668 is a reply to message #1437045] Mon, 06 October 2014 10:44 Go to previous messageGo to next message
Achim Loerke is currently offline Achim LoerkeFriend
Messages: 376
Registered: July 2009
Location: Braunschweig, Germany
Senior Member

You can use functions - using the ?func(...) notation in parameter fields - to get the date, format it and get the parts interesting to you. Storing them would be a store value operation on the Application component.

The string handling functions are only partly available in the released version. For some functions you might have to download the source project to add them to your version of Jubula.

- Achim
Re: Read Hour and save in Variable. [message #1439050 is a reply to message #1438668] Mon, 06 October 2014 20:44 Go to previous messageGo to next message
Plinio Froener is currently offline Plinio FroenerFriend
Messages: 13
Registered: May 2014
Junior Member
Hi Achim,

Thank you for your answer !!

I have the release 8.00 version of Jubula installed and these functions enable:

?getCentralTestDataSetValue(dataSetName,keyColumnName,entryKey,columnName)
?formatDate(date,formatString)
?mult(varArg1,varArg2)
?sub(minuend,subtrahend)
?base64Encode(string)
?div(dividend,divisor)
?round(toRound,precision)
?trunc(toTruncate,precision)
?modifyDate(date,offset)
?randomInt(exclusiveMaxValue)
?add(varArg1,varArg2)
?base64Decode(string)
?now()
?uuid()
?replaceAll(string,regex,replacement)
?parseDate(dateString,formatString)
?getNodeAttribute(attributeName)


I can´t get the Time machine using now() function(return only the Date). I miss some functions like "plus" vars and "TIME".

Do you know how could i get and install more functions on my Jubula Version ?




Thanks in advanced,

Plínio





Re: Read Hour and save in Variable. [message #1439762 is a reply to message #1439050] Tue, 07 October 2014 13:36 Go to previous messageGo to next message
David Hickernell is currently offline David HickernellFriend
Messages: 85
Registered: October 2012
Member
Using
?formatDate(?now(),'HH:mm')
works for me.
Re: Read Hour and save in Variable. [message #1439917 is a reply to message #1439762] Tue, 07 October 2014 17:27 Go to previous message
Plinio Froener is currently offline Plinio FroenerFriend
Messages: 13
Registered: May 2014
Junior Member
Thaks a lot David !! It´s working.
Previous Topic:[solved] How to check if a variable is already set?
Next Topic:Error 5009 : Start AUT failed
Goto Forum:
  


Current Time: Wed Sep 25 22:13:38 GMT 2024

Powered by FUDForum. Page generated in 0.03872 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top