Report > Save As > Exception

Bug reports.
bkruse
Posts: 38
Joined: Tue Jul 20, 2010 12:19 pm

Report > Save As > Exception

Post by bkruse » Tue Jul 17, 2012 10:37 am

Hi,

I've recently upgraded from 2.3.9 to 3.3.1. I just opened the solution, fixed a few lines and everythings worked out of the box - very cool 8)
When my first Project run through and displayed the Report I tried File > Save As to save it to a different location. I just browsed there and hit "Speichern". I got the following Error message
Can't save file CreditSystem_20120717_101319.rxzlog under C:\ecue\QA.
Choose another file name or check if the directory exists and that
you have write permission in that path and file. (maybe a write protection problem?)
The Exception:
ICSharpCode.SharpZipLib.Zip.ZipException: Entry size/stream size mismatch
bei ICSharpCode.SharpZipLib.Zip.ZipFile.AddEntry(ZipFile workFile, ZipUpdate update)
bei ICSharpCode.SharpZipLib.Zip.ZipFile.RunUpdates()
bei ICSharpCode.SharpZipLib.Zip.ZipFile.CommitUpdate()
bei Ranorex.Report.Zip(String xmlReportFileName, Stream zipReportFileStream)
bei Ranorex.Report.CopyToFileOrFileStream(String sourceReportFileName, String destinationReportFileName, Stream fileStream)
bei Ranorex.Addins.ReportViewPrimaryViewContent.Save(OpenedFile file, Stream stream)
bei ICSharpCode.SharpDevelop.OpenedFile.SaveCurrentViewToStream(Stream stream)
bei ICSharpCode.SharpDevelop.OpenedFile.SaveToDisk()
bei ICSharpCode.SharpDevelop.FileServiceOpenedFile.SaveToDisk()
bei ICSharpCode.SharpDevelop.OpenedFile.SaveToDisk(String newFileName)
bei ICSharpCode.Core.FileUtility.ObservedSave(NamedFileOperationDelegate saveFileAs, String fileName, String message, FileErrorPolicy policy)
It generates a file "CreditSystem_20120717_101319.rxzlog" but it is empty.


When I choose File > Save As and switch from "Ranorex Commpressed Report (*.rxzlog)" (oh btw it should read Compressed, right?) to "Ranorex Report (*.rxlog)" then it works.

I use a custom XSL stylesheet, but uncommenting that doesn't help.
Report setup is done by

Code: Select all

            String dateString = System.DateTime.Now.ToString("yyyyMMdd_HHmmss");
            String logFileNamePrefix = Assembly.GetCallingAssembly().ManifestModule.Name.Replace(".exe", "");
            string logFileName = logFileNamePrefix + "_" + dateString + ".rxlog";
			
			// set a custom stylesheet for the default XML report  
			XmlLogger.SetReportStylesheetFile("Modules\\CustomStylesheet.xsl");
			
			// append to an existing file with the same name
			Report.Setup(ReportLevel.Debug, logFileName, true);
Let me know if you have any info on this or if you need more details.

best regards,
Björn

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

Re: Report > Save As > Exception

Post by Support Team » Tue Jul 17, 2012 2:42 pm

Hi Björn,

I already added an issue, so thanks for reporting this ;).

Back to the main problem, could you send us your report folder, respectively all files which could be helpful in order to reproduce the issue on our system (report files, xsl, ...)?

Regards,
Markus
Ranorex Support Team
.
Image

bkruse
Posts: 38
Joined: Tue Jul 20, 2010 12:19 pm

Re: Report > Save As > Exception

Post by bkruse » Wed Jul 18, 2012 12:04 pm

Hi again,

I tried to nail it down and reading the error message again ("... or check if the directory exists and that
you have write permission in that path and file ...") was helpful:

Just start Ranorex with admin rights and: it works!
But - and even more interesting - when I start Ranorex now without(!) admin rights, it also works!

Well, that makes it hard to reproduce.

Maybe Ranorex needed this one-time admin rights to set some settings (temporary storage of files somewhere for zipping)? My UAC is set to 2nd level from bottom. Win7 Pro where my user is an admin.

For me it works now.
Let me know if you are still interested in more information.

thanks and best regards,
Björn

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

Re: Report > Save As > Exception

Post by Support Team » Wed Jul 18, 2012 2:08 pm

Hi Björn,

My UAC is also enabled but in my case the error didn't appear.
Strange thing, it seems to be some sort of a local security issue, maybe your firewall/anti virus software has also something to do with the error.

Should the error appear again more additional information about your environment would be useful.

Regards,
Markus
Ranorex Support Team
.
Image

bkruse
Posts: 38
Joined: Tue Jul 20, 2010 12:19 pm

Re: Report > Save As > Exception

Post by bkruse » Wed Jul 18, 2012 3:24 pm

Just for the files: right now just TREND MICRO Office Scan installed, up-to-date and running.
Its firewall is disabled, Windows firewall also disabled.

In case it appears again, I'll come back here ; )

Grüße, Björn

bkruse
Posts: 38
Joined: Tue Jul 20, 2010 12:19 pm

Re: Report > Save As > Exception

Post by bkruse » Mon Sep 10, 2012 3:49 pm

Hi,

it appeared again, exactly the same exception as mentioned above.
The project originated in Ranorex 2.3.
New projects do not have this problem, so the cause lies in the Ranorex 2-history or the conversion to Ranorex 3.

I'll try to move my projects to the new structure when I find time for that. I feel that will solve it.

regards, Björn