Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

license error for powerpack from an old dotnet site #1

Open
georgedavid29 opened this issue Aug 28, 2019 · 3 comments
Open

license error for powerpack from an old dotnet site #1

georgedavid29 opened this issue Aug 28, 2019 · 3 comments

Comments

@georgedavid29
Copy link

license error for powerpack from an old dotnet site.
any tricks to fix this?

image

@OpinionatedGeek
Copy link
Owner

Hi,

I'm afraid not, or at least no tricks spring to mind.

One option would be to take the code here and compile it for your old dotnet site. This code is 'unlicensed', so freely available to do with as you please.

Off the top of my head, the only change you may need to make could be to change OpinionatedGeek.Web.PowerPack.Licensing.PowerPackLicenseProvider.GetLicense() to return a ValidLicense():

public override System.ComponentModel.License GetLicense (LicenseContext context, Type type, object instance, bool allowExceptions)
{
    return new ValidLicense ();
}

Since this was last released in 2008, I suspect you'd need an older version of .NET to compile it.

@georgedavid29
Copy link
Author

thanks for the quick reply. we'll have to see if/how we can re-compile it. i wasn't sure if the licensing data was stored in the registry or a flat file we could copy from the old server to the new server.

@OpinionatedGeek
Copy link
Owner

Oh I can certainly answer that one!

The only place the code looks for licensing information is in the configuration, which - unless you've done something a little unusual - will be in the web.config.

You should have a line like this near the top of the old web.config:

    <section name="OpinionatedGeek.Web.PowerPack" type="OpinionatedGeek.Web.PowerPack.ConfigurationSectionHandler,OpinionatedGeek.Web.PowerPack" />

Then you should have a config section like this somewhere in the old web.config:

<OpinionatedGeek.Web.PowerPack>
    ...
</OpinionatedGeek.Web.PowerPack>

You'll need to copy those across to the new web.config. That's all I can think/remember that you'd need to do to take the license across.

Good luck!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants