dövücü Posted March 7, 2011 Share Posted March 7, 2011 (edited) Merhaba arkadşalar bir projem için serial konusunda çalışıyorum serial işini yaptım anlatımlardan ama benim sorunum şu ben istiyorum ki birden fazla şifre ile projeye girilebilsin bir şifre atadım diyelim "123" ve ben bunu unuttum daha önceden de 2. şifre olarak "kurtarma" yazdım şifreyi yazınca projem açılsın istiyorum ama bir türlü yapamadım yardımcı olabilir misiniz.Bahsettiğim olay birden fazla şifre ile programa giriş şifre sorgulamayı dialog ile yaptırmak istiyorum. Edited March 7, 2011 by dövücü Quote Link to comment Share on other sites More sharing options...
Sistemci Posted March 7, 2011 Share Posted March 7, 2011 abi kodları verirsen yardımcı olabilirim Quote Link to comment Share on other sites More sharing options...
dövücü Posted March 7, 2011 Author Share Posted March 7, 2011 [quote]0n startupda[/quote] real_password = "deneme"; user_password = Dialog.PasswordInput("Şifre", "Lütfen Şifreyi Giriniz:", MB_ICONQUESTION); if real_password ~= user_password then Application.Exit(); Quote Link to comment Share on other sites More sharing options...
KintaRo Posted March 7, 2011 Share Posted March 7, 2011 [CODE]tSerial [COLOR="#FF0000"]=[/COLOR] [COLOR="#FF0000"]{[/COLOR][COLOR="#800080"]"12345"[/COLOR][COLOR="#FF0000"],[/COLOR] [COLOR="#800080"]"789456"[/COLOR][COLOR="#FF0000"],[/COLOR] [COLOR="#800080"]"abc123"[/COLOR][COLOR="#FF0000"]}[/COLOR] [COLOR="#008000"]-- seriallerin oldugu tablo[/COLOR] sGirilen [COLOR="#FF0000"]=[/COLOR] Input[COLOR="#FF0000"].[/COLOR]GetText([COLOR="#800080"]"Input1"[/COLOR]) [COLOR="#008000"]-- serialin girildigi inputtan alinan metin[/COLOR] [COLOR="#0000FF"]if[/COLOR] sGirilen [COLOR="#FF0000"]==[/COLOR] tSerial[COLOR="#FF0000"][[/COLOR][COLOR="#000000"]1[/COLOR][COLOR="#FF0000"]][/COLOR] [COLOR="#0000FF"]or[/COLOR] sGirilen [COLOR="#FF0000"]==[/COLOR] tSerial[COLOR="#FF0000"][[/COLOR][COLOR="#000000"]2[/COLOR][COLOR="#FF0000"]][/COLOR] [COLOR="#0000FF"]or[/COLOR] sGirilen [COLOR="#FF0000"]==[/COLOR] tSerial[COLOR="#FF0000"][[/COLOR][COLOR="#000000"]3[/COLOR][COLOR="#FF0000"]][/COLOR] [COLOR="#0000FF"]then[/COLOR] [COLOR="#008000"]-- eger girilen serial tablodaki degerlerden biriyle uyusursa[/COLOR] Page[COLOR="#FF0000"].[/COLOR]Jump([COLOR="#800080"]"Page2"[/COLOR]) [COLOR="#008000"]-- 2. sayfaya atla[/COLOR] [COLOR="#0000FF"]else[/COLOR] [COLOR="#008000"]-- uyusmazsa[/COLOR] Dialog[COLOR="#FF0000"].[/COLOR]Message([COLOR="#800080"]"Hata"[/COLOR][COLOR="#FF0000"],[/COLOR] [COLOR="#800080"]"Girilen Şifre Yanlış"[/COLOR]) [COLOR="#008000"]-- hata ver[/COLOR] [COLOR="#0000FF"]end[/COLOR] [/CODE] Quote Link to comment Share on other sites More sharing options...
galetis Posted March 7, 2011 Share Posted March 7, 2011 (edited) Kintaro okuyo birazdan gelir cevap Edit: yazmadan gelmiş Edited March 7, 2011 by galetis Quote Link to comment Share on other sites More sharing options...
Sistemci Posted March 7, 2011 Share Posted March 7, 2011 (edited) abi çok hızlısın Edited March 7, 2011 by Sistemci Quote Link to comment Share on other sites More sharing options...
dövücü Posted March 7, 2011 Author Share Posted March 7, 2011 Hocam öncelikle teşekkür ederim fakat verdiğiniz kodları projemin on startup ekranına ekledim projemi çalıştırdığımda direk hata şifre yalnış dialogu geliyor şifre sormuyor ? Quote Link to comment Share on other sites More sharing options...
KintaRo Posted March 7, 2011 Share Posted March 7, 2011 paşam bu kodlar örnek, açıklamadada gördüğün gibi inputtan aliyor metni. Bunu uyarlayacaksın işte kendine göre. Neyse al: [CODE]tSerial [COLOR="#FF0000"]=[/COLOR] [COLOR="#FF0000"]{[/COLOR][COLOR="#800080"]"12345"[/COLOR][COLOR="#FF0000"],[/COLOR] [COLOR="#800080"]"789456"[/COLOR][COLOR="#FF0000"],[/COLOR] [COLOR="#800080"]"abc123"[/COLOR][COLOR="#FF0000"]}[/COLOR] [COLOR="#008000"]-- seriallerin oldugu tablo[/COLOR] sGirilen [COLOR="#FF0000"]=[/COLOR] Dialog[COLOR="#FF0000"].[/COLOR]PasswordInput([COLOR="#800080"]"Şifre"[/COLOR][COLOR="#FF0000"],[/COLOR] [COLOR="#800080"]"Lütfen Şifreyi Giriniz:"[/COLOR][COLOR="#FF0000"],[/COLOR] MB_ICONQUESTION); [COLOR="#0000FF"]if[/COLOR] sGirilen [COLOR="#FF0000"]==[/COLOR] tSerial[COLOR="#FF0000"][[/COLOR][COLOR="#000000"]1[/COLOR][COLOR="#FF0000"]][/COLOR] [COLOR="#0000FF"]or[/COLOR] sGirilen [COLOR="#FF0000"]==[/COLOR] tSerial[COLOR="#FF0000"][[/COLOR][COLOR="#000000"]2[/COLOR][COLOR="#FF0000"]][/COLOR] [COLOR="#0000FF"]or[/COLOR] sGirilen [COLOR="#FF0000"]==[/COLOR] tSerial[COLOR="#FF0000"][[/COLOR][COLOR="#000000"]3[/COLOR][COLOR="#FF0000"]][/COLOR] [COLOR="#0000FF"]and[/COLOR] sGirilen [COLOR="#FF0000"]~=[/COLOR] [COLOR="#800080"]"CANCEL"[/COLOR] [COLOR="#0000FF"]then[/COLOR] [COLOR="#008000"]-- eger girilen serial tablodaki degerlerden biriyle uyusursa[/COLOR] Page[COLOR="#FF0000"].[/COLOR]Jump([COLOR="#800080"]"Page2"[/COLOR]) [COLOR="#008000"]-- 2. sayfaya atla[/COLOR] [COLOR="#0000FF"]else[/COLOR] [COLOR="#008000"]-- uyusmazsa[/COLOR] Dialog[COLOR="#FF0000"].[/COLOR]Message([COLOR="#800080"]"Hata"[/COLOR][COLOR="#FF0000"],[/COLOR] [COLOR="#800080"]"Girilen Şifre Yanlış"[/COLOR]) [COLOR="#008000"]-- hata ver[/COLOR] Application[COLOR="#FF0000"].[/COLOR]Exit() [COLOR="#0000FF"]end[/COLOR][/CODE] Quote Link to comment Share on other sites More sharing options...
dövücü Posted March 7, 2011 Author Share Posted March 7, 2011 yanlış girilirse tekrar şifre yi gir sormuyor onu nasıl yapabilirim. Quote Link to comment Share on other sites More sharing options...
KintaRo Posted March 7, 2011 Share Posted March 7, 2011 Global Functions: [CODE][COLOR="#0000FF"]function[/COLOR] giris() tSerial [COLOR="#FF0000"]=[/COLOR] [COLOR="#FF0000"]{[/COLOR][COLOR="#800080"]"12345"[/COLOR][COLOR="#FF0000"],[/COLOR] [COLOR="#800080"]"789456"[/COLOR][COLOR="#FF0000"],[/COLOR] [COLOR="#800080"]"abc123"[/COLOR][COLOR="#FF0000"]}[/COLOR] sGirilen [COLOR="#FF0000"]=[/COLOR] Dialog[COLOR="#FF0000"].[/COLOR]PasswordInput([COLOR="#800080"]"Şifre"[/COLOR][COLOR="#FF0000"],[/COLOR] [COLOR="#800080"]"Lütfen Şifreyi Giriniz:"[/COLOR][COLOR="#FF0000"],[/COLOR] MB_ICONQUESTION); [COLOR="#0000FF"]if[/COLOR] sGirilen [COLOR="#FF0000"]==[/COLOR] tSerial[COLOR="#FF0000"][[/COLOR][COLOR="#000000"]1[/COLOR][COLOR="#FF0000"]][/COLOR] [COLOR="#0000FF"]or[/COLOR] sGirilen [COLOR="#FF0000"]==[/COLOR] tSerial[COLOR="#FF0000"][[/COLOR][COLOR="#000000"]2[/COLOR][COLOR="#FF0000"]][/COLOR] [COLOR="#0000FF"]or[/COLOR] sGirilen [COLOR="#FF0000"]==[/COLOR] tSerial[COLOR="#FF0000"][[/COLOR][COLOR="#000000"]3[/COLOR][COLOR="#FF0000"]][/COLOR] [COLOR="#0000FF"]and[/COLOR] sGirilen [COLOR="#FF0000"]~=[/COLOR] [COLOR="#800080"]"CANCEL"[/COLOR] [COLOR="#0000FF"]then[/COLOR] Page[COLOR="#FF0000"].[/COLOR]Jump([COLOR="#800080"]"Page1"[/COLOR]) [COLOR="#0000FF"]elseif[/COLOR] sGirilen [COLOR="#FF0000"]==[/COLOR] [COLOR="#800080"]"CANCEL"[/COLOR] [COLOR="#0000FF"]then[/COLOR] Application[COLOR="#FF0000"].[/COLOR]Exit() [COLOR="#0000FF"]elseif[/COLOR] sGirilen [COLOR="#FF0000"]~=[/COLOR] tSerial[COLOR="#FF0000"][[/COLOR][COLOR="#000000"]1[/COLOR][COLOR="#FF0000"]][/COLOR] [COLOR="#0000FF"]and[/COLOR] sGirilen [COLOR="#FF0000"]~=[/COLOR] tSerial[COLOR="#FF0000"][[/COLOR][COLOR="#000000"]2[/COLOR][COLOR="#FF0000"]][/COLOR] [COLOR="#0000FF"]and[/COLOR] sGirilen [COLOR="#FF0000"]~=[/COLOR] tSerial[COLOR="#FF0000"][[/COLOR][COLOR="#000000"]3[/COLOR][COLOR="#FF0000"]][/COLOR] [COLOR="#0000FF"]or[/COLOR] sGirilen [COLOR="#FF0000"]==[/COLOR] [COLOR="#800080"]""[/COLOR] [COLOR="#0000FF"]or[/COLOR] sGirilen [COLOR="#FF0000"]~=[/COLOR] [COLOR="#800080"]"CANCEL"[/COLOR] [COLOR="#0000FF"]then[/COLOR] Dialog[COLOR="#FF0000"].[/COLOR]Message([COLOR="#800080"]"Hata"[/COLOR][COLOR="#FF0000"],[/COLOR] [COLOR="#800080"]"Girilen Şifre Yanlış"[/COLOR]) [COLOR="#0000FF"]return[/COLOR] giris() [COLOR="#0000FF"]end[/COLOR] [COLOR="#0000FF"]end[/COLOR][/CODE] Actions>On Startup: [CODE]giris()[/CODE] Quote Link to comment Share on other sites More sharing options...
dövücü Posted March 7, 2011 Author Share Posted March 7, 2011 sağol kintaro bu sefer oldu. Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.