Click here to Skip to main content
Rate this: bad
good
Please Sign up or sign in to vote.
See more: VB8.0 VB9.0 VB.NET
How I can able to stop the application after running 3 times in vb.net. I want to stop running the application after launching the application 3 times! But I cannot any coding for that in vb in the WWW.
 
Please help me!
Posted 2-Oct-12 0:06am
Comments
geekbond at 2-Oct-12 9:13am
   
Check this link on codeproject if you want to make your app a trial version. http://www.codeproject.com/Articles/15496/Application-Trial-Maker
Chiranthaka Sampath at 2-Oct-12 11:04am
   
But my dear brother all these are are Java not VB. Please help me to do this in VB 2005 or VB 2008
geekbond at 2-Oct-12 11:25am
   
You can easily convert C# projects to VB.Net with the following tools.
 
http://www.fishcodelib.com/Convert.htm
http://www.developerfusion.com/tools/convert/csharp-to-vb/
 
I particularly like developerfusion, I used it everytime when I hadn't learnt C#, you can zip an entire project and you get the VB equivalent which is mostly 90% accurate.
Chiranthaka Sampath at 3-Oct-12 18:56pm
   
Thanx bro
geekbond at 8-Oct-12 9:36am
   
Happy to help.

1 solution

Rate this: bad
good
Please Sign up or sign in to vote.

Solution 1

It sounds like what you want is a type of trial version for your application. The simplest way to do this would be to write a key to the registry and then add or subtract one from your initial written value for each time the application is run. When you hit zero (if you are counting down) or 3 (if you are counting up), you would stop the application from running. The downside is that the user could change this registry value if they figured out where it was.
 
For a more complex example, here is a CP article that might help:
Implementing a Rudimentary Count Based Trial Version Plugin for Windows Applications.[^]
 
If you want even more secure, you probably should look into purchasing third-party software for creating trial versions.
 
Update
Here is a link to a VB.NET solution for tracking the number of days. You could use these concepts and just modify the implementation a bit to get number of uses instead of number of days:
http://www.vbforums.com/showthread.php?621068-Trial-Period-code-VB.NET[^]
  Permalink  
v2
Comments
Chiranthaka Sampath at 2-Oct-12 11:05am
   
I need VB 2005 or VB 2008 example not C#! But your help is valuable
Tim Corey at 2-Oct-12 11:14am
   
C# easily converts to VB.NET. In fact, if you compile the information into a DLL, you wouldn't even need to convert it. You could run a C# dll with your VB.NET program. Another option would be to take my first suggestion and roll your own. I'll add another link to my answer that will get you started down that road. Basically, you are either going to have to pay for something or do some work. We don't have a pre-built VB.NET option for you.
Chiranthaka Sampath at 3-Oct-12 18:56pm
   
Ok thanks Pal!

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

  Print Answers RSS
0 OriginalGriff 205
1 Sergey Alexandrovich Kryukov 185
2 jlopez788 109
3 Rob Philpott 100
4 Prakriti Goyal 97
0 OriginalGriff 6,837
1 Sergey Alexandrovich Kryukov 5,589
2 Maciej Los 3,479
3 Peter Leow 3,323
4 DamithSL 2,505


Advertise | Privacy | Mobile
Web03 | 2.8.140721.1 | Last Updated 2 Oct 2012
Copyright © CodeProject, 1999-2014
All Rights Reserved. Terms of Service
Layout: fixed | fluid

CodeProject, 503-250 Ferrand Drive Toronto Ontario, M3C 3G8 Canada +1 416-849-8900 x 100