RaveReport -> FastReport

Some time ago on this forum the import from RaveReport was discussed. It was decided to implement this import in FR5. If someone is interested in this import, attach a sample .rav file and write the version of Rave in which the file is created. If the .rav file needs a database, attach it too.

Best regards, FR team.
«1

Comments

  • edited 3:37PM
    YES!!

    I'm about to move 300 reports from Rave to Fast Reports, so this would be greatly appreciated.

    What kind of conversion could we be looking at? Bands? Entire design? Data components? Scripts?
    I've been working on Fast Reports for some weeks now, but if there are some conversion tools ahead, that could be worth waiting for.

    If you need sample reports I can certanly offer that, but i suppose all of them would be a little to much. What kind of reports are you looking for?

    regards,
    Petter

  • edited 3:37PM
    Draeden wrote: »
    Some time ago on this forum the import from RaveReport was discussed. It was decided to implement this import in FR5. If someone is interested in this import, attach a sample .rav file and write the version of Rave in which the file is created. If the .rav file needs a database, attach it too.

    Best regards, FR team.

    Hello,

    I'm interested too. However the database behind most of my Rave reports are VERY complicated and mostly I use MySql.
    Is the Rav file not enough?

    Thank you
  • edited 3:37PM
    Petter S., we're going to support bands, entire design, database connections. Scripts is now a question - maybe they'll be converted to FR, maybe not. Attach some Rave reports with most complex structure. Include scripts too - we'll see whether it's possible to convert them.

    starhu, .rav files are enough. Databases are needed to be sure that the resulting .fr3 file is capable to print the same stuff what the original .rav prints, but the import itself doesn't need database sources. If your datasources are really complicated, then attach only .rav files.

    Note, that our import uses API from Rave v5.0. This doesn't prevent from importing .rav files from older versions of Rave, but the set of components/features is limited by that of Rave5.
  • edited 3:37PM
    Draeden wrote: »
    starhu, .rav files are enough. Databases are needed to be sure that the resulting .fr3 file is capable to print the same stuff what the original .rav prints, but the import itself doesn't need database sources. If your datasources are really complicated, then attach only .rav files.

    Hello,

    I have attached a rav file (compressed with rar) that has many reports,pages, bands, pictures and some scripts.

    Thank you.
  • edited 3:37PM
    In what version of Rave it's created? Your report contains a component TRaveJPEGImage that Rave v5.0 doesn't have.
  • edited November 2010
    Draeden wrote: »
    Petter S., we're going to support bands, entire design, database connections. Scripts is now a question - maybe they'll be converted to FR, maybe not. Attach some Rave reports with most complex structure. Include scripts too - we'll see whether it's possible to convert them.

    Thanks.

    Her are some reports attached. The first one in the project is probably the most complicated, with scripts, datamirrors and other stuff. If you need databases to test with, I will be happy to send you some by mail (my test DB's have elements of personal information, so I prefer not to put them in an open forum).

    My reports are created in Rave 6.0.5, but as far as I know there is not anything in there that was no present i Rave 5.

    Petter
  • edited 3:37PM
    Draeden wrote: »
    In what version of Rave it's created? Your report contains a component TRaveJPEGImage that Rave v5.0 doesn't have.

    I think maybe this is an AddOn to Rave. The Nevrona WEB-site is a mess, but you can find the AddOn here: http://rave-notes.blogspot.com/2009/01/blog-post.html

    Petter
  • edited November 2010
    Petter S., the import converted your report to fr3 file, but Rave5 failed to open the .rav file - it said that a component with a weird name is missing. See the attachment for the fr3 file and the screenshot of the error. Please point to things in the fr3 file that are not correct.
  • edited 3:37PM
    Petter S., thank you for the useful link - I found there TRaveJPEGImage component and now I'm able to convert the report of starhu.

    starhu, the attachment contains fr3 file produced from your rav file. Please, point to things in this fr3 that are not correct.
  • edited November 2010
    I found that your reports contain a Rave-specific feature - several reports inside one rav file. It's more accurate to represent such reports as several fr3 files, maybe as a zip archive. Here are these archives.
  • edited November 2010
    Here is the beta version of the import. It's highly apprectiated if you'll test it on your reports. To use this tool follow these steps:

    1. Click File | Designer to open FR designer.
    2. Click File | Open in the designer.
    3. Select a .rav file.
    4. Some .rav files may contain several reports inside. Such reports are converted to several .fr3 files. The tool will ask you where to save these files.
    5. In the designer you'll see the last report from the .rav file. If the .rav file contains a single report, then it'll be shown in the designer. If the .rav file contains several reports, then you can find the same number of .fr3 files inside a folder you specified.

    Note, that if the .rav file contains database components, then they'll appear in the resulting .fr3 file(s) only if these database components can be created at runtime. For instance, if the .rav file contains a IBX database connection and your system doesn't have ibinstall.dll installed, then you'll not see this IBX component in .fr3 files, as an attempt to create this component at runtime will call ibinstall.dll and fail.
  • edited 3:37PM
    Draeden wrote: »
    Here is the beta version of the import. It's highly apprectiated if you'll test it on your reports. To use this tool follow these steps:

    Thanks!

    I've tried it on one of my .rav-files, containing 31 reports. That took more than 2 hours on my PC..., but at last I got 31 .fr3-files. I really thought it had shut down, until the first FR3 appeared after approx 5 minutes, and then a new one 5 minutes later, and so on...

    There must be something mysterious in those new homemade files. They are exceptionally slow to work with. The files you sent me Nov 12th (PetterS.rar) are NOT slow at all. I attach one homemade (1.fr3) for you to examine, and also the .rav I used.

    There seems to be one main issue with measaurement. All sizing and placement is failing by the factor of approx 1.27. What should be 12.7 cm has become 10.0 cm, and what should be 18.5 cm has become 14.57 cm.

    In Rave we use Region-components as containers for all bands. That is not done in FR. The conversion seems to convert 'region' to 'subreport', and than I get subreports in all banded reports. That is a little unconvenient.

    In Rave there are what is called Global Pages, used for storing information that is shared between different reports inside the same .rav-file. In my test, This Global Pages becomes Page1, and the actual report pages becomes Page2, 3... Is there any hope of putting the global pages on the highest pagenumbers?

    /Petter
  • edited 3:37PM
    One main difference between your system and mine is that you have IBX installed. Maybe IBX components take so much time. When I import your rav file it takes about 3 seconds, but all IBX components are skipped.

    Your 1.fr3 file is not slow on my machine - it's opened in a moment. But FR designer informs me that IBX components cannot be added and skips them.

    The problem with measurements is fixed - the import multiplied all Rave lengths twice, but should multiple by 2.54 - one inch.

    Rave's regions is a problem. FR doesn't offer a proper way to emulate them. Subreports is just an approach to make output similar to what regions do. If you know a better way to convert regions, I'll implement it.

    Now all global components (i.e. components that are not inside any report) are placed after contents a Rave report. Thus global pages have highest numbers.
  • edited 3:37PM
    I imported Andre.rav and it took 3-4 seconds to complete all 31 fr3 files. Try to disable IBX (just make ibinstall.dll inaccessible) and import again.
  • venven
    edited 3:37PM
    Hi,
    I am very interested in the possibility of exporting reports from Rave Reports to FastReports. I use Rave Reports 8.0.1 Developer Edition and Delphi 2010. Attached you???ll find one of the reports with complex design, and I have over 300 such reports, in which (Data) MirrorSection components are the main part. The report consists of two ???core??? pages - StartPage and StartPage2 and two auxiliary for each of them-Helper and Helper2.
    The design of the pages is in StartPage and StartPage2, I put DataMirrorSection components in the DataBand components, and in Helper and Helper2 are the controls that display data. Important place in the report hold the events, set forth in the Event Editor for each page.

    I downloaded the FRImport.exe from the forum and loaded 110063_1.rav.

    As a result, in the design appeared 21 pages (ТfrxReportPage). In RaveProject -> Parameters I have defined parameters, but they are missing in the generated design. In addition, there are no events and any equivalent of the Data View Dictionary, that is, the data source for the controls on the Page components.

    Enc:
    1. 110063_1.rav
    2. 110063_1.pdf ??? a report after print
    3. fr3 RaveToFR as the result after export
    4. a small project with data as cds files, through which 110063_1.rav runs

    Thank you in advance for your help!

    Regards,
    Ventsislav Nenov
  • edited 3:37PM
    Draeden wrote: »
    In what version of Rave it's created? Your report contains a component TRaveJPEGImage that Rave v5.0 doesn't have.

    Hello,

    TRaveJPEGImage is a component that was developed by Rave (because the Rave didn't support jpge pictures by default), but it wasn't built in the usual packages.

    I have attached the component with source (for Delphi 2010).
  • edited 3:37PM
    ven, it's a good idea to make a compiled Rave previewer. If you can, please also make a compiled designer so that I can see your report before previewing. I need a simple app that can

    - open an arbitrary .rav file of Rave8 version
    - see in the designer
    - see it in the preview
    - show the version of Rave, e.g. File | Version would show a simple window with text "Rave 8.1"

    This app would save a lot of my time. Thanks in advance!
  • edited 3:37PM
    Draeden wrote: »
    One main difference between your system and mine is that you have IBX installed. Maybe IBX components take so much time. When I import your rav file it takes about 3 seconds, but all IBX components are skipped.

    Hi again.

    Yes, the speed issue has certanly to do with the ibx. Deleting the ibinstall.dll did not make any change for me. I have a Firebird server running on my system, maybe this makes the difference.
    Removing the IBX-components from my reports did the trick. Now I'm at 3 seconds as well.

    Conversion from 'DataText' to 'Memo':
    In Rave we have 'DataText' and 'DataMemo', used for retrieving values from db's and also from report-parameters. The syntax for getting av report-parameter in a datatext is 'param.MyParamName'.
    The report-parameters can be set from application code, and then printed in the report. In some reports in Rave we use lots of theese to move data from app to report.

    I can't find anything about such parameters in FR, but it seems like the 'variables' in FR can be used the same way. If this is correct, then i think that the Rave-import should convert 'param.MyParamName' to '[MyParamName] in memo's.

    Then there is an issues using the variables in FR: When i insert a variable in a memo, like '[MyParam]' then the contents for the variable is printed. But, if the variable have not been set, it prints the text 'MyParam' instead. What I want to print is blank when the variable does not have a value. How do I solve this?

    Attached there is a FR-report with lots of parameter/variables, and the .rav from where it's imported.

    regards,
    Petter


    131.zip 98.2K
  • edited 3:37PM
    Petter S., could you make a simple app that'll be able to design/view your file? This app will enable me to see its contents. Rave5 is unable to open it.
  • edited 3:37PM
    Draeden wrote: »
    Petter S., could you make a simple app that'll be able to design/view your file? This app will enable me to see its contents. Rave5 is unable to open it.

    Hi.

    I'm not an app-making-guy, I just build reports...

    But, what I can do is to zip and upload a complete installation of our main app with all reports and data, and an end-user rave-designer. It's about 70 mb zipped, and you just need to unpack. No installation needed.
    If this is OK, I would prefer to send you download-information by mail, as there are some licensing inside that is not suitable for open forum. If you want to e-mail me, it is petter[a]agro.no

    Petter
  • venven
    edited 3:37PM
    Hi, Draeden!

    To the previous project I added a possibility of opening the RAV report in a design mode.
    After opening the designer from menu Help-> About we can get information about the version.
    If you need me to do more please let me know.

    Regards,
    Ventsislav Nenov
  • edited 3:37PM
    ven, I examined your report.

    1. DataMirror and SectionMirror components seem to copy contents of some other container component. FR doesn't have such mirroring features. Is it ok to emulate Rave's mirroring by copying contents of a referred to container? For example, if a section mirrors a region with databands, the converter would just move these databands to the location of the section.

    2. Some pages in your report have pascal-like code assigned with events, like as OnBeforePrint. Although this code is pascal-like, it may differ in some features from FR's pascal-like scripts, hence converting a Rave's script to a FR's script needs a parser. This can be done, but it's not easy. Is it difficult to move Rave's scripts to FR in "manual mode"?

    3. Your report contains texts like "Param.Original". Where does this "Original" come from? I've not found it anywhere.
  • edited 3:37PM
    Draeden wrote: »
    ven, I examined your report.

    1. DataMirror and SectionMirror components seem to copy contents of some other container component. FR doesn't have such mirroring features. Is it ok to emulate Rave's mirroring by copying contents of a referred to container? For example, if a section mirrors a region with databands, the converter would just move these databands to the location of the section.

    2. Some pages in your report have pascal-like code assigned with events, like as OnBeforePrint. Although this code is pascal-like, it may differ in some features from FR's pascal-like scripts, hence converting a Rave's script to a FR's script needs a parser. This can be done, but it's not easy. Is it difficult to move Rave's scripts to FR in "manual mode"?

    3. Your report contains texts like "Param.Original". Where does this "Original" come from? I've not found it anywhere.

    Thw questions above are not adressed to me, but I would like to add my opinon, as it goes to the behavior of the import:

    1. Yes, that seem to be the closest you get, and would work nice in my reports.

    2. In Rave I use scripts to do things that in FR can and should be done in other ways. In some om my reports there are >100 scripts that I don't need anymore in FR. So converting all the scripts can get me a lot of garbage to sort out. In Rave every coponent needs to have it's own script, and in FR we can re-use the scripts-code. I think the manual way might be the best for me.

    3. In Rave the report parameters (printed in datatext-boxes, with the syntax 'param.MyParamName') do not need to be declared anywhere. In my reports we use params to push non-table-like data from Delphi to Rave, and the params are set from Delphi only. Params can also be sett from Rave-scripts, or from the output of other Rave-components (like the 'CalcTotal'-component).

    If the parameter is not set at all, not from Delphi and not from Rave, it just prints blank. This I'm having trouble with getting right in FR. See my earlier post.

    /Petter
  • Thomas PFisterThomas PFister Bavaria, Germany
    edited 3:37PM
    Hi,

    a good friend informed me today about your project with the Rave-Converter. Sounds great!


    I work in the meantime more with FR then with Rave, but I think I know Rave "a little"...
    If you have questions about Rave, the components and so on, feel free to ask, I'll help what I can in my spare time ...


    :-) thomas

    formerly know as "TeamNevrona"-member and owner of "http://rave-notes.blogspot.com";
  • edited 3:37PM
    Petter, thank you for the information. It makes some things clear to me.

    I found a problem with mirroring sections in Rave 8. It's possible to make a closed loop and thus crush Rave. It needs only three sections: A, B and C; B is inside A and B mirrors C, while C mirrors A and hence C mirrors itself. Rave tries to process this situation and crushes. That's not good as the converter needs to check such sitiations carefully.

    However, sections don't seem to be difficult to implement. More curious components are datamirrors. I see that they in some way mirror data, but in what exact way do they do this?

    It'd be great if you explain in details how datamirrors work >
  • edited 3:37PM
    Draeden wrote: »
    It'd be great if you explain in details how datamirrors work >

    I guess that Thomas could explain this more accurate, but I will give it a try:

    A ordinary section can by the mirror-property mirror another section somewhere else in the report, or in a global page. This is a fixed mirroring.

    A DataMirrorSection is used when you wish to mirror different sections depending of data. Behind the 'datamirrors'-property of a 'DataMirrorSection' there is an editor where you set up which field-values that should mirror which section. The source of value can be a field in a dataset, a report-parameter, or a value assigned from the OnMirrorValue-event script.

    An example: You have a table where a field could have values A, B or C, and you want to
    - print in normal font if value is A
    - print in bold italic, and also print some graphics if the value is B
    - print nothing if value is C.
    Then you put 3 sections on a not-printed report page: One with the stuff you want to print if value is A, one for B, and one empty for C. In your databand you put a DataMirrorSection, and set it up to mirror depending of the values A, B or C.

    In FR I solved this by adding multiple child-bands, and then set the visible-property for each of them depending of data in the OBP-event. If this is not the best way, please advice me in the right direction...

    Petter

  • edited 3:37PM
    Hi,

    a good friend informed me today about your project with the Rave-Converter. Sounds great!


    I work in the meantime more with FR then with Rave, but I think I know Rave "a little"...
    If you have questions about Rave, the components and so on, feel free to ask, I'll help what I can in my spare time ...


    :-) thomas

    formerly know as "TeamNevrona"-member and owner of "http://rave-notes.blogspot.com";

    Nice to see you in here Thomas! I've had great help from your postings in the Rave newsgroups for many years. I'm sure that if you could find time to download and test the import-routine posted in this thread by Dreaden on Nov 16th, and then i new version Nov 19th, you can add valuable feedback to the FR-guys, based on your wide experience.

    Petter
  • edited 3:37PM
    Thank for the detailed answer! Comments from Thomas PFister are also very appreciated.

    Does anyone use "the plain mirroring" i.e. mirroring a section by another section or a DataMirrorSection via their "Mirror" property?
  • venven
    edited 3:37PM
    Hi, Draeden!

    I read the comments carefully, I thought about them and I am aware of the fact that the conversion of RAVE report to FastReport can't be done one to one because we're talking about two different products.
    I will say what my expectation from the converter "RAVE to FastReport" is and I would use the report which I sent in my previous messages for an example.
    After converting the rav file I expect to receive an output fr-file that will have the same structure as the rav file, i.e. same number of pages, layout band components, fields, lines, etc. When there is a RAVE component that has no equivalent in FastReport, this component should be replaced with whatever - TMemoView-Rectangle, with the same size and position. This will allow me to decide how to change the report, what to do, and so on. The purpose is the output file to be with the same design of the pages, as in the rav file.
    As for the parameters in RaveProject -> Parameters ??? they may not appear in the output fr file ??? this is not a problem for me. It is similar with the events for some of the fields ??? they are of no interest for me and may not be transferred. The fact that the obtained after converting fr file will not be able to start and generate a result is not a problem too. It???s important for me to get a file with the same number of pages and layout of components as in the source rav file. Personally for me this will save me a lot of work. The functionality that will be missing in the new file, I???ll create it by myself and this also is not a problem. Moreover, in FastReport there is a feature that allows me to makes these reports better and even to simplify them.

    I hope this explanation will help you in any way. If it???s necessary I???ll answer specifically to the questions.

    Regards,
    Ventsislav Nenov
  • edited 3:37PM
    Here is a bit updated version of the Rave import. I replaced datamirrors with memos of the same size, as suggested ven and I also added the ability to cancel importing, since some components (like IBX dataconnections) may take a lot of time to be created.

    ven, your program for viewing .rav files appeared very useful. Can you add the ability to edit Rave reports and then save them to rav files? This feature is needed for making some specific simple designs to test the Rave import.

Leave a Comment

Rich Text Editor. To edit a paragraph's style, hit tab to get to the paragraph menu. From there you will be able to pick one style. Nothing defaults to paragraph. An inline formatting menu will show up when you select text. Hit tab to get into that menu. Some elements, such as rich link embeds, images, loading indicators, and error messages may get inserted into the editor. You may navigate to these using the arrow keys inside of the editor and delete them with the delete or backspace key.