Contributions
GroovyScript: Getting node value out XML
Hello, Can somebody tell me how i can get a node value out of XML. I want to do that with a groovy script because i have to compaire the values. My xml message is: 9003 Bericht voldoet niet aan AZR-bedrijfsregel 3 3 1 250 3 I want to getall the values between the node : I use the code below, but that didn't work. def groovyUtils = new com.eviware.soapui.support.GroovyUtils( context ) log.info( groovyUtils.projectPath ) //create holder for last response an log requistID def holder = groovyUtils.getXmlHolder( "EI-Bericht#response" ) def strlItems = holder.getNodeValues( "//ns1:Bedrijfsregels") log.info( strlItems["Omschrijving"] ) What do i wrong?????17KViews0likes4CommentsCatch screenshot by log.warning event
How can i catch the picture from log.warning. for example Log.Warning('Warning Message Text', 'Extended Text', pmHighest, nil, Sys.Desktop); When i go to the event i don't see the image path. How can i get the image path from a warning event? Regards Raymond Wiertz Furore.com The Netherlands12KViews0likes0CommentsCatch screenshot by log.warning event
hello How can i catch the picture from log.warning. for example Log.Warning('Warning Message Text', 'Extended Text', pmHighest, nil, Sys.Desktop); When i go to the event i don't see the image path. How can i get the image path from a warning event? Regards Raymond Wiertz Furore.com The Netherlands11KViews0likes1CommentRe: Editing Excel files
Brad, I use the ADO function to read data from excel. So every excel tabsheet i handle as a database table and i can query on it. perhaps this is a solution for your problem. Below i have a example how you can do it. Regards R. Wiertz Quality Assurance Furore.com Procedure ReadFromExcel(aExcelFile : String); var DBConnection : OleVariant; Command : OleVariant; RecordSet : OleVariant; ConnectionString : String; strQuery : String; SheetName : String; iFieldCount : Integer; begin ConnectionString := 'Provider=Microsoft.Jet.OLEDB.4.0;Data Source= ' + aExcelFile + ';Extended Properties="Excel 8.0;HDR=Yes;IMEX=1"'; if Length(aConnectionString) > 0 then begin DBConnection := ADO.CreateConnection(); DBConnection.ConnectionString := aConnectionString; try DBConnection.LoginPrompt := False; except //do nothing, there is no login prompt end; try DBConnection.Open; SheetName := 'Your excel sheet name'; strQuery := 'Select * from ['+SheetName+'$]'; Command := ADO.CreateCommand(); Command.CommandText := Query; Command.ActiveConnection := DBConnection; RecordSet := Command.Execute(); while not aqConvert.VarToBool(RecordSet.EOF) do begin for iFieldCount := 0 to RecordSet.Fields.count -1 do begin Log.message(aqConvert.VarToStr(RecordSet.Fields(iFieldCount).name)); Log.Message(aqConvert.VarToStr(RecordSet.Fields(iFieldCount).Value)); end; end; RecordSet.Close; DBConnection.Close; end;3.6KViews0likes0Comments- 9.2KViews0likes0Comments
- 3.5KViews0likes0Comments
GroovyUtils: Error by declare
When i use the script below i get an error: def groovyUtils = new com.eviware.soapui.support.GroovyUtils( context ) log.info( groovyUtils.projectPath ) The error that i get: Tue May 01 11:35:14 CEST 2007:ERROR:org.codehaus.groovy.control.MultipleCompilationErrorsException: startup failed, Script1.groovy: 10: unable to resolve class com.eviware.soapui.support.GroovyUtils @ line 10, column 19. 1 error Please can you tell me what i do wrong. I use de demo version of SoapUI Pro9.9KViews0likes4Comments