Προς το περιεχόμενο

Voitheia se visual basic(arxarios)


therock

Προτεινόμενες αναρτήσεις

Δημοσ.

Pedia exo ksekiniso na ftaxno ena aplo programmataki stin visual basic pou exei sxesei me tin metrima tis partidas tavli!Exo loipon dimiourgisei 2 textbox opou anaferontai ta paixnidia pou exei parei o kathenas kai ena trito pou simplironeis ton arithmo ton pexnidion pou tha pextoun.Diladi an thes na peksei sta 5 simplironeis sto 3 textbox 5.

 

Ayto pou thelo tora,einai molis simplirothoun ta pente na vgazei minima kai na leei poios nikise.Diladi sto textbox 1 an exei ton arithmo 3 kai sto textbox 2 ton arithmo 5,na vgazei minima kai na leei pos nikise o player 2.(Ipotithete pos prin to textbox 1 exo ena label pou leei player 1 kai prin textbox 2 ena pou leei player 2).

 

Ara pos mporo na to kano ayto?

 

Kai kati akoma,pos mporo na valo na rotaei stin arxi ta onomata ton paixton kai na ta antoistixa sta antistoixa label,alla patontas cancel na exei san default player 1,player 2.Kai telos pos mporo na krataei log me to poioi pextes peksane,pote,kai poio to score?

 

Ayta...Eyxaristo ek ton protairon!

Δημοσ.

An katalaba kala, ayto poy 8eleis einai an sto trito textbox exei ton ari8mo 5, tote o prwtos paikths poy 8a ftasei sta 5 paixnidia 8a einai kai o nikhths. Ayto poy mporeis na kaneis, einai na baleis sto form soy enan timer (apo to toolbox to eikonidio me to xronometro). 8eteis to interval toy timer (apo to properties) iso me enan ari8mo (to interval ka8orizei ka8e posa millisecond 8a trexei ton kwdika poy exeis grapsei gia ton timer soy). kaneis diplo klik ston timer poy ebales, kai grafeis ton ekshs kwdika :

>
if( val(textbox1.text) = val(textbox3.text) or val(textbox2.text) = val(textbox3.text))then
msg=msgbox("To mhnyma poy 8eleis na typwnetai",vbOkOnly+vbInformation,"O titlos toy messageBox poy 8a emfanizetai")
end if

 

Oson afora ta onomata twn paiktwn, mporeis molis ksekinaei to programma soy, na emfanizeis ena inputbox sto opoio o ka8e paikths 8a bazei to nickname toy, dld :

>
player1 = InputBox("Dwse to nick toy 1oy paikth","Nick 1oy paikth")
player2 = InputBox("Dwse to nick toy 2oy paikth","Nick 2oy paikth")
if(player1 <> "")then
labe1.caption=player1
else
label1.caption="Player 1"
end if
if(player2 <> "")then
labe2.caption=player2
else
label2.caption="Player 2"
end if

Telos, sxetika me ta logs, mporeis na ta kratas se ena arxeio (sxetika me arxeia sth basic mporeis na breis sto internet), h an exeis megalh orreksh se mia bash, an kai den to blepw anagkaio afoy h plhroforia soy einai arketa mikrh.

 

Elpizw na se boi8hsa....cu

 

Edited by Dionisos: Vazete ton kwdika mesa se

 tags!
Δημοσ.

Eyxaristo para poli gia to reply sou,oson afora ta log ennoo na mou sozei aytomata kathe fora ta paixnidia pou pezontai.As poume an simera peksoun ena o player 1 kai o 2,na mou to sosei aytomata to programma molis to kleiso se ena log pou na leei px Wednsday 28/04/2004 Player 1-Player 2 = 5-3.Pos mporei na ginei ayto?

 

Episis pou mporo na vro kana kalo tutorial,e-book peri visual basic.

 

Kai telos i visual basic theoreitai pio aplopoimenoi kai ipodiesteri allon opos c++ kai alles?

Δημοσ.

to save sto kleisimo tou programmatos 8a to kaneis sto unload event ths formas.

Afto symvainei prin do8ei ksana h allocated mnhmh tou programmatos sto systhma.

 

thn hmeromhnia 8a thn pareis me thn synarthsh "date" ( h getdate,den 8ymamai) gia na dhmiourgeis aftomata to filename.Ta ypoloipa stoixeia yparxoun hdh sthn forma.

Δημοσ.

Μην ξεχνάτε ότι θα αποθηκεύονται ίσως και περισσότερα από 1 log lines με την ίδια ημερομηνία. Αν αυτό δεν είναι επιθυμητό, τότε θα χρειαστεί να γίνεται εύρεση στο αρχείο log ώστε να ενημερώνει τα στοιχεία της ημερομηνίας. (βάζω φωτιές)

Δημοσ.

Mporei na anoigei to arxeio na diavazei olo to keimeno pou exei mesa,na kollaei afto pou 8elei kai na to ksanapao8hkeyei.

Afto ginetai poly efkola xrhsimopoiwntas file system objects (FSO).

Prepei na kanei include to MS scripting runtime library gia na mporesei na ta xrhsimopoihsei.

Αρχειοθετημένο

Αυτό το θέμα έχει αρχειοθετηθεί και είναι κλειστό για περαιτέρω απαντήσεις.

  • Δημιουργία νέου...