Okiee... Di sini Hisoka punya edittext default kyk gambar di bawah :
Naaah...edittext yang itu tuuh...pengen kita ubah...biar bentuknya jadi kotak, jadi sama kyk textbox di C#-wpf...eheh... :D
Soo...pertama-tama tambain resource drawable, klik kanan di folder drawable, pilih new, terus pilih drawable resource file :
Terus masukin nama file xml-nya terus tekan ok...
Naah... kita dapat file kyk gini :
Naaah... di file-nya kita taroin kode xml kek gini :
Naaaah... uuudaaaah... terus kita ganti background di editextnya biar ngereference ke kotak.xml yang kita buat
Daaaan... hasilnyaaa.... kyk gini :
Naaah... itu warna tepinya biru... itu bisa diganti2 juga... silahkan dicoba2 tag2 lain di xml-nya terus liad perubahannya... :D
Thursday, May 19, 2016
Wednesday, May 18, 2016
Making Captcha In Android Using Android Studio Part II
Okieee... Let's continue part II... In the previous part, we have made two classess, MainCatpchaHysoka & TextCaptchaHyosoka, and now we will gonna make one more class namely MathOperationCaptchaHyosoka eheheh... :D
then extends this class from MainCatpchaHyosoka too....
Let's create variabel and it's contructor :
And change protected Bitmap image() as shown below :
Yeeeeiiiks... Coool.... Let's go to MainActivity.....First thing first.... Let's add some needed variabels for connecting our layout element to mainActivity :
Theen... Initializing our first captcha as plus_minus_multiply :
If we run this project, It should be looked like this :
Okieee... Next.. Let's put a handler for "Refresh" and "Cek" Button....Buut... first let's create a new string variabel called "answer" :
Refresh Button :
Cek Button :
Demo :
You download this project from my github repo righthere....
then extends this class from MainCatpchaHyosoka too....
Let's create variabel and it's contructor :
And change protected Bitmap image() as shown below :
Yeeeeiiiks... Coool.... Let's go to MainActivity.....First thing first.... Let's add some needed variabels for connecting our layout element to mainActivity :
Theen... Initializing our first captcha as plus_minus_multiply :
If we run this project, It should be looked like this :
Okieee... Next.. Let's put a handler for "Refresh" and "Cek" Button....Buut... first let's create a new string variabel called "answer" :
Refresh Button :
Demo :
You download this project from my github repo righthere....
Subscribe to:
Comments (Atom)

















