Report To PDF issues- error on build

Ranorex Spy, Recorder, and Studio.
jojomonsta
Posts: 12
Joined: Wed May 27, 2015 9:53 am

Report To PDF issues- error on build

Post by jojomonsta » Mon Mar 13, 2017 6:37 pm

Hi there
I am banging my head against a wall here, so please point me in the right direction.

I wanted to add the dll to the references to allow me to get the report as a PDF after each run.
I have downloaded the reference files etc from the page:
http://www.ranorex.com/blog/ranorex-rep ... /#onthefly

I've added the references as mentioned (I'm using v6.2.0)
Ranorex.Libs.Util
Ranorex.PDF

and then I added the .cs to the project and dragged it into a teardown region.

Each time I try and build the solution I get the following messages.

'Ranorex.Core.Testing.TestSuite' does not contain a definition for 'ReportCompress' and no extension method 'ReportCompress' accepting a first argument of type 'Ranorex.Core.Testing.TestSuite' could be found (are you missing a using directive or an assembly reference?) (CS1061) - C:\OptimumCredit\Dev\code\Ranorex\xxxxx\xxxxxxx\ReportToPDF.cs:116,31

'Ranorex.Core.Testing.TestSuite' does not contain a definition for 'ReportFormatString' and no extension method 'ReportFormatString' accepting a first argument of type 'Ranorex.Core.Testing.TestSuite' could be found (are you missing a using directive or an assembly reference?) (CS1061) - C:\OptimumCredit\Dev\code\Ranorex\xxxxx\xxxxxxx\ReportToPDF.cs:142,18

I have searched for any assistance online but cannot see anything which makes any sense to fix the issue.

Is there someone with the know-how to help me out here, please?

Thanks in advance

J

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

Re: Report To PDF issues- error on build

Post by Support Team » Tue Mar 14, 2017 7:07 am

Hi jojomonsta,

Please check if the correct "Ranorex.Core" assembly is referenced within your solution. Furthermore, please ensure that the correct *.cs file is used, "ReportToPDF_6.X.cs":
ReportToPDF_requirements.png
ReportToPDF_requirements.png (19.57 KiB) Viewed 1114 times
I hope this helps,
Robert
.
Image

jojomonsta
Posts: 12
Joined: Wed May 27, 2015 9:53 am

Re: Report To PDF issues- error on build

Post by jojomonsta » Tue Mar 14, 2017 10:26 am

Thank you, thank you, thank you!

I thought I might have needed to use the ReportToPDF_6.X but I wasn't able to drag it in to the project.

After readint his I decided to right-click on it to add and I was then able to drag it to a Teardown region.
I had to exclude the original ReportToPDF by excluding it as I was getting the error
'The namespace 'xxx' already contains a definition for 'xxx' (CS0101)'

When I excluded the original PDF .cs, this then built successfully.

Thanks for your prompt reply!

Zuzanna
Posts: 1
Joined: Fri Apr 07, 2017 3:02 pm

Re: Report To PDF issues- error on build

Post by Zuzanna » Fri Apr 07, 2017 3:08 pm

Hi

I have the same problem with Ranorex 7.0
I'm using:
Ranorex.Core version 7.0.0.0
Ranorex.Libs.Util version 7.0.0.0

and copy ReportToPDF.cs for Ranorex 7.0 file to my testcase

I don't know if it matters but my project was imported from Ranorex 6.2 vesion

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

Re: Report To PDF issues- error on build

Post by Support Team » Mon Apr 10, 2017 9:51 am

Hi Zuzanna,

Please ensure that you added a reference to the new ReportToPDF.dll(version 1.0.7)

Sincerely,
Robert
.
Image