2018 bis heute | 2017 2016 2015 2014 | 2013 | 2012 | 2011 2010 2009 | 2008 | 2007

(ältere Archiveinträge vor 2007 nicht dargestellt, aber in der Suche enthalten)

Mailingliste - Einträge 2007


[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: FW: [QF-Test] Help regarding Unknown property dialog


  • Subject: Re: FW: [QF-Test] Help regarding Unknown property dialog
  • From: Martin Moser <martin.moser@?.de>
  • Date: Wed, 04 Apr 2007 12:05:18 +0200

Hi Alfred,

yes, that was my silly mistake :-)

Regards,
Martin

--On Mittwoch, April 04, 2007 03:42:40 -0600 Alfred Mathavan
<amathava@?.com> wrote:

Martin,



I slightly altered your second suggestion and it worked :-)

I changed like this --> print rc.lookup("SwitchGroup", rc.lookup('type'))



Output

['172.31.11.181',]

['172.31.11.182','172.31.11.182',]



Thanks for your support.



Greetings,

Alfred

________________________________

From: Alfred Mathavan
Sent: Wednesday, April 04, 2007 3:06 PM
To: 'Martin Moser'; 'qftest-list@?.de'
Subject: FW: [QF-Test] Help regarding Unknown property dialog



Martin,



Sorry, I got this the following dialog when I used print
rc.lookup("SwitchGroup", str(type))







Greetings,

Alfred



________________________________

From: Alfred Mathavan
Sent: Wednesday, April 04, 2007 3:02 PM
To: 'Martin Moser'; qftest-list@?.de
Subject: RE: [QF-Test] Help regarding Unknown property dialog



Martine,



Thanks for pointing out that silly mistake.



1.)

Line > rc.setLocal('type',"Switch."+str(rc.lookup('switchname')))

There you should use "Switches" instead of Switch :-)



I am sorry, I had taken this code from the previous version :-)



The Corrected code is



rc.setLocal('type',"Switches."+str(rc.lookup('switchname')))



2.)

The syntax ${var} won't make use of variable-expansion in a server
script,

so you have to use the rc.lookup syntax here.

So try this one:

      print rc.lookup("SwitchGroup", str(type))



When I try this I got this dialog.









Any example on variable expansion from a server script and within a
$(GroupName:PropertyName) syntax will help me.



Greetings,

Alfred



-----Original Message-----
From: Martin Moser [mailto:martin.moser@?.de]
Sent: Wednesday, April 04, 2007 1:20 PM
To: qftest-list@?.de
Cc: Alfred Mathavan
Subject: Re: [QF-Test] Help regarding Unknown property dialog



Hello Alfred,



there are two mistakes in your script:



1.)

Line > rc.setLocal('type',"Switch."+str(rc.lookup('switchname')))

There you should use "Switches" instead of Switch :-)



2.)

The syntax ${var} won't make use of variable-expansion in a server
script,

so you have to use the rc.lookup syntax here.

So try this one:

      print rc.lookup("SwitchGroup", str(type))







Regards,

Martin



--On Mittwoch, April 04, 2007 00:18:50 -0600 Alfred Mathavan

<amathava@?.com> wrote:



Hi ,







Senario:-







When I try to fetch a property by substituting dynamic value to the

key(PropertyName) to the syntax $(GroupName:PropertyName) I get an

Unknown property Error Dialog.







Ref:-



Property File Content



Switches.300 = ['172.31.11.181',]



Switches.400 = ['172.31.11.182','172.31.11.182',]



Switches.valueChoices=['300','400',]







Server Script that gets executed in a for loop with respect to the

number of valueChoices







            name = ${SwitchGroup:Switches.valueChoices}[$(i)]



rc.setLocal('switchname',name)







rc.setLocal('type',"Switch."+str(rc.lookup('switchname')))







print rc.lookup('type')

--------------------------------------------------------> Prints

Switches.300



print ${SwitchGroup:Switches.300}

--------------------------------------------------------> Prints

['172.31.11.181']







print ${SwitchGroup:rc.lookup('type')}

------------------------------------------------------->











Could you let me know where I am going wrong?







Greetings,



Alfred











--
Martin Moser                           martin.moser@?.de
Quality First Software GmbH            http://www.qfs.de
Tulpenstr. 41                          Tel: +49 8171 919874
DE-82538 Geretsried                    Fax: +49 8171 919876
GF: Gregor Schmid, Karlheinz Kellerer  HRB München 14083