Hi,
you are looking probably for an obfuscation solution.
There are many products out there. Just try to google it.
A quite cheap one is for example .Net Reactor which comes also with some basic licensing functionality (
http://www.eziriz.com/[
^])
EDIT
----------------------------------------------------
Ah ok. Then I got you wrong :) Maybe this will help you
Application Trial Maker[
^] or if you are only interested in some ideas
http://www.codeproject.com/Messages/2901545/Create-dll-file-and-add-implement-trial-period.aspx[
^]
Best regards