Overview
Examples
Screenshots
Comparisons
Applications
Download
Documentation
Tutorials
Bazaar
Status & Roadmap
FAQ
Authors & License
Forums
Funding Ultimate++
Search on this site
Search in forums












SourceForge.net Logo
Home » U++ Library support » RichText,QTF,RTF... » Error while compiling on Windows Platform
Error while compiling on Windows Platform [message #35787] Wed, 21 March 2012 12:29 Go to next message
Shwetha is currently offline  Shwetha
Messages: 39
Registered: August 2011
Member
Hii,


I have programmed to generate the report and print it, followed the example as shown in reportgen prog. I could compile and get the desired out put on linux platform. same program i tried to execute on Windows and following error occurs.Could you please tell me how to solve the issue.

erpprint.cpp

In file included from C:\MyApps\ERPPrint\erpprint.cpp:1:0:

C:\MyApps\ERPPrint\/ERPPrint.h: In constructor 'ERPReportWindow::ERPReportWindow()':

C:\MyApps\ERPPrint\/ERPPrint.h:27:30: error: cannot call constructor 'ERPReportWindow::ReportWindow' directly

C:\MyApps\ERPPrint\/ERPPrint.h:27:30: error: for a function-style cast, remove the redundant '::ReportWindow'

ERPPrint: 1 file(s) built in (0:01.82), 1828 msecs / file, duration = 1843 msecs, parallelization 0%



There were errors. (0:01.90)



Re: Error while compiling on Windows Platform [message #35795 is a reply to message #35787] Thu, 22 March 2012 06:48 Go to previous messageGo to next message
koldo is currently offline  koldo
Messages: 3356
Registered: August 2008
Senior Veteran
Hello Shwetha

Could you include ERPPrint.h file?

Anyway I guess you are compiling with MinGW and there is some kind of redundancy in class declaration, like:

class MyClass {
	MyClass::MyClass();	// MinGW does not like this redundancy
};


Best regards
Iñaki
Re: Error while compiling on Windows Platform [message #35796 is a reply to message #35795] Thu, 22 March 2012 07:13 Go to previous messageGo to next message
Shwetha is currently offline  Shwetha
Messages: 39
Registered: August 2011
Member
Hi Koldo,

Please find attached file.
  • Attachment: ERPPrint.h
    (Size: 1.81KB, Downloaded 268 times)
Re: Error while compiling on Windows Platform [message #35798 is a reply to message #35796] Thu, 22 March 2012 08:00 Go to previous messageGo to next message
Shwetha is currently offline  Shwetha
Messages: 39
Registered: August 2011
Member
Please let me know how do i make it work on windows by removing the redundancy.
Re: Error while compiling on Windows Platform [message #35801 is a reply to message #35798] Thu, 22 March 2012 10:25 Go to previous messageGo to next message
omari is currently offline  omari
Messages: 264
Registered: March 2010
Experienced Member
Hello,

you make it work by removing the line :

		ReportWindow::ReportWindow();


a derived class call its base constructor automatically.



regards
omari.
Re: Error while compiling on Windows Platform [message #35805 is a reply to message #35801] Thu, 22 March 2012 15:49 Go to previous message
koldo is currently offline  koldo
Messages: 3356
Registered: August 2008
Senior Veteran
omari wrote on Thu, 22 March 2012 10:25

Hello,

you make it work by removing the line :

		ReportWindow::ReportWindow();


a derived class call its base constructor automatically.



Oh yes.

You wrote this:
class ERPReportWindow : public ReportWindow 
{
public:
	typedef ERPReportWindow CLASSNAME;

	ERPReportWindow() 
	{
		ReportWindow::ReportWindow();  // This line is redundant
	};
};



Best regards
Iñaki
Previous Topic: class generating QTF table
Next Topic: Printing in Windows - selecting 2 copies, prints 4 copies
Goto Forum:
  


Current Time: Thu Apr 18 15:30:11 CEST 2024

Total time taken to generate the page: 0.02041 seconds