Click here to Skip to main content
15,892,674 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
I have created a widows application with setup project. I compiled and build.Everything looks fine.

For changing the configuration file during installation am trying to add a new Installer file. when i add it by default i get the below code

C#
[RunInstaller(true)]
    public partial class Installer : Installer
    {
        public Installer()
        {
            InitializeComponent();
        }
    }


before modifying When i compile this Am gettin
Circular base class dependency involving 'windows_setup.Installer' and 'windows_setup.Installer'

windows setup is the name space i used for the application

Why am getting this and how to resolve this...?

Thanks
Posted

1 solution

The culprit is :

public partial class Installer : Installer


You are trying to define a partial class which inherits itself. It has nothing to do with installer but you are going against the basic principles.

Create a new class which inherits Installer class.

public partial class MyInstaller : Installer
 
Share this answer
 
v2
Comments
peru j 6-Jul-12 7:21am    
I did that...Now i get" Inconsistent accessibility: base class 'windows_setup.Installer' is less accessible than class 'windows_setup.MyInstaller' "
Manas Bhardwaj 6-Jul-12 7:36am    
Did you change the Consructor name as well?
peru j 6-Jul-12 7:40am    
Yes .Below is the Code Snippet

[RunInstaller(true)]
public partial class MyInstaller : Installer
{
public MyInstaller()
{
InitializeComponent();
}
}
peru j 9-Jul-12 7:19am    
Any idea ?

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900