0

فقط ۲۵ بار برنامه اجرا بشه !؟

 
mehdigerdali
mehdigerdali
کاربر طلایی1
تاریخ عضویت : خرداد 1390 
تعداد پست ها : 5587
محل سکونت : خوزستان

فقط ۲۵ بار برنامه اجرا بشه !؟
دوشنبه 20 تیر 1390  7:45 PM

فقط ۲۵ بار برنامه اجرا بشه !؟

سلام امروز یک کد بسیار ساده برای شما آماده کردم. کد زیر باعث میشه فقط برنامه برای ۲۵ اجرا بشه نه بیشتر یک command1 به فرم اظافه کنید و بعد کد زیر را به برنامه اظافه کنید.

private sub form_load()

' the "a" in getsetting and savesetting
' can be changed to another letter
retvalue = getsetting("a", "0", "runcount") ' this returns the value of the registry edit.
worm$ = val(retvalue) + 1 ' adds one to the value of the regisrty edit.
savesetting "a", "0", "runcount", worm$ ' saves the new value

if worm$ 24 then 'put one number lower then it says.
msgbox "you have used this program 25 times, purchase is now required", 16, "sorry"
' this would send the user to a website
' in their default browser.
win32keyword "http://skygazer.net"
unload me
end
end if

end sub

private sub command1_click()

end
end sub

***به بهشت نمی روم اگر مــــــادرم آنجا نباشد***

آنگاه که تنها شدی و در جست جوی یک تکیه گاه مطمئن هستی ، بر من توکل نما . نمل/79

 

تشکرات از این پست
ramins nedaee
دسترسی سریع به انجمن ها