Licensing using .net dll - Advanced Installer Community

We’re moving our forums to a new platform.

You can still browse and search existing topics, but you can no longer create new topics or post replies.

For questions, technical issues, or feature requests, please don’t hesitate to contact our support team at support@advancedinstaller.com.

Thank you for your understanding!

renukabitla
Posts: 7
Joined: Mon Oct 17, 2011 2:12 pm

Licensing using .net dll

Hi,

I have made a dll file but when i include the same in the user defined validation of the package serial validation in the licensing the function doesnt appear in the drop down and i also want to pass the PIDKEY as argument to that function
The project type i have used is a class library
Kindly let me know if i am missing any other settings to be done in the advanced installer or missing any code
I have attached the Class file of the dll.

Any help would be appreciated
Thanks in advance
Attachments
Class1.txt
(4 KiB) Downloaded 208 times
Bogdan
Posts: 2796
Joined: Tue Jul 07, 2009 7:34 am
Contact: Website

Re: Licensing using .net dll

Hi,

The DLL you've implemented is used for our licensing support. From what I understood you are trying to use the serial validation support, therefor a different feature.

For serial validation you need a DLL after the following model.

Regards,
Bogdan
Bogdan Mitrache - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube
renukabitla
Posts: 7
Joined: Mon Oct 17, 2011 2:12 pm

Re: Licensing using .net dll

Hi

Thanks a lot for your reply Mr. Bogdan that sorts out my problem but just wanted to confirm whether there isnt any way to achieve it through pure .Net code
Bogdan
Posts: 2796
Joined: Tue Jul 07, 2009 7:34 am
Contact: Website

Re: Licensing using .net dll

Always a pleasure. Let me know if you have other questions.

Regards,
Bogdan
Bogdan Mitrache - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube
renukabitla
Posts: 7
Joined: Mon Oct 17, 2011 2:12 pm

Re: Licensing using .net dll

Please suggest if there is any other way to achieve it through pure .Net code and not using cpp and all.
Bogdan
Posts: 2796
Joined: Tue Jul 07, 2009 7:34 am
Contact: Website

Re: Licensing using .net dll

Hi,

Recently we added a new article into our user-guide that explains how you can export from your .NET code a DLL similar with the one I presented above.
http://www.advancedinstaller.com/user-g ... rp-ca.html

Regards,
Bogdan
Bogdan Mitrache - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube
renukabitla
Posts: 7
Joined: Mon Oct 17, 2011 2:12 pm

Re: Licensing using .net dll

Hi
Sorry to bother you agian but could you please provide me a proper and complete example of Serial Validation with its code of dll and aip project settings
Or tell me step by step instruction to achieve the same as i have created a custom action dll but not able to call it on a specific dialog next button
How to pass the PIDKEY as argument to that fuction
I have also attached my dll code



Thanks
Attachments
CustomAction.txt
(829 Bytes) Downloaded 198 times
mihai.petcu
Posts: 3860
Joined: Thu Aug 05, 2010 8:01 am

Re: Licensing using .net dll

Hello,

The only serial validation sample we have is the one from this article my colleague Bogdan mentioned above. It is a model for a Win32 .DLL.

Here is an article to help you with executing a custom action on button push.

Since you are developing a fully fledged C# .NET custom action, you can get or set an installer public property(PIDKEY) in the following way:

Code: Select all

public static ActionResult CustomAction1(Session session)
{
// sending message to installation log
session.Log("Begin CustomAction1");

// getting a property
YourVariable = session["YOUR_PROPERTY"];

// setting a property
session["YOUR_PROPERTY"] = "YOUR_VALUE";

return ActionResult.Success;
}
Unfortunately it is not within our support boundaries neither to create or debug custom actions.

All the best,
Mihai
Mihai Petcu - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube

Return to “Common Problems”