You are on page 1of 232

Laäp Trình Web Vôùi Visual Basic

PHAÀN I :
CÔ SÔÛ LYÙ THUYEÁT VEÀ NGOÂN NGÖÕ VISUAL BASIC

I. Tìm hieåu ngoân ngöõ laäp trình Visual Basic


1. Toång quan veà ngoân ngöõ laäp trình Visual Basic
Visual Basic, con ñöôøng nhanh nhaát vaø ñôn giaûn nhaát ñeå taïo nhöõng öùng duïng cho
Microsoft Windows. Baát keå baïn laø moät nhaø chuyeân nghieäp hay laø moät ngöôøi môùi laäp
trình Windows, Visual Basic cung caáp cho baïn moät taäp hôïp caùc coâng cuï hoaøn chænh ñeå
nhanh choùng phaùt trieån caùc öùng duïng.
Vaäy Visual Basic laø gì ? Thaønh phaàn “Visual” noùi ñeán caùc phöông thöùc duøng ñeå
taïo giao dieän ñoà hoïa ngöôøi söû duïng (GUI). Thay vì vieát nhöõng doøng maõ ñeå moâ taû söï
xuaát hieän vaø vò trí cuûa nhöõng thaønh phaàn giao dieän, ta chæ caàn theâm vaøo nhöõng ñoái
töôïng ñaõ ñöôïc ñònh nghóa tröôùc ôû vò trí naøo ñoù treân maøn hình.
Thaønh phaàn “Basic” noùi ñeán ngoân ngöõ “BASIC” (Beginners All-Purpose Symbolic
Instruction Code) moät ngoân ngöõ ñöôïc duøng bôûi nhieàu nhaø laäp trình hôn baát cöù moät
ngoân ngöõ naøo khaùc trong lòch söû maùy tính. Visual Basic ñöôïc phaùt trieån daàn daàn döïa
treân ngoân ngöõ BASIC, vaø baây giôø chöùa ñöïng haøng traêm ñieàu leänh, haøm, vaø töø khoùa…
coù quan heä tröïc tieáp vôùi giao dieän ñoà hoïa cuûa Windows.
Ngoân ngöõ laäp trình Visual Basic khoâng chæ laø Visual Basic. Heä thoáng laäp trình
Visual Basic, nhöõng öùng duïng bao goàm Microsoft Excel, Microsoft Access, vaø nhieàu
öùng duïng Windows khaùc ñeàu duøng cuøng moät ngoân ngöõ.
Maëc duø muïc ñích cuûa chuùng ta laø taïo ra nhöõng öùng duïng nhoû cho baûn thaân hay moät
nhoùm, moät heä thoáng caùc coâng ty lôùn, hoaëc thaäm chí phaân phoái nhöõng öùng duïng ra toaøn
caàu qua Internet. Visual Basic laø cung cuï maø baïn caàn.
• Nhöõng chöùc naêng truy xuaát döõ lieäu cho pheùp ta taïo ra nhöõng cô sôû döõ lieäu,
nhöõng öùng duïng front-end, vaø nhöõng thaønh phaàn phaïm vi server-side cho haàu
heát caùc daïng thöùc cô sôû döõ lieäu phoå bieán, bao goàm Microsoft SQL Server vaø
nhöõng cô sôû döõ lieäu möùc enterprise khaùc.

• Nhöõng kyõ thuaät ActiveX cho pheùp ta duøng nhöõng chöùc naêng ñöôïc cung caáp töø
nhöõng öùng duïng khaùc, nhö laø chöông trình xöû lyù vaên baûn Microsoft Word, baûng
tính Microsoft Excel vaø nhöõng öùng duïng Windows khaùc.

• Khaû naêng Internet laøm cho noù deã daøng cung caáp cho vieäc theâm vaøo nhöõng taøi
lieäu vaø öùng duïng qua Internet hoaëc intranet töø beân trong öùng duïng cuûa baïn,
hoaëc taïo nhöõng öùng duïng Internet server.

• Öùng duïng cuûa baïn keát thuùc laø moät file .exe thaät söï. Noù duøng moät maùy aûo Visual
Basic ñeå baïn töï do phaân phoái öùng duïng.

Trang 1
2. Caáu truùc cuûa moät öùng duïng Visual Basic
Moät öùng duïng thaät ra laø moät taäp hôïp caùc chæ daãn tröïc tieáp ñeán maùy tính ñeå thi haønh
moät hay nhieàu taùc vuï. Caáu truùc cuûa moät öùng duïng laø phöông phaùp trong ñoù caùc chæ
daãn ñöôïc toå chöùc, ñoù laø nôi chæ daãn ñöôïc löu giöõ vaø thi haønh nhöõng chæ daãn trong moät
trình töï nhaát ñònh.
Vì moät öùng duïng Visual Basic, treân cô baûn laø nhöõng ñoái töôïng, caáu truùc maõ ñoùng
ñeå töôïng tröng cho nhöõng moâ hình vaät lyù treân maøn hình. Baèng vieäc ñònh nghóa, nhöõng
ñoái töôïng chöùa maõ vaø döõ lieäu. Form, caùi maø chuùng ta nhìn thaáy treân maøn hình laø töôïng
tröng cho nhöõng thuoäc tính, quy ñònh caùch xuaát hieän vaø caùch cö xöû. Cho moãi form
trong moät öùng duïng, coù moät quan heä module form (vôùi teân file môû roäng laø .frm) duøng
ñeå chöùa ñöïng maõ cuûa noù.
Moãi module chöùa nhöõng thuû tuïc söï kieän – nhöõng ñoaïn maõ, nôi ñaët nhöõng chæ daãn,
caùi seõ ñöôïc thi haønh trong vieäc ñaùp öùng nhöõng söï kieän chæ ñònh. Form coù theå chöùa
nhöõng ñieàu khieån. Töông öùng vôùi moãi ñieàu khieån treân form, coù moät taäp hôïp nhöõng thuû
tuïc söï kieän trong module form ñoù.
Maõ khoâng chæ quan heä vôùi moät form chæ ñònh hay ñieàu khieån coù theå ñöôïc ñaët trong
moät loaïi module khaùc, moät module chuaån (.BAS). Moät thuû tuïc ñöôïc duøng ñeå ñaùp öùng
nhöõng söï kieän trong nhöõng ñoái töôïng khaùc nhau phaûi ñöôïc ñaët trong cuøng moät chuaån,
thay vì taïo nhöõng baûn sao maõ trong nhöõng thuû tuïc söï kieän cho moãi ñoái töôïng. Moät lôùp
module (.cls) ñöôïc duøng ñeå taïo nhöõng ñoái töôïng, caùi maø coù theå ñöôïc goïi töø nhöõng thuû
tuïc beân trong öùng duïng cuûa baïn. Trong khi moät module chuaån chæ chöùa maõ, moät lôùp
module chöùa ñöïng caû maõ vaø döõ lieäu. Ta coù theå nghó noù nhö moät ñieàu khieån.

3. Chuùng ta coù theå laøm gì vôùi Visual Basic


 Taïo giao dieän ngöôøi söû duïng
Giao dieän ngöôøi söû duïng coù leõ laø thaønh phaàn quan troïng nhaát cuûa moät öùng duïng.
Ñoái vôùi ngöôøi söû duïng, giao dieän chính laø öùng duïng ; hoï khoâng caàn chuù yù ñeán thaønh
phaàn maõ thöïc thi beân döôùi. ÖÙng duïng cuûa chuùng ta coù theå phoå bieán ñöôïc hay khoâng
phuï thuoäc vaøo giao dieän.

 Söû duïng nhöõng ñieàu khieån chuaån cuûa Visual Basic


Ta duøng nhöõng ñieàu khieån ñeå laáy thoâng tin maø ngöôøi söû duïng nhaäp vaøo, vaø ñeå hieån
thò keát xuaát. Nhöõng ñieàu khieån maø ta coù theå duøng trong öùng duïng bao goàm hoäp vaên
baûn, nuùt leänh, vaø hoäp danh saùch,…. Nhöõng ñieàu khieån khaùc cho ta truy xuaát nhöõng öùng
duïng khaùc, xöû lyù döõ lieäu cuûa noù nhö laø moät thaønh phaàn maõ trong öùng duïng cuûa baïn.

 Laäp trình vôùi nhöõng ñoái töôïng.


Nhöõng ñoái töôïng laø thaønh phaàn chuû yeáu ñeå laäp tình Visual Basic. Nhöõng ñoái töôïng
coù theå laø form, nhöõng ñieàu khieån hay cô sôû döõ lieäu.

Trang 2
Laäp Trình Web Vôùi Visual Basic

 Laäp trình vôùi phaàn hôïp thaønh


Chuùng ta ñoâi khi caàn söû duïng khaû naêng tính toaùn cuûa Microsoft Excel trong öùng
duïng Visual Basic, hay ñònh daïng moät taøi lieäu söû duïng thanh coâng cuï ñònh daïng cuûa
Microsoft Word, hoaëc löu tröõ vaø xöû lyù döõ lieäu duøng Microsoft Jet… Taát caû nhöõng ñieàu
naøy coù theå thöïc hieän ñöôïc baèng caùch xaây döïng nhöõng öùng duïng cuûa chuùng ta söû duïng
nhöõng thaønh phaàn ActiveX. Theâm vaøo ñoù, Visual Basic coù theå giuùp chuùng ta taïo ra
nhöõng ñieàu khieån ActiveX rieâng.

 Ñaùp öùng nhöõng söï kieän chuoät vaø baøn phím


Nhöõng öùng duïng Visual Basic coù theå ñaùp öùng moät löôïng lôùn söï kieän chuoät vaø baøn
phím. Ví duï form, hoäp aûnh, vaø nhöõng ñieàu khieån aûnh coù theå phaùt hieän vò trí con troû
chuoät, coù theå quyeát ñònh phím traùi hay phím phaûi ñöôïc nhaán, vaø coù theå ñaùp öùng nhöõng
toå hôïp cuûa phím chuoät vôùi phím Shift, Ctrl, hay Alt. Söû duïng nhöõng ñieàu khieån phím,
ta coù theå laäp trình nhöõng ñieàu khieån vaø form ñeå ñaùp öùng caùc haønh ñoäng phím hoaëc
phieân dòch vaø xöû lyù maõ Ascii cuûa kyù töï.
Theâm vaøo ñoù, nhöõng öùng duïng Visual Basic coù theå hoã trôï söï kieän reâ vaø thaû cuõng nhö
tính naêng reâ vaø thaû OLE.

 Laøm vieäc vôùi vaên baûn vaø ñoà hoïa.


Visual Basic cung caáp khaû naêng ñoà hoïa vaø vaên baûn phöùc taïp trong öùng duïng.
Nhöõng thuoäc tính vaên baûn coù theå giuùp ta nhaán maïnh caùc khaùi nieäm quan troïng vaø caùc
chi tieát caàn quan taâm. Theâm vaøo ñoù, Visual Basic cung caáp khaû naêng ñoà hoïa cho pheùp
ta linh ñoäng trong thieát keá, bao haøm caùc hình aûnh ñoäng baèng caùch hieån thò moät loaït
caùc hình aûnh lieân tieáp nhau.

 Gôõ roái maõ vaø quaûn lyù loãi


Ñoâi khi coù nhöõng loãi xaûy ra beân trong maõ cuûa öùng duïng. Nhöõng loãi nghieâm troïng
coù theå laø nguyeân nhaân moät öùng duïng khoâng ñaùp öùng leänh, thoâng thöôøng yeâu caàu
ngöôøi söû duïng khôûi ñoäng laïi öùng duïng, vaø khoâng löu laïi nhöõng gì ta ñaõ laøm. Quaù trình
tìm ra vaø söûa loãi goïi laø gôõ roái. Visual Basic cung caáp nhieàu coâng cuï giuùp chuùng ta
phaân tích öùng duïng laøm vieäc nhö theá naøo. Nhöõng coâng cuï gôõ roái ñaët bieät höõu ích trong
vieäc tìm ra nguoàn goác loãi, nhöng chuùng ta cuõng coù theå duøng nhöõng coâng cuï naøy ñeå
kieåm tra chöông trình hoaëc tìm hieåu nhöõng öùng duïng khaùc nhau laøm vieäc nhö theá naøo.

 Xöû lyù oå ñóa, thö muïc vaø file


Khi laäp trình trong Windows, noù raát quan troïng ñeå coù khaû naêng theâm, di chuyeån,
taïo môùi hoaëc xoùa nhöõng thö muïc vaø file, laáy thoâng tin veà vaø xöû lyù oå ñóa. Visual Basic
cho pheùp chuùng ta xöû lyù oå ñóa, thö muïc vaø file baèng hai phöông phaùp : qua nhöõng
phöông htöùc cuõ nhö laø ñieàu leänh Open, Write#, vaø qua moät taäp hôïp caùc coâng cuï môùi
nhö FSO (File System Object)

Trang 3
 Thieát keá cho vieäc thi haønh vaø tính töông thích
Visual Basic chia xeû haàu heát nhöõng tính naêng ngoân ngöõ trong Visual Basic cho
nhöõng öùng duïng, bao goàm trong Microsoft Office vaø nhieàu öùng duïng khaùc. Visual
Basic, VBScript, moät ngoân ngöõ script Internet, ñeàu laø taäp hôïp con cuûa ngoân ngöõ
Visual Basic.

 Phaân phoái nhöõng öùng duïng


Sau khi taïo moät öùng duïng Visual Basic, ta coù theå töï do phaân phoái baát kyø öùng duïng
naøo ñaõ taïo baèng Visual Basic ñeán baát cöù ai duøng Microsoft Windows. Ta coù theå phaân
phoái öùng duïng treân ñóa, treân CD, qua maïng, treân intranet hoaëc Internet.

4. Toùm taét ngoân ngöõ


4.1. Bieán
Bieán ñöôïc duøng ñeå löu taïm thôøi caùc giaù trò tính toaùn trong quaù trình xöû lyù chöông
trình.
 Caùch khai baùo bieán
Visual Basic duøng caùch khai baùo bieán trong chöông trình nhö sau :
Dim <Teân bieán> As <Kieåu bieán>
Ta cuõng coù theå khoâng caàn khai baùo kieåu bieán (töùc boû meänh ñeà As <Kieåu bieán> phía
sau), trong tröôøng hôïp naøy, bieán coù theå ñöôïc duøng ñeå löu giöõ moät giaù trò baát kyø.

 Quy taéc ñaët teân bieán


 Teân bieán coù chieàu daøi toái ña 255 kyù töï.
 Phaûi baét ñaàu baèng moät chöõ caùi.
 Khoâng ñaët caùc khoaûng troáng vaø caùc kyù hieäu (+ - * /…) trong teân bieán.
 Khoâng ñöôïc truøng vôùi töø khoùa cuûa ngoân ngöõ.
 Traùnh ñaët teân truøng nhau.

 Phaïm vi söû duïng bieán


Phaïm vi söû duïng bieán tuøy thuoäc caùch ta khai baùo vaø choã ta ñaët doøng leänh khai baùo
bieán.
 Neáu ta khai baùo trong phaàn General, bieán coù theå ñöôïc duøng ôû baát kyø ñoaïn leänh
naøo trong from vaø cuõng chæ maát ñi khi from ñöôïc giaûi phoùng khoûi boä nhôù.
 Neáu ta khai baùo bieán trong phaàn vieát leänh cho moät söï kieän cuûa moät ñoái töôïng
(töùc khai baùo giöõa hai doøng Sub vaø End Sub cuûa maõ leänh ñoù) thì bieán chæ toàn taïi
vaø duøng ñöôïc trong phaïm vi hai doøng Sub vaø End Sub ñoù maø thoâi. Bieán nhö vaäy
goïi laø bieán rieâng hay bieán noäi boä.
 Neáu ta duøng töø khoùa Public thay cho Dim ñeå khai baùo bieán , bieán seõ toàn taïi
trong suoát thôøi gian thöïc hieän chöông trình vaø coù theå duøng ñöôïc trong baát cöù
ñoaïn leänh naøo cuûa chöông trình. Bieán nhö vaäy goïi laø bieán chung hay bieán toaøn
cuïc.

Trang 4
Laäp Trình Web Vôùi Visual Basic

4.2. Caùc kieåu döõ lieäu trong Visual Basic

Teân kieåu Kích thöôùc Khoaûng gía trò


Byte 1 byte 0 ñeán 255 (töùc coù theå gaùn cho bieán caùc giaù trò nhoû
nhaát laø 0 vaø lôùn nhaát laø 255)

Integer 2 byte -32768 ñeán 32767

Long 4 byte -2.147.483.648 ñeán 2.147.483.647

Single 4 byte -3,402823E38 ñeán –1,401298E-45 (caùc gía trò aâm)


1,401298E-45 ñeán 3,402823E38 (caùc gía trò döông)

Double 8 byte -1,79769E308 ñeán –4,94065E-324 (giaù trò aâm)


4,94065E-324 ñeán 1,79769E308 (giaù trò döông)

Currency 8 byte -922337203685477,5808 ñeán


922337203685477,5807

Boolean 2 byte True tôùi False

Date 2 byte 1 thaùng 1 naêm 100 ñeán 31 thaùng 12 naêm 9999 ;


Thôøi gian töø 0:00:00 ñeán 23:59:59:

String 1 byte cho coù theå leân ñeán 231 kyù töï
moãi kyù töï

Variant 16 byte + Null, Error, baát kyø kieåu soá naøo coù giaù trò trong khoaûng
1 byte cho Double hay baát kyø noäi dung text naøo
moãi kyù töï

Kyù hieäu Exx phía sau soá coù nghóa laø nhaân vôùi 10xx.
• Kieåu soá nguyeân döông (khoâng chaáp nhaän soá aâm) goàm kieåu Byte.
• Kieåu soá nguyeân (chaáp nhaän caû soá aâm nhöng khoâng chaáp nhaän phaàn leû thaäp
phaân) goàm caùc kieåu :Integer, Long.
• Kieåu soá thöïc goàm Single, Double, Currency.
• Kieåu Boolean goïi laø kieåu luaän lyù, noù chæ chaáp nhaän hai giaù trò True laø ñuùng vaø
False laø sai.
• Kieåu String duøng ñeå chöùa caùc giaù trò chuoãi. Moät chuoãi kyù töï coù theå coù nhieàu kyù
töï. Khi vieát moät giaù trò chuoãi, ta phaûi bao hai ñaàu noù baèng daáu nhaùy keùp.

Trang 5
• Kieåu ngaøy thaùng (Date) ñeå chöùa giaù trò thôøi gian. Khi vieát moät giaù trò kieåu Date,
ta coù theå vieát theo baát cöù kieåu ghi giôø naøo bao hai ñaàu baèng daáu #.

4.3. Caùc toaùn töû trong Visual Basic


4.3.1. Caùc toaùn töû tính toaùn

Toaùn töû YÙ nghóa Ví duï


+ Coäng hai soá haïng vôùi nhau X =Y + 1
coù theå duøng ñeå coäng hai chuoãi st= “Visual” + “Basic”
- Tröø hai soá haïng X=Y-1
* Nhaân hai soá haïng X=Y*1
/ Chia, traû veà kieåu soá thöïc Y=1/2
\ Chia laáy nguyeân X=3\2 ‘X seõ nhaän giaù trò 1
Mod Chia laáy dö X = 7 Mod 4 ‘X seõ nhaän giaù trò 3
^ Laáy luõy thöøa X=Y^3

4.3.2. Caùc toaùn töû so saùnh

Toaùn töû YÙ nghóa


> So saùnh xem soá thöù nhaát coù lôùn hôn soá thöù hai khoâng.
< So saùnh xem soá thöù nhaát coù nhoû hôn soá thöù hai khoâng.
= So saùnh xem soá thöù nhaát coù baèng soá thöù hai khoâng.
<> So saùnh xem soá thöù nhaát coù khaùc hôn soá thöù hai khoâng.
>= So saùnh xem soá thöù nhaát coù lôùn hôn hay baèng soá thöù hai khoâng.
<= So saùnh xem soá thöù nhaát coù nhoû hôn hay baèng soá thöù hai khoâng.

4.3.3. Caùc toaùn töû luaän lyù

Toaùn töû YÙ nghóa


And Traû veà True neáu caû hai soá haïng ñeàu laø True, traû veà False neáu
moät trong hai soá haïng laø False.
Or Traû veà True neáu moät trong hai soá haïng laø True, traû veà False neáu
caû hai soá haïng laø False.
Not Traû veà True neáu soá haïng laø False, False neáu soá haïng laø True.

4.4. Caáu truùc tuyeån vaø caáu truùc laëp


4.4.1. Caáu truùc tuyeån
 Caáu truùc tuyeån If
Cuù phaùp 1 :

Trang 6
Laäp Trình Web Vôùi Visual Basic

If <bieåu thöùc luaän lyù> Then


… ‘Neáu bieåu thöùc luaän lyù treân laø True
… ‘thì thöïc hieän ñoaïn leänh naøy
End If

Cuù phaùp 2 :

If <bieåu thöùc luaän lyù> Then


… ‘Neáu bieåu thöùc luaän lyù treân laø True
… ‘thì thöïc hieän ñoaïn leänh naøy
Else
… ‘Ngöôïc laïi neáu bieåu thöùc luaän lyù laø False
… ‘thì thöïc hieän ñoaïn leänh naøy.
End If

 Caáu truùc tuyeån Select Case


Cuù phaùp :

Select Case <bieán hay bieåu thöùc> ‘xeùt bieán hay bieåu thöùc naøy
Case <caùc giaù trò> ‘Neáu bieán hay bieåu thöùc baèng caùc giaù trò naøy
<caùc caâu leänh> ‘thì thöïc hieän ñoaïn leänh naøy

Case <caùc giaù trò>

‘coù theå coù nhieàu Case cho caùc ñieàu kieän caàn
xeùt.
[ Case Else ‘Neáu bieán hay bieåu thöùc khoâng baèng caùc giaù
trò cuûa caùc Case beân treân
<caùc caâu leänh> ] ‘thì thöïc hieän phaàn leänh naøy

End Select

4.4.2. Caùc caáu truùc laëp


 Caáu truùc Do…Loop
Cuù phaùp 1 :

Do While <bieåu thöùc ñieàu kieän> ‘trong khi bieåu thöùc ñieàu kieän ñuùng
<caùc caâu leänh> ‘thì thöïc hieän caùc caâu leänh naøy
Loop ‘Quay trôû veà doøng Do While ñeå kieåm tra laïi

Trang 7
Cuù phaùp 2 :

Do ‘thöïc hieän
<caùc caâu leänh> ‘caùc caâu leänh naøy
Loop Until <ñieàu kieän> ‘cho ñeán khi ñieàu kieän ñuùng

Cuù phaùp naøy khaùc cuù phaùp 1 ôû choã : trong cuù phaùp 1 ñieàu kieän ñöôïc xeùt tröôùc khi thöïc
hieän caùc caâu leänh, cuù phaùp 2 ñieàu kieän ñöôïc xeùt sau khi thöïc hieän caùc caâu leänh.

 Caáu truùc For…Next


Cuù phaùp :

For bieán = giaù trò ñaàu To giaù trò cuoái [Step khoaûng taêng]
<caùc caâu leänh>
Next bieán

4.5. Thuû tuïc


 Caùch ñònh nghóa thuû tuïc
Moät thuû tuïc tröôùc khi muoán söû duïng noù phaûi ñònh nghóa noù. Duøng töø khoùa Sub ñeå
khai baùo thuû tuïc nhö theá naøy.

Private/Pulic Sub <Teân thuû tuïc>


… <Caùc maõ leänh maø thuû tuïc naøy thöïc hieän>
End Sub ‘Choã keát thuùc thuû tuïc.

 Neáu ta khai baùo baèng töø khoùa Public, thuû tuïc coù theå ñöôïc goïi ñeå söû duïng trong
baát kyø form naøo trong chöông trình.
 Neáu ta khai baùo baèng töø khoùa Private, thuû tuïc chæ coù theå duøng ñöôïc trong form
coù chöùa noù maø thoâi

 Thuû tuïc coù truyeàn tham soá


Khi moät thuû tuïc ñöôïc goïi maø coù truyeàn theâm moät soá giaù trò vaøo, caùc giaù trò naøy
ñöôïc goïi laø caùc tham soá cuûa thuû tuïc ñoù. Ñeå laøm ñieàu naøy, khi khai baùo thuû tuïc ta caàn
ghi theâm noù seõ nhaän bao nhieâu tham soá baèng cuù phaùp nhö sau :

Private/Public Sub <Teân thuû tuïc> (<Teân töôïng tröng cho tham soá> As <Kieåu>,…)

Trang 8
Laäp Trình Web Vôùi Visual Basic

II. Nhöõng öùng duïng Internet Visual Basic


1. Caùc khaùi nieäm veà öùng duïng Internet
1.1. ÖÙng duïng Internet laø gì ?
Moät öùng duïng Internet laø moät öùng duïng töông taùc, moät öùng duïng ñaõ ñöôïc dòch coù
theå truy xuaát qua Internet. Öùng duïng Internet coù theå thi haønh nhöõng coâng vieäc phöùc
taïp treân caû client hay treân server. Trong moät öùng duïng Internet server – based, noù
duøng giao thöùc Internet HTTP ñeå laáy laïi nhöõng yeâu caàu töø moät client, ñaëc bieät laø moät
Web browser, xöû lyù maõ keát hôïp vôùi noù, vaø göûi traû döõ lieäu veà cho browser.
Trong laäp trình Internet Visual Basic, ta coù theå theâm noäi dung ñoäng vaøo nhöõng
trang Web deã daøng. Öùng duïng Internet Visual Basic lieân keát maõ Visual Basic ñeán moät
hoaëc nhieàu trang HTML vaø quaûn lyù söï kieän phaùt sinh trong nhöõng trang naøy bôûi vieäc
töông taùc vôùi chöông trình treân caû client hay treân server. Giao tieáp vôùi ngöôøi duøng
trong moät öùng duïng Internet Visual Basic coù theå laø moät chuoãi caùc trang HTML(Hyper
Text Markup Language), hay laø moät söï troän laãn cuûa trang HTML vaø Visual Basic
form. Tuy nhieân, vôùi loaïi giao dieän naøo thì öùng duïng cuõng quaûn lyù söï kieän, goïi nhöõng
phöông thöùc, thieát laäp vaø laáy laïi nhöõng thuoäc tính cô baûn treân nhöõng thaønh phaàn trong
trang HTML ñoù.

1.2. Nhöõng moâ hình ñoái töôïng Internet


Chuùng ta chæ duøng khaùi nieäm laäp trình höôùng ñoái töôïng trong öùng duïng Internet
Visual Basic chæ khi chuùng ta laøm trong öùng duïng Visual Basic form–based. Trong
öùng duïng Internet Visual Basic, chuùng ta duøng moâ hình ñoái töôïng quan heä ñeå truy

. Coù hai loaïi


xuaát vaø xöû lyù thoâng tin vaø nhöõng ñieàu khieån treân trang HTML

öùng duïng Internet Visual Basic : öùng duïng IIS vaø


öùng duïng DHTML. Trong ñoù öùng duïng IIS
(Internet Information Server), ta duøng moâ hình ñoái
töôïng Active Server Pages (ASP) ñeå laáy laïi thoâng
tin töø ngöôøi söû duïng, göûi thoâng tin ñeán browse, vaø
löu laïi thoâng tin veà phieân laøm vieäc hieän taïi. Trong
öùng duïng DHTML, ta duøng moâ hình ñoái töôïng
Dynamic HTML (DHTML) ñeå xöû lyù nhöõng thaønh
phaàn treân moät trang HTML.
1.3. Lòch söû phaùt trieån treân Internet

Trang 9
 Noäi dung tónh

ÖÙng duïng ñaàu tieân treân Internet laø nhöõng


trang tónh, noù göûi noäi dung noù ñeán browser vaø
khoâng töï phaûn öùng vôùi baát kyø haønh ñoäng naøo
maø ngöôøi söû duïng ñaõ thi haønh. Maëc duø moâ
hình trình baøy vôùi ngöôøi söû duïng nhöõng trang
thoâng tin ñaõ ñöôïc format nhöng söï töông taùc ñoù
laø coù giôùi haïn giöõa ngöôøi söû duïng vaø Web
server. Nhöõng trang tónh naøy phaûi ñöôïc hieäu
chænh baèng tay ñeå caäp nhaät nhöõng noäi dung
cuûa noù.
 Trình baøy noäi dung ñoäng baèng caùch laäp trình Gateway

Söï phaùt trieån cuûa nhöõng giao tieáp Gateway nhö


laø Common Gateway Interface (CGI), öùng duïng
Internet Server Programming Interface (ISAPI), vaø
nhöõng caùi khaùc cho pheùp ngöôøi söû duïng theâm vaøo
nhöõng noäi dung ñoäng cho Web. Vôùi noäi dung ñoäng,
moät browser coù theå göûi moät yeâu caàu cho vieäc tìm
kieám thoâng tin. Server, thay vì traû veà moät trang
tónh, noù chaïy moät script hay moät öùng duïng vaø traû veà
trang HTML ñaõ ñöôïc caäp nhaät vaø thoâng tin chính
xaùc. Ñieàu baát thuaän lôïi cuûa chöông trình Gateway
laø khoù taïo vaø thay ñoåi noù.

Trang 10
Laäp Trình Web Vôùi Visual Basic

 Scripting

Scripting cho pheùp noäi dung ñoäng baèng caùch keát


hôïp nhöõng Script coù theå thi haønh ñöôïc vaøo tröïc tieáp
trong moät trang HTML. Thay vì yeâu caàu Server,
browser coù theå söû lyù nhöõng Script khi noù taûi HTML
naøy. Nhuõng script coù theå ñöôïc söû lyù treân caû Client
hay treân Web server. Ngoân ngöõ chung cho script
Client – side laø VBScript vaø JavaScript. Rieâng vôùi
Script server – side, ngoân ngöõ chung cho noù laø
Active Server Pages (ASP).
Trong moâ hình ASP Script, phaùt trieån HTML vaø
phaùt trieån Script laø cuøng quaù trình. Noù cho pheùp
nhaø cung caáp Web cung caáp nhöõng öùng duïng töông
taùc thay vì chæ laø xuaát baûn noäi dung.
 ÖÙng dung Internet Visual Basic
Kyõ thuaät Internet Visual Basic cho pheùp ta lieân keát nhöõng maõ VB chuaån vôùi giao
tieáp ngöôøi söû duïng cuûa nhöõng trang HTML. Noù cung caáp chöùc naêng laäp trình keát hôïp
vôùi trang Web, cho pheùp ta taïo nhöõng trang ñoäng vaø töông taùc. Vôùi kyõ thuaät Internet
Visual Basic, ta coù theå thi haønh nhöõng hoaït ñoäng phöùc taïp maø khoâng caàn phaûi laäp

trình phöùc taïp nhö Coù hai loaïi öùng duïng


Gateway hay Scripting.

Internet VB chính: öùng duïng IIS vaø öùng duïng


DHTML.
1.4. Nhöõng thuaän lôïi cuûa öùng duïng Internet Visual Basic
Coù nhieàu phöông phaùp ñeå phaùt trieån nhöõng öùng duïng cho Internet. Tröôùc khi coù
Visual Basic 6.0, nhöõng nhaø phaùt trieån thöôøng döïa treân chöông trình Gateway, treân
chöùc naêng ActiveX, hay treân Active Server Page ñeå taïo nhöõng öùng duïng Internet
ñoäng, töông taùc. Phaùt trieån öùng duïng Internet trong Visual Basic ñöa ra nhieàu khoùa
thuaän lôïi hôn nhöõng phöông phaùp treân.

Trang 11
 Ta coù theå laøm giaûm ñaùng keå chi phí cho vieäc trieån khai öùng duïng ñeán vôùi moãi
ngöôøi söû duïng. Ngöôøi söû duïng cuûa moät öùng duïng Internet IIS coù theå chaïy öùng
duïng naøy chæ vôùi duy nhaát moät browser thích hôïp vaø thôøi gian chaïy Visual Basic
treân maùy tính cuûa hoï. Nhöõng thaønh phaàn caàn thieát ñaõ ñöôïc thieát laäp töï ñoäng tröôùc
ñoù.
 Ta coù theå söû duïng kieán thöùc cuûa mình veà Visual Basic vaø duøng moâi tröôøng laäp
trình Visual Basic, khoâng caàn phaûi hoïc Scripting hay nhöõng thao taùc xöû lyù nhöõng
tag HTML ñeå phaùt trieån moät öùng duïng coù chöùc naêng Web – base cao.

 Ta coù theå taùch bieät vieäc thieát keá giao dieän ngöôøi söû duïng töø vieäc vieát maõ cho
moät form hay moät trang. Trong nhöõng öùng duïng Web – base tröôùc, nhöõng ngöôøi
phaùt trieån phaûi cheøn nhöõng script cuûa hoï vaøo tröïc tieáp trong moät taøi lieäu HTML,
caùi maø haàu nhö duøng ñeå taïo giao dieän ngöôøi söû duïng. Noù laøm cho maõ trôû neân khoù
ñoïc vaø quaûn lyù.

 Trong öùng duïng IIS, ta coù theå duøng laïi nhöõng trang trong nhöõng ngöõ caûnh khaùc
nhau. Khoâng gioáng nhö HTML, nôi maø thoâng tin töø trang naøy sang trang khaùc phaûi
ñöôïc gaén chaët vaøo trong baûn thaân HTML, thì vieäc laùi thoâng tin cho moät trang trong
moät öùng duïng Internet Visual Basic ñöôïc löu tröõ taùch bieät töø baûn thaân moãi trang.
Noù cho pheùp ta duøng trang naøy ôû nhieàu nôi trong moät öùng duïng, vieäc thay ñoåi
höôùng tuøy thuoäc vaøo ngöõ caûnh.

 Ta coù theå giaûm thôøi gian taûi vaø do ñoù giaûm thôøi gian taûi maïng cuûa chuùng ta, bôûi
vì heä thoáng khoâng caàn phaûi taûi xuoáng nhöõng thaønh phaàn khaùc ñeå chaïy öùng duïng .

 Ta coù theå deã daøng löu giöõ traïng thaùi öùng duïng, nhö laø teân cuûa ngöôøi söû duïng
hoaëc soá account giöõa nhöõng yeâu caàu client. Tuøy thuoäc vaøo loaïi öùng duïng, ta coù theå
löu giöõ traïng thaùi treân client, treân server hay caû hai.

 Ta coù theå gôõ roái nhöõng öùng duïng IIS vaø DHTML baèng nhöõng coâng cuï gôõ roái
chuaån cuûa Visual Basic.

2. ÖÙng duïng Internet vaø nhöõng kyõ thuaät Internet trong Visual Basic
2.1. ÖÙng duïng Internet Visual Basic
2.1.1. ÖÙng duïng IIS
Nhöõng öùng duïng IIS thöôøng truù treân Web Server vaø xöû lyù nhöõng yeâu caàu ñeán töø
moät browser. ÖÙng duïng IIS xöû lyù yeâu caàu ñoù, chaïy maõ VB keát hôïp vôùi noù vaø traû veà
nhöõng ñaùp öùng cho ngöôøi söû duïng. Caùc quaù trình xöû lyù cho moät öùng duïng IIS ñeàu xaûy
ra treân server.

Trang 12
Laäp Trình Web Vôùi Visual Basic

2.1.2. ÖÙng duïng DHTML


Öùng duïng DHTML cho pheùp ta vieát maõ Visual Basic ñeå quaûn lyù nhöõng söï kieän
treân baát cöù thaønh phaàn naøo cuûa moät trang HTML. Haàu heát quaù trình xöû lyù trong moät
öùng duïng DHTML coù theå xaûy ra treân maùy browser, maëc duø öùng duïng coù theå goïi
server neáu thaáy caàn thieát.

2.1.3. Söï khaùc nhau giöõa öùng duïng IIS vaø öùng duïng DHTML
ÖÙng duïng IIS vaø öùng duïng DHTML laø hai loaïi öùng duïng Internet maø ta coù theå taïo
treân Visual Basic. Chuùng ta ñeàu coù theå ñaùp öùng nhöõng söï kieän trong moät trang HTML,
tuy nhieân cuõng coù söï khaùc giöõa hai loaïi öùng duïng :
 Söï phuï thuoäc – ÖÙng duïng DHTML ñöôïc duøng cho intranet, vaø phuï thuoäc vaøo
Internet Explorer 4.0, trong khi IIS öùng duïng coù theå ñöôïc duøng treân Internet hoaëc
intranet. Ngöôøi söû duïng cuûa moät öùng duïng IIS khoâng caàn chæ ñònh heä ñieàu haønh
hay browser.
 Moâ hình ñoái töôïng – ÖÙng duïng DHTML duøng moâ hình ñoái töôïng khaùc vôùi öùng
duïng IIS ñeå truy xuaát vaø laøm vieäc vôùi nhöõng thaønh phaàn treân moät trang HTML.
Trong khi öùng duïng IIS duøng moâ hình ñoái töôïng Active Server Pages, DHTML
duøng moâ hình ñoái töôïng Dynamic HTML.
 Nôi xöû lyù caùc quaù trình - ÖÙng duïng IIS ñöôïc thieát keá ñeå thöïc thi haàu heát caùc
quaùtrình xöû lyù cuûa noù treân Web Server, coøn öùng duïng DHTML thöïc thi quaù trình
xöû lyù cuûa noù treân maùy browser. Ta khoâng theå taïo baát cöù thaønh phaàn Web Server
naøo khi ta taïo moät öùng duïng DHTML.

2.2. Caùc kyõ thuaät laäp trình Web maø Visual Basic hoã trôï
2.2.1. VBScript
Microsoft Visual Basic Scripting, thaønh phaàn môùi nhaát cuûa hoï ngoân ngöõ laäp trình
Visual Basic, mang nhöõng Script ñoäng vaøo nhöõng moâi tröôøng khaùc nhau, bao goàm
Script client Web trong Microsoft Internet Explorer vaø Script Server Web trong
Microsoft Internet Information Server.
Visual Basic Scripting ñöôïc thieát keá ñeå laøm chuû beân trong moät Internet browser,
nhö laø Microsoft Internet Explorer hay nhöõng browser khaùc. VBScript laø kyõ thuaät
ngoân ngöõ cöïc nhanh vaø maïnh daønh cho nhöõng moâi tröôøng gioáng nhö Internet, intranet,
hay Word Wide Web. Noù cho pheùp nhöõng nhaø phaùt trieån duøng Visual Basic ñeå nhanh
choùng taïo ra nhöõng giaûi phaùp cho Internet hay Word Wide Web.
Do VBScript laø moät ngoân ngöõ phaùt trieån qua platform, neân khoâng coù moät soá thaønh
phaàn cuûa ngoân ngöõ Visual Basic cho nhöõng öùng duïng. Chuùng bao goàm nhöõng haøm
xuaát nhaäp file, nhöõng haèng vaø loaïi döõ lieäu thuoäc beân trong. Ta coù theå vieát maõ
VBScript trong cöûa soå maõ cuûa Visual Basic, nhöng khoâng theå chaïy hay kieåm tra öùng
duïng trong Visual Basic IDE.

2.2.2. Dynamic HTML

Trang 13
Dynamic HTML laø moät taäp hôïp caùc tính naêng coù tính chaát ñoåi môùi trong Microsoft
Internet Explorer 4.0 Dynamic HTML cho nhöõng nhaø saùng taùc khaû naêng taïo nhöõng taøi
lieäu HTML thaät noåi baät , caùi maø töông taùc vôùi ngöôøi söû duïng maø khoâng phaûi döïa treân
nhöõng chöông trình server – side hay taäp hôïp nhöõng trang HTML phöùc taïp ñeå taïo ra
nhöõng hieäu quaû ñaëc bieät.
Vôùi Dynamic HTML, ta coù theå deã daøng theâm vaøo nhöõng hieäu öùng, ví duï:
 Laøm aån ñi vaên baûn vaø hình aûnh vaøo trong taøi lieäu vaø giöõ noäi dung aån cho ñeán
khi qua moät khoaûng thôøi gian ñaõ chæ ñònh hay ngöôøi söû duïng töông taùc vôùi trang
naøy.
 Laøm cho vaên baûn vaø hình aûnh trong taøi lieäu cuûa trôû neân soáng ñoäng. Moãi thaønh
phaàn hoaït ñoäng ñoäc laäp töø baát kyø ñieåm baát ñaàu naøo cho ñeán baát cöù ñieåm keát
thuùc naøo, theo moät ñöôøng daãn ta choïn hay ngöôøi söû duïng ñaõ choïn .
 Taïo moät ñoàng hoà ñeå töï ñoäng caäp nhaät noäi dung môùi nhaát, kho trích daãn, hay döõ
lieäu khaùc
 Taïo moät form sau ñoù ñoïc, xöû lyù, vaø ñaùp öùng cho döõ lieäu maø ngöôøi söû duïng nhaäp
vaøo trong form.
Dynamic HTML laøm vieäc raát toát vôùi nhöõng öùng duïng, nhöõng ñieàu khieån Active X,
vaø nhöõng caùi khaùc chaáp nhaän nhöõng ñoái töôïng. Ta coù theå duøng nhöõng öùng duïng vaø
ñieàu khieån ñang toàn taïi hay taïo ra moät thaønh phaàn môùi. Nhöõng öùng duïng vaø ñieàu
khieån laøm vieäc raát toát khi noù döïa vaøo ñoù ñeå xöû lyù nhöõng taùc vuï khoù khaên , vaø duøng
Dynamic HTML ñeå hieån thò keát xuaát vaø xöû lyù thoâng tin ngöôøi söû duïng nhaäp vaøo.

2.2.3. Nhöõng thaønh phaàn ActiveX


Nhöõng thaønh phaàn ActiveX cho ta khaû naêng taïo ra öùng duïng baèng caùch keát hôïp
nhöõng öùng duïng tinh vi töø nhöõng caùi ñaõ coù saün. ActiveX laø moät ñoái töôïng, nhöng
khoâng phaûi baát cöù ñoái töôïng naøo cuõng laø ActiveX maø noù phaûi tuaân theo 2 tieâu chuaån
chính : ñoù laø ñoái töôïng COM (Component Object Model), vaø coù khaû naêng töï ñaêng kyù.
Ñoù laø nhöõng ñoaïn chöông trình ñoäc laäp thöïc hieän moät chöùc naêng naøo ñoù maø coù theå
ñöôïc goïi bôûi nhöõng öùng duïng baát kyø khaùc. Khi baïn xaây döïng nhöõng trang Web thì
ActiveX Control seõ laøm cho trang Web cuûa baïn soáng ñoäng vôùi nhöõng tính naêng phong
phuù, vaø töông taùc cao vôùi ngöôøi söû duïng. ÖÙng duïng Visual Basic coù bao haøm nhieàu
loaïi thaønh phaàn ActiveX

 Nhöõng öùng duïng hoã trôï kyõ thuaät ActiveX, nhö laø Microsoft Excel, Microsoft
Word, vaø Microsoft Access, cung caáp nhöõng ñoái töôïng maø ta coù theå thao taùc laäp
trình töø beân trong öùng duïng Visual Basic cuûa chuùng ta. Ví duï ta coù theå duøng
nhöõng thuoäc tính, phöông thöùc vaø söï kieän cuûa Microsoft Excel, Microsoft Word,
vaø Microsoft Access trong öùng duïng cuûa ta.

 Nhöõng thaønh phaàn maõ cung caáp thö vieän cuûa nhöõng ñoái töôïng coù theå laäp trình .
Khoâng gioáng nhö moät ñoái töôïng trong öùng duïng cho pheùp ActiveX , moät ñoái

Trang 14
Laäp Trình Web Vôùi Visual Basic

töôïng trong moät thaønh maõ coù theå chaïy trong cuøng moät quaù trình vôùi öùng duïng
cuûa ta, cho pheùp nhanh choùng truy xuaát tôùi nhöõng ñoái töôïng naøy.

 Ta coù theå theâm nhöõng tính naêng maø khoâng phaûi taïo chuùng baèng caùch söû duïng
nhöõng ñieàu khieån ActiveX. Ví duï nhö hieån thò moät lòch coâng taùc treân moät form
hoaëc ñoïc döõ lieäu ñöôïc ñònh daïng ñaëc bieät.
 Nhöõng taøi lieäu Active X cho pheùp ta taïo nhöõng öùng duïng Internet töông taùc . Ta
coù theå taïo nhöõng form coù theå ñöôïc caát giöõ trong Internet Explorer. Nhöõng taøi
lieäu ActiveX coù theå hieån thò hoäp thoâng baùo , form vaø bao haøm nhöõng ñieàu khieån
Active X . Nhöõng taøi lieäu ActiveX coù theå coù chöùc naêng nhö laø nhöõng thaønh
phaàn maõ.

Trang 15
PHAÀN II :
GIÔÙI THIEÄU ÑEÀ TAØI

I. Ñeà taøi
Laäp trình Web baèng ngoân ngöõ Visual Basic 6.0

II. Nhieäm vuï ñeà taøi


Taïo ra moät moâ phoûng cuûa ñieän thoaïi di ñoäng, vôùi nhöõng tính naêng, taùc vuï cuõng nhö
nguyeân lyù hoaït ñoäng döïa theo moät loaïi maùy ñieän thoaïi di ñoäng coù thöïc, vôùi yeâu caàu laø
ngöôøi söû duïng treân maïng coù theå duøng ñöôïc nhö moät ñieän thoaïi thaät söï.

Trang 16
Laäp Trình Web Vôùi Visual Basic

PHAÀN III :
PHAÂN TÍCH VAØ THIEÁT KEÁ ÑEÀ TAØI

I. Phaân tích ñeà taøi


1. Xaùc ñònh muïc tieâu cuûa chöông trình
Nhieäm vuï cuûa chöông trình laø taïo ra moät website, treân ñoù moâ phoûng moät ñieän thoaïi
di ñoäng, vôùi ñaày ñuû nhöõng tính naêng, taùc vuï nhö moät ñieän thoaïi thaät söï. Theâm vaøo ñoù,
website phaûi coù nhöõng trang höôùng daãn thaät ñaày ñuû, chi tieát veà nhöõng tính naêng, taùc
vuï, vôùi muïc tieâu laø moät ngöôøi söû duïng bình thöôøng, khi ñoïc qua nhöõng höôùng daãn,
cuõng coù theå deã daøng söû duïng ñieän thoaïi moâ phoûng naøy nhö laø moät ñieän thoaïi thaät söï.

2. Xaùc ñònh caùch hieän thöïc chöông trình


Do nhieäm vuï cuûa ñeà taøi laø laäp trình Web vôùi ngoân ngöõ laäp trình laø Visual Basic 6.0,
do ñoù yeâu caàu phaûi naém vöõng nhöõng kieán thöùc cô baûn cuûa Visual Basic 6.0, nhö caùc
ñieàu leänh, caùc toaùn töû, caùc caáu truùc tuyeån, caùch laøm vieäc vôùi bieán, vôùi file …. Ngoaøi
phaûi naém vöõng caùc kieán thöùc cô baûn ñoù, chuùng em coøn phaûi tìm hieåu theâm caùc khaùi
nieäm cô baûn veà Internet ñeå tieän cho vieäc trieån khai öùng duïng sau naøy.
Do yeâu caàu cuûa ñeà taøi laø taïo ra 1 moâ phoûng ñieän thoaïi di ñoäng, maø ngöôøi söû duïng
coù theå söû duïng treân maïng. Vaán ñeà ñaët ra laø phaûi tìm moät coâng cuï maø Visual Basic 6.0
cung caáp ñeå taïo ra moät moâ phoûng ñieän thoaïi vôùi khaû naêng ñoà hoïa vaø töông taùc cao vôùi
ngöôøi söû duïng treân maïng.
Sau khi tìm hieåu caùc coâng cuï, ñoái töôïng maø Visual Basic 6.0 cung caáp, hoã trôï ñeå
phaùt trieån nhöõng öùng duïng treân Internet, chuùng em quyeát ñònh choïn ActiveX Control
laøm coâng cuï ñeå xaây döïng chöông trình (ñieän thoaïi moâ phoûng). Vôùi ActiveX Cotrol,
chuùng em coù theå taïo ra giao dieän ngöôøi söû duïng ñaùp öùng ñöôïc khaû naêng ñoà hoïa cao vaø
töông taùc vôùi ngöôøi söû duïng.
Theâm vaøo ñoù, chuùng em ñaõ duøng Microsoft Frontpage nhaèm taïo söï deã daøng trong
vieäc taïo caùc trang höôùng daãn ngöôøi söû duïng duøng nhöõng tính naêng ñöôïc xaây döïng
trong ñieän thoaïi moâ phoûng,

4. Caùc coâng cuï seõ duøng ñeå xaây döïng chöông trình
 Visual Basic 6.0.
 ActiveX Control trong Visual Basic 6.0.
 Microsoft Frontpage.

Trang 17
II. Thieát keá ñeà taøi
Phaàn thieát keá ñöôïc chia laøm 2 phaàn : thieát keá giao dieän vaø xaây duïng nhöõng tính
naêng taùc vuï cuûa ñieän thoaïi moâ phoûng.

1. Thieát keá giao dieän


Giao dieän cuûa chöông trình laø moät chuoãi caùc trang html, vôùi trang chính seõ trình
baøy vôùi ngöôøi söû duïng khi kích hoaït chöông trình laø

Treân trang chính naøy ñaõ thieát keá saün nhöõng lieân keát, laùi ngöôøi söû duïng ñeán nhöõng
trang khaùc nhau tuøy theo moái lieân keát maø hoï choïn

Trang 18
Laäp Trình Web Vôùi Visual Basic

Theo nhöõng lieân keát naøy, baïn seõ ñeán trang höôùng daãn cuõng nhö söû duïng ñieän thoaïi
moâ phoûng. Trang naøy ñöôïc chia laøm 3 frame, vôùi moãi frame laø moät trang khaùc nhau,
trình baøy nhöõng noäi dung khaùc nhau. Ngöôøi söû duïng coù theå laàn theo nhöõng moái lieân
keát ôû frame thöù nhaát (trình baøy trang caây tính naêng) ñeå xem nhöõng höôùng daãn chi tieát
veà caùch söû duïng nhöõng tính naêng ñoù ñöôïc trình baøy ôû frame thöù ba. Khi user xem
nhöõng höôùng daãn chi tieát ñoù, hoï coù theå tröïc tieáp kieåm nghieäm caùch hoaït ñoäng cuûa
nhöõng tính naêng ñöôïc xaây döïng treân ñieän thoaïi moâ phoûng treân frame thöù hai cuûa trang
naøy.

Trang trình baøy caáu truùc caây nhöõng tính naêng ñöôïc xaây döïng trong ñieän thoaïi moâ
phoûng

Trang 19
Trang höôùng daãn söû duïng, trình baøy thaät chi tieát caùch duøng nhöõng tính naêng ñaõ ñöôïc
moâ phoûng

Trang trình baøy ñieän thoaïi moâ phoûng vaø ngöôøi söû duïng coù theå duøng tröïc tieáp nhö moät
ñieän thoaïi thaät söï

Trang 20
Laäp Trình Web Vôùi Visual Basic

2. Xaây döïng nhöõng tính naêng trong ñieän thoaïi moâ phoûng
Nhöõng tính naêng, taùc vuï trong ñieän thoaïi moâ phoûng ñöôïc xaây döïng döïa treân moät
loaïi maùy ñieän thoaïi di ñoäng coù thöïc, maùy Motorola Cd928. Do xaây döïng döïa treân moät
maùy coù thöïc neân nhöõng tính naêng cuõng nhö nguyeân lyù hoaït ñoäng cuûa noù cuõng phaûi
ñöôïc baûo ñaûm nhö maùy thaät.
Nhöõng tính naêng cuûa maùy ñöôïc tích hôïp trong caùc menu, trong ñoù menu chính seõ laø

(1) (2) (3) (4) (5) (6)


Phone Call Related Messages Phone Network Accessory
Book Features Setup Selection
(1)

Nhöõng tính naêng trong menu coù chöùc naêng cuoän troøn theo nguyeân lyù nhö maùy
Motorola Cd928.

 (1) ,….: trình töï cuûa caùc menu con

Trang 21
1. Menu Phone Book

Phone Book
Personal Number
- Find Entry
Enter Name - Call Number
By Name
- Modify Name Or Number
- Erase Name And Number

- Find Entry
Enter Location - Call Number
By Location
- Modify Name Or Number
- Erase Name And Number

- Add Entry
- Add To Phone Memory
- Add To SIM Card Memory

- Check Capacity
- Check Phone Capacity
- Check SIM Capacity
- Prevent Access
- No Memory Restrictions
- To SIM Card Memory
- To Phone Memory
Fixed
-View Fixed Dial List - To Phone & SIM Memory
Dialling
-Setup Fixed Dialling _Enter PIN2
- On
- Off
- Edit Entry
- Add Entry
One-Touch
- To Phone Memory - Erase Entry
Dial Setting
- To SIM Memory
- To Fixed Dial List

Phone Book
Danh baï ñieän thoaïi ñieän töû. Laø nôi baïn coù theå löu nhöõng teân vaø soá ñieän thoaïi nhö moät
muïc rieâng leû.
Personal Number
Laø moät menu con duøng cho vieäc taïo vaø quaûn lyù danh saùch nhöõng soá ñieän thoaïi caù
nhaân cuûa baïn.
Find Entry by Name
Tuøy choïn ñöôïc duøng ñeå choïn moät soá ñieän thoaïi töø moät danh saùch coù thöù töï nhöõng
teân ñaõ ñöôïc löu trong danh baï ñieän thoaïi.

Find Entry by Location


Tuøy choïn ñöôïc duøng ñeå choïn moät soá ñieän thoaïi töø moät danh saùch coù thöù töï nhöõng
vò trí ñaõ ñöôïc löu trong danh baïñieän thoaïi.

Trang 22
Laäp Trình Web Vôùi Visual Basic

Call Number
Goïi cho soá ñieän thoaïi vöøa tìm thaáy.
Modify Name Or Number
Duøng cho vieäc thay ñoåi teân vaø soá ñieän thoaïi cuûa muïc vöøa tìm thaáy.
Erase Name And Number
Xoaù teân vaø soá ñieän thoaïi cuûa muïc vöøa tìm thaáy.

Add Entry
Tuøy choïn duøng ñeå theâm muïc vaøo trong danh baï ñieän thoaïi.
Add To Phone Memory
Theâm moät muïc vaøo trong boä nhôù cuûa ñieän thoaïi.
Add To SIM Card Memory
Theâm moät muïc vaøo trong boä nhôù cuûa theû SIM.

Check Capacity
Kieåm tra khaû naêng chöùa coøn laïi cuûa danh baï ñieän thoaïi.
Check Phone Capacity
Kieåm tra söùc chöùa trong boä nhôù cuûa ñieän thoaïi.
Check SIM Capacity
Kieåm tra söùc chöùa trong boä nhôù cuûa theû SIM.

Prevent Access
Tuøy choïn duøng cho vieäc ngaên ngöøa truy xuaát ñeán danh saùch soá ñieän thoaïi ñöôïc löu
trong danh baï ñieän thoaïi.
No Memory Restrictions
Khoâng giôùi haïn söï truy xuaát ñeán boä nhôù.
To SIM Card Memory
Giôùi haïn vieäc truy xuaát ñeán danh saùch soá ñieän thoaïi ñöôïc löu trong boä nhôù theû
SIM.
To Phone Memory
Giôùi haïn vieäc truy xuaát ñeán danh saùch soá ñieän thoaïi ñöôïc löu trong boä nhôù ñieän
thoaïi.
To Phone & SIM Memory
Giôùi haïn vieäc truy xuaát ñeán danh saùch soá ñieän thoaïi ñöôïc löu trong caû boä nhôù
theû SIM vaø boä nhôù ñieän thoaïi.

Fixed Dialling
Tính naêng naøy cho pheùp giôùi haïn vieäc söû duïng ñieän thoaïi baèng caùch chæ goïi ñöôïc
nhöõng soá coù soá hay tieàn toá truøng vôùi nhöõng soá hay tieàn toá ñaõ löu trong danh saùch soá coá
ñònh.
View Fixed Dial List

Trang 23
Tuyø choïn duøng ñeå xem caùc muïc ñaõ ñöôïc löu trong danh saùch soá coá ñònh.

Setup Fixed Dialling


Duøng ñeå thieát laäp caùc tuøy choïn cho muïc goïi soá coá ñònh.
On
Cho pheùp duøng tính naêng goïi soá coá ñònh.
Off
Khoâng cho pheùp duøng tính naêng goïi soá coá ñònh.
Edit Entry
Hieäu chænh moät muïc (teân, soá ñieän thoaïi) trong danh saùch soá coá ñònh.
Add Entry
Theâm moät muïc (teân, soá ñieän thoaïi) vaøo trong danh saùch soá coá ñònh.
Erase entry
Xoaù moät muïc (teân, soá ñieän thoaïi) töø danh saùch soá coá ñònh.

One-Touch Dial Setting


Tính naêng naøy cho pheùp chæ ñònh danh saùch naøo coù theå ñöôïc quay soá chæ vôùi moät phím.
To Phone Memory
Nhöõng soá ñieän thoaïi ñöôïc löu trong boä nhôù ñieän thoaïi coù vò trí töø 1 ñeán 9 seõ ñöôïc
quay soá chæ vôùi moät phím.
To SIM Memory
Nhöõng soá ñieän thoaïi ñöôïc löu trong boä nhôù theû SIM coù vò trí töø 101 ñeán 109 seõ
ñöôïc quay soá chæ vôùi moät phím.
To Fixed Dial List
Nhöõng soá ñieän thoaïi ñöôïc löu trong danh saùch soá coá ñònh coù vò trí töø 1 ñeán 9 seõ
ñöôïc quay soá chæ vôùi moät phím.

Trang 24
Laäp Trình Web Vôùi Visual Basic

2. Menu Call Related Features


Call Related
Features

Show BatteryMetter
Restrict My
- Show ID On Next Call
Phone Number
- Restrict ID On Next Call
Call Diverting - Divert When
- Divert Voice Calls
Unavailable
- Divert Fax Calls
- Divert All
- Divert Data Calls
Talk and Fax Voice Calls
- Cancel All Diverting
- Detailed
Call Waiting Diverting

Call Barring
- Bar Outgoing
- Int’l Calls
Calls
- Int’l Calls Except Home
Key Answer Only - All Calls
- Off
- Bar Incoming
- When Roaming
Calls
- All Calls
- Off
- Cancel All Barring
- Change Bar Password

Call Related Features


Caùc ñaëc ñieåm veà cuoäc ñieän thoaïi.

Show Battery Meter


Hieån thò ñoàng hoà ño naêng löôïng cuûa pin ñieän thoaïi.

Restrict My Phone Number


Show ID On Next Call
Soá ñieän thoaïi cuûa baïn seõ ñöôïc göûi ñi vôùi cuoäc goïi keá, nhöng sau ñoù noù seõ khoâng
ñöôïc göûi ñi cho ñeán khi baïn choïn laïi tính naêng naøy.
Restrict ID On Next Call
Soá ñieän thoaïi cuûa baïn seõ khoâng ñöôïc göûi ñi vôùi cuoäc goïi keá, sau ñoù soá ñieän thoaïi
cuûa baïn seõ ñöôïc göûi ñi vôùi nhöõng cuoäc goïi keá cho ñeán khi baïn choïn laïi tính naêng
naøy.

Trang 25
Call Diverting
Tính naêng naøy duøng ñeå chuyeån cuoäc goïi ñeán ñeán nhöõng soá ñieän thoaïi khaùc khi ñieän
thoaïi cuûa baïn khoâng hoaït ñoäng, hoaëc khi baïn khoâng muoán nhaän cuoäc goïi ñoù.
Divert Voice Calls
Chuyeån cuoäc goïi
Divert When Unavailable
Chuyeån taát caû caùc cuoäc goïi ñeán ñeán moät soá ñieän thoaïi khaùc moãi khi ñieän thoaïi
cuûa baïn khoâng hoaït ñoäng.
Divert All Voice Calls
Chuyeån taát caû caùc cuoäc goïi ñeán ñeán moät soá ñieän thoaïi khaùc maø khoâng theo moät
ñieàu kieän naøo caû.
Detailed Diverting
Tính naêng naøy duøng ñeå chæ ñònh chuyeån nhöõng cuoäc goïi ñeán ñeán nhöõng soá khaùc
nhau
If Busy
Chuyeån cuoäc goïi ñeán neáu ñieän thoaïi cuûa baïn ñang baän.
If Not Reachable
Chuyeån cuoäc goïi ñeán neáu ñieän thoaïi cuûa baïn khoâng theå tieáp xuùc ñöôïc bôûi
maïng.
If No Answer
Chuyeån cuoäc goïi ñeán neáu baïn khoâng muoán traû lôøi.

Divert Fax Calls


Tính naêng naøy cho pheùp baïn chuyeån taát caû nhöõng cuoäc nhaän baèng Fax ñeán moät soá
ñieän thoaïi ñôn.
Divert Data Calls
Tính naêng naøy cho pheùp baïn chuyeån taát caû nhöõng cuoäc nhaän baèng döõ lieäu ñeán moät
soá ñieän thoaïi ñôn.
Cancle All Diverting
Duøng ñeå huûy toaøn boä chöùc naêng chuyeån cuoäc goïi.

Talk and Fax


Laø moät tính naêng maïng cho pheùp baïn noùi vaø sau ñoù göûi hoaëc nhaän fax trong moät cuoäc
goïi. Noù coù 2 tuøy choïn : On vaø Off.

Call Waiting
Quy ñònh caùch maø maùy seõ baùo hieäu khi coù moät cuoäc goïi ñang chôø. Noù coù 2 tuøy choïn :
On vaø Off.

Call Barring
Laø moät tính naêng maïng duøng cho vieäc chaën cuoäc goïi.

Trang 26
Laäp Trình Web Vôùi Visual Basic

Bar Outgoing Calls


Chaën nhöõng cuoäc goïi ñi.
Int’l Calls
Chöùc naêng naøy seõ chaën nhöõng cuoäc goïi ñi quoác teá moãi khi noù ñöôïc choïn.
Int’l Calls Except Home
Chöùc naêng naøy seõ chaën nhöõng cuoäc goïi ñi quoác teá ngoaïi tröø ñaát nöôùc cuûa baïn.
All Calls
Chaën taát caû nhöõng cuoäc goïi ñi.
Off
Huûy boû chöùc naêng chaën cuoäc goïi cho nhöõng cuoäc goïi ñi.

Bar Incoming Calls


Chaên nhöõng cuoäc goïi ñeán.
When Roaming
Chaën nhöõng cuoäc goïi ñeán khi baïn ñang roaming
All Calls
Chaën taát caû nhöõng cuoäc goïi ñeán.
Off
Huûy boû chöùc naêng chaën cuoäc goïi cho nhöõng cuoäc goïi ñeán.

Cancle All Barring


Huûy toaøn boä chöùc naêng naêng chaën cuoäc goïi cho nhöõng cuoäc goïi ñi hoaëc nhöõng cuoäc
goïi ñeán.

Change Bar Password


Thay ñoåi maõ chaën cuoäc goïi.

Key Answer Only


Chæ ñònh caùch traû lôøi cuoäc goïi ñeán baèng caùch duøng phím, hay môû naép maùy seõ traû lôøi
cuoäc goïi ñeán.

Trang 27
3. Menu Messages

Messages

Call Voicemail
Outgoing Message List - Send Message
Messages - Edit Message - Send Message
- Delete Message - Store Message
- Go To Next Message
Message Editor
- Send Message
- Store Message
Cell Broadcast
- On
- Off
Message Settings
- Voicemail Number
- Service Centre
- Expiry Period
- Outgoing Massege Type

Call VoiceMail
Tuøy choïn seõ laøm moät cuoäc goïi ñeán soá hoäp thö thoaïi hieän taïi.

Outgoing Messages
Duøng ñeå xem vaø quaûn lyù baát kyø tin nhaén göûi ñi. Nhöõng tin nhaén naøy ñöôïc löu treân theû
SIM.
Send Message
Duøng ñeå theâm vaøo soá ñieän thoaïi, nôi ñeán cuûa tin nhaén.
Enter Number
Duøng caùc phím soá nhaäp vaøo soá ñieän thoaïi ñích, vaø göûi tin nhaén ñi theo soá ñieän
thoaïi naøy.
Find Entry by Name
Tìm soá ñieän thoaïi theo teân ñaõ löu trong danh baï ñieän thoaïi vaø göûi tin nhaén ñi
theo soá ñieän thoaïi naøy.
Find Entry by Location
Tìm soá ñieän thoaïi theo vò trí ñaõ löu trong danh baï ñieän thoaïi vaø göûi tin nhaén ñi
theo soá ñieän thoaïi naøy.

Edit Message
Hieäu chænh tin nhaén ñaõ choïn hay taïo moät tin nhaén môùi.

Trang 28
Laäp Trình Web Vôùi Visual Basic

Send Message
Göûi tin nhaén vöøa môùi hieäu chænh.
Store Message
Löu laïi tin nhaén sau khi hieäu chænh.

Delete Message
Xoaù tin nhaén ñang xem hieän taïi.
Go to Next Message
Hieån thò tin nhaén keá tieáp.

Message Editor
Hieäu chænh tin nhaén ñaõ choïn hay taïo moät tin nhaén môùi.
Send Message
Göûi tin nhaén vöøa môùi hieäu chænh.
Store Message
Löu laïi tin nhaén sau khi hieäu chænh.

Cell Broadcast
Dòch vuï phaùt thanh. Noù coù 2 tuøy choïn : On vaø Off.

Message Settings
Caøi ñaët tin nhaén.
Voicemail Number
Duøng ñeå nhaäp vaøo soá ñieän thoaïi, laø soá ñöôïc duøng trong muïc “Call Voicemail”.
Service Centre
Tröôùc khi baïn göûi ñi baát kyø tin nhaén naøo, baïn phaûi duøng tuøy choïn naøy ñeå nhaäp vaøo
soá cuûa trung taâm dòch vuï tin nhaén.
Expiry Period
Duøng ñeå chæ ñònh khoaûng thôøi gian toái ña maø nhöõng tin nhaén chöa ñöôïc göûi ñi, ñöôïc
löu laïi treân trung taâm dòch vuï tin nhaén tröôùc khi bò xoùa.
Outgoing Message Type
Chæ ñònh daïng thöùc cuûa caùc tin nhaén göûi ñi. Ta coù theå choïn töø caùc daïng thöùc nhö
Text, Fax, Voice….

Trang 29
4. Menu Phone Setup

Phone Setup

Select Phone Line


Adjust Ring Volume
Ring or Vibrate
- Ring Only
- Vibrate
- Vibrate Then Ring
- No Ring or Vibrate
Set Ringer Tone
- Standard Tone
Set Ringer Tone 2 - Music Tone

Phone Lock
- Automatic Lock
- Lock Now - On
Change SIM PIN2 Code - Change Unlock Code - Off
New Security Code
Extended Menus
- On
Show Time and Date - Off
Set Time and Date
Set Time Format
Battery Saving Mode
- On
- Off
Select Keypad Tone
- Normal Tones
- Single Tone
- No Tones

Phone Setup
Caøi ñaët ñieän thoaïi.

Select Phone Line


Duøng ñeå chuyeån ñoåi vieäc choïn ñöôøng daây 1 hoaëc ñöôøng daây 2.

Adjust Ring Volume


Tuøy choïn duøng ñeå ñieàu chænh aâm löôïng chuoâng baùo hieäu khi coù moät cuoäc goïi ñeán.

Ring or Vibrate
Chæ ñònh caùch baùo hieäu maø maùy seõ thöïc hieän khi coù moät cuoäc goïi ñeán.

Trang 30
Laäp Trình Web Vôùi Visual Basic

Ring Only
Maùy seõ phaùt ra tieáng chuoâng theo theo ñieäu ñaõ ñöôïc chæ ñònh trong muïc “Set
Ringer Tone”
Vibrate Only
Maùy chæ rung khi coù moät cuoäc goïi ñeán.
Vibrate Then Ring
Maùy seõ rung hai laàn vaø sau ñoù laø tieáng chuoâng.
No Ring or Vibrate
Maùy chæ baùo hieäu baèng caùch hieån thò thoâng baùo “Call”.

Set Ringer Tone


Thieát laäp tieáng chuoâng baùo hieäu khi coù cuoäc goïi ñeán ñöôïc nhaän ôû ñöôøng daây 1.
Standard Tone
Tieáng chuoâng chuaån.
Music Tone
Khi ñöôïc choïn, maùy seõ toå hôïp nhöõng tieáng chuoâng khaùc nhau.

Phone Lock
Duøng ñeå thieát laäp, thay ñoåi maõ môû khoùa maùy
Automatic Lock
Töï ñoäng khoùa maùy moãi khi baät coâng taéc môû maùy.
Lock Now
Tuøy choïn naøy seõ khoùa maùy ngay laäp töùc. Khi ñoù maùy seõ khoâng söû duïng ñöôïc cho
ñeán khi nhaäp ñuùng maõ môû khoùa.
Change Unlock Code
Thay ñoåi maõ môû khoùa maùy.

New Security Code


Duøng ñeå thay ñoåi maõ baûo maät, maõ duøng cho vieäc ngaên ngöøa truy nhaäp ñeán nhöõng tính
naêng beân trong nhöõng menu.

Extened Menus
Duøng ñeå taét, môû menu môû roäng. Neáu tuøy choïn naøy ôû traïng thaùi taét, baïn khoâng theå
duøng ñöôïc baát kyø tính naêng môû roäng naøo.

Show Time and Date


Laø moät tính naêng môû roäng. Hieån thò ngaøy vaø giôø hieän taïi cho ñeán khi coù moät phím
ñöôïc nhaán.

Set Time and Date


Laø moät tính naêng môû roäng, duøng ñeå thay ñoåi laïi ngaøy vaø giôø hieän taïi.

Trang 31
Set Time Format
Laø moät tính naêng môû roäng, thieát laäp daïng thöùc hieån thò giôø cuûa maùy (daïng 12h hoaëc
24h)

Battery Saving Mode


Tính naêng naøy cho pheùp ta tieát kieäm naêng löôïng khi maùy ôû traïng thaùi khoâng ñaøm
thoaïi.

Select Keypad Tones


Tuøy choïn duøng ñeå thay ñoåi hoaëc khoâng cho pheùp coù aâm ñieäu khi moät phím ñöôïc nhaán.
Normal Tones
Tieáng bình thöôøng.
Single Tone
Tieáng ñôn
No Tones
Khoâng coù tieáng.

Trang 32
Laäp Trình Web Vôùi Visual Basic

5. Menu Network Selection

Network
Selection

Change
- Change to 900/1800
Band
- Change to 900
- Change to 1800
Available
- Register Now
Network
- Make Preferred

Network
- Registration
Search - Automatic Search
Preferences
- M anual Search
- Frequency
- Slow Search
Of Search
- M edium Search
- Fast Search
- Continuous Search
Preferred
- Add Network
Networks - Choose From Available
To List
- Choose From Known
- Show List - Add New Network Code
Of Networks
Find New - Move To New Location
Network - Delete Selection

Network Selection
Choïn maïng hoaït ñoäng. Ñeå laøm vaø nhaän nhöõng cuoäc goïi, maùy cuûa baïn phaûi ñaêng kyù
vôùi moät trong nhöõng maïng ñang hoaït ñoäng.

Change Band
Choïn baêng taàn hoaït ñoäng.
Change to 900/1800
Chuyeån sang daõy baêng taàn 900/1800
Change to 900
Chuyeån sang daõy baêng taàn 900
Change to 1800
Chuyeån sang daõy baêng taàn 1800

Available Networks
Tính naêng naøy seõ queùt ñeå tìm nhöõng maïng naøo ñang hoaït ñoäng ôû vò trí hieän taïi cuûa
baïn.

Trang 33
Register Now
Ñaêng kyù vôùi maïng baïn ñaõ choïn
Make Preferred
Löu laïi vò trí cuûa maïng ñaõ choïn trong danh saùch nhöõng maïng öu tieân.

Network Search
Tìm maïng.
Registration Preferences
Chæ ñònh caùch thöùc maùy seõ laøm theá naøo ñeå ñaêng kyù vôùi moät maïng.
Automatic Search
Töï ñoäng tìm vaø ñaêng kyù vôùi moät maïng.
Manual Search
Tìm vaø ñaêng kyù vôùi moät maïng baèng caùch thuû coâng.

Frequency of Search
Chæ ñònh ñieän thoaïi cuûa baïn phaûi chôø bao laâu tröôùc khi noù coá gaéng ñaêng kyù laïi sau
khi vieäc ñaêng kyù tröôùc ñoù ñaõ thaát baïi.
Slow Search
Medium Search
Fast Search
Continuous Search

Preferred Networks
Danh saùch nhöõng maïng öu tieân.
Add Network To List
Theâm maïng ñaõ choïn vaøo trong danh saùch nhöõng maïng öu tieân.
Choose From Available
Choïn maïng töø danh saùch nhöõng maïng ñang hoaït ñoäng ôû vò trí hieän taïi cuûa baïn.
Choose From Known
Choïn maïng töø taäp hôïp danh saùch nhöõng maïng ñaõ ñöôïc ñònh nghóa töø tröôùc.

Show List Of Networks


Hieån thò danh saùch nhöõng maïng öu tieân.
Move To New Location
Di chuyeån maïng ñaõ choïn ñeán moät vò trí môùi.
Delete Selection
Xoaù maïng ñaõ choïn khoûi danh saùch nhöõng maïng öu tieân.

Find New Network


Tìm maïng môùi.

Trang 34
Laäp Trình Web Vôùi Visual Basic

6. Menu Accessory Setup


5.
Accessory Setup

Mute Car Radio


- On
- Off
Automatic Answer
- On
- Off

Automatic Handsfree
- On
- Off
Safety Timer
- On
- Off

Auxiliary Alert
- On
- Off

Accessory Setup
Thieát laäp nhöõng thieát bò ñính keøm.

Mute Car Radio


Laøm taét tieáng cuûa radio khi baïn laøm hoaëc nhaän moät cuoäc goïi.

Automatic Answer
Khi ñöôïc choïn, maùy seõ töï ñoäng traû lôøi khi coù moät cuoäc goïi ñeán sau 2 laàn chuoâng.

Automatic Handsfree
Chuyeån cuoäc ñaøm thoaïi baèng caùch duøng tai nghe vaø speaker.

Safety Timer
Auxiliary Alert
Ñeøn hieäu seõ nhaáp nhaùy khi coù moät cuoäc goïi ñeán.

Trang 35
7. Menu Quick Access

1 - Find Name?

2 - Add to SIM?

3 - Call Voicemail?

4 - Battery Meter?

5 - Show Time/Date?

6 - Adjust Ring?

7 - Switch Line 1/2?

8 - Vibrate On/Off?

9 - Change Band?

Quick Access Menu


Menu truy caäp nhanh laø moät tính naêng ñoäc ñaùo. Noù cho pheùp ta choïn 9 chöùc naêng
thöôøng duøng maø khoâng caàn phaûi raø tìm loøng voøng trong caùc menu. Ta cuõng coù theå
thieát keá laïi menu truy caäp nhanh tuøy theo yù thích.

Trang 36
Laäp Trình Web Vôùi Visual Basic

3. Maõ nguoàn cuûa chöông trình


3.1. Maõ nguoàn cuûa caùc trang HTML höôùng daãn söû duïng.
 Maõ nguoàn cuûa trang chính

<html>
<head>
<meta name="GENERATOR" content="Microsoft FrontPage 3.0">
<title>mot</title>
<style>
<!--
-->
</style>
</head>
<body background="bg4gride.gif">
<p><img src="Welhome4.gif" width="190" height="76" alt="Welhome4.gif (56575
bytes)"></p>
<p align="center">
<img src="motorola.jpg" width="229" height="70" alt="motorola.bmp (48214
bytes)">
&nbsp;&nbsp;
<img src="cd928.jpg" width="98" height="59" alt="cd928.bmp (17518 bytes)"></p>
<p align="left">&nbsp; &nbsp;&nbsp; &nbsp;&nbsp; &nbsp;&nbsp; &nbsp;&nbsp;
&nbsp;&nbsp;&nbsp;&nbsp; <font color="#004080">
&nbsp;&nbsp;&nbsp;&nbsp;</font>
<font face="VNI-Present" color="#000000">
<big><strong><big>Ñieän thoaïi nhoû cho theá giôùi lôùn</big></strong></big><br>
</font><font face="VNI-Vari">Moät ñieän thoaïi - nhieàu phong caùch - cd928 chính
laø söï theå hieän caù tính cuûa baïn</font></p>
<table border="1" width="87%" height="228">
<tr>
<td width="23%" height="63"><img src="0thkhao.gif" width="106"
height="36"></td>
<td width="133%" height="63"><font face="VNI-Times">Vôùi caáu truùc caây menu, cho
baïn moät caùi nhìn khaùi quaùt veà toaøn boä caáu truùc nhöõng tính naêng ñöôïc xaây döïng trong
maùy <big><font color="#FF0000">cd928</font></big>.</font></td>
<td width="21%" height="63"><a href="file:///C:/LV/chung.htm"><img src="0go.gif"
width="27" height="31" alt="click here de xem trang tham khao"
border="0"></a></td>
</tr>
<tr>
<td width="23%" height="67"><img src="Help.jpg" width="104" height="35"></td>

Trang 37
<td width="133%" height="67"><font face="VNI-Times">Vôùi nhöõng höôùng daãn tæ mæ,
roõ raøng, baïn seõ deã daøng tieáp caän caùch laøm theá naøo ñeå söû duïng nhöõng tính naêng cuûa
maùy <font color="#FF0000"><big>cd928</big></font>.</font></td>
<td width="21%" height="67"><a href="file:///C:/LV/chung.htm">
<img src="0go.gif" width="27" height="31" alt="click here de xem phan huong dan"
border="0"></a></td>
</tr>
<tr>
<td width="23%" height="42"><img src="SUDUNG.gif" width="105"
height="31"></td>
<td width="133%" height="42"><font face="VNI-Times">Moâ phoûng cuûa maùy
<big><font color="#FF0000">cd928</font></big>, cho baïn caûm giaùc nhö ñang söû
duïng moät maùy ñieän thoaïi thaät söï.</font></td>
<td width="21%" height="42"><a href="file:///C:/LV/chung.htm"><img src="0go.gif"
width="27" height="31" alt="click here de vao trang su dung" border="0"></a></td>
</tr>
<tr>
<td width="23%" height="32">
<img src="Maila.gif" width="100" height="32"></td>
<td width="133%" height="32">
<font face="VNI-Times">Xin chaân thaønh caûm ôn nhöõng ñoùng goùp cuûa caùc baïn.
</font></td>
<td width="21%" height="32"><a href="mailto:e9708155@dithcmut.edu.vn">
<img src="0go.gif" width="27" height="31" alt="click here de gui mail cho toi"
border="0"></a></td>
</tr>
</table>
<p align="center"><br>
<img src="3hand.gif" width="32" height="32" alt="3hand.gif (2453 bytes)">
<img src="0website.gif" width="100" height="30" alt="0website.gif (2635 bytes)">
<font face="VNI-Times"><br>
<a href="http://motorola.com">http://motorola.com</a></font></p>
<p align="left">&nbsp;</p>
<p align="left">&nbsp;</p>
<table border="1" width="660">
<tr>
<td width="100%">&nbsp;</td>
</tr>
</table>
</body>
</html>

Trang 38
Laäp Trình Web Vôùi Visual Basic

 Maõ nguoàn cuûa trang chöùa ñieän thoaïi moâ phoûng


<html>
<head>
<title>luan-van.CAB</title>
</head>
<body>
<p>
<object ID="UserControl1" CLASSID="CLSID:191803D8-6371-11D0-82CA-
B54CDE05F649"
CODEBASE="luan-van.CAB#version=1,2,0,0" width="137" height="262">
</object>
</p>
</body>
</html>

 Maõ nguoàn cuûa trang trình baøy caây tính naêng


<html>
<head>
<meta name="GENERATOR" content="Microsoft FrontPage 3.0">
<title></title>
<base target="main">
</head>
<body bgcolor="#FFFFFF" text="#000000">
<p><font color="#FF0000"><a name="phone">Phone Book</a></font><br>
<small>&nbsp;&nbsp;&nbsp;
<a href="use-phonebook.htm#phone-book">Personal Numbers</a><br>
&nbsp;&nbsp;&nbsp;
<a href="use-phonebook.htm#fixed dial">Fixed Dialling</a>
</small><br>&nbsp;&nbsp;
<a href="use-phonebook.htm#one touch"><small>One-Touch Dial Setting
</small></a>
&nbsp; <br>
<br>
<font color="#FF0000"><a name="features">Call Related Features<br>
</a></font><small>&nbsp;&nbsp;&nbsp;
<a href="use-phonebook.htm#show battery">Show Batery Meter
</a><br>&nbsp;&nbsp;&nbsp; Restric My Phone Number
<br>&nbsp;&nbsp;&nbsp;
<a href="use-phonebook.htm#call divert"> Call Diverting
</a></small><br>
<small>&nbsp;&nbsp;&nbsp; Talk and Fax<br>

Trang 39
&nbsp;&nbsp;&nbsp; Call Waiting<br>
&nbsp;&nbsp;&nbsp;
<a href="use-phonebook.htm#call bar">Call Baring</a><br>
&nbsp;&nbsp;&nbsp;
<a href="use-phonebook.htm#key answer">Key Answer Only
</a></small></p>
<p><font color="#FF0000">
<a name="messages">Messages<br>
</a></font><small>&nbsp;&nbsp;&nbsp;
<a href="use-phonebook.htm#call voicemail">Call Voicemail
</a><br>
&nbsp;&nbsp;&nbsp;
<a href="use-phonebook.htm#outgoing msg">Outgoing Messages</a><br>
&nbsp;&nbsp;&nbsp;
<a href="use-phonebook.htm#msg editor">Message Editor</a><br>
&nbsp;&nbsp;&nbsp; Cell Broadcast<br>
&nbsp;&nbsp;&nbsp;
<a href="use-phonebook.htm#msg setting">Message Settings</a></small></p>
<p><font color="#FF0000"><a name="setup">Phone Setup<br>
</a></font><small>&nbsp;&nbsp;&nbsp;
<a href="use-phonebook.htm#line">Select Phone Line</a><br>
&nbsp;&nbsp;&nbsp;
<a href="use-phonebook.htm#volume">Adjust Ring Volume</a><br>
&nbsp;&nbsp;
<a href="use-phonebook.htm#ring">Ring Or Vibrate</a><br>
&nbsp;&nbsp;&nbsp;
<a href="use-phonebook.htm#ringer">Set Ringer Tone</a><br>
&nbsp;&nbsp;&nbsp;
<a href="use-phonebook.htm#tone2">Set Ringer Tone 2</a></small><br>
<small>&nbsp;&nbsp;&nbsp;
<a href="use-phonebook.htm#lock">Phone Lock</a><br>
&nbsp;&nbsp;&nbsp;
<a href="use-phonebook.htm#code">New Security Code</a><br>
&nbsp;&nbsp;&nbsp;
<a href="use-phonebook.htm#extended">Extended Menus</a><br>
&nbsp;&nbsp;&nbsp;
<a href="use-phonebook.htm#show">Show Time and Date</a><br>
&nbsp;&nbsp;&nbsp;
<a href="use-phonebook.htm#set">Set Time Format</a><br>
&nbsp;&nbsp;&nbsp;
<a href="use-phonebook.htm#battery">Battery Saving Mode</a><br>

Trang 40
Laäp Trình Web Vôùi Visual Basic

&nbsp;&nbsp;&nbsp;
<a href="use-phonebook.htm#keypad">Select Keypad Tones</a><br>
</small><br>
<font color="#FF0000">Network Selection<br>
</font>&nbsp;
<a href="use-phonebook.htm#change band"><small>Change Band</small></a>
&nbsp;&nbsp;&nbsp; <br>
<small>&nbsp;&nbsp;
<a href="use-phonebook.htm#avail network">Available Network</a></small><br>
<small>&nbsp;&nbsp;
<a href="use-phonebook.htm#find network">Network Search</a></small><br>
<small>&nbsp;&nbsp;
<a href="use-phonebook.htm#prefer network">Preferred Networks</a></small><br>
<small>&nbsp;&nbsp;
<a href="use-phonebook.htm#find new">Find New Network</a>&nbsp;
</small>&nbsp;
</p>
<p><a href="use-phonebook.htm#quick access">
<font color="#0000FF">Quick Access Menu</font></a></p>
<p><a href="motorola_cd928__________________.htm" target="_top">
<img src=home.gif width="54" height="50" alt="click here de tro ve trang chinh"
border="0"></a></p>
<table border="1" width="100%">
<tr>
<td width="100%">&nbsp;</td>
</tr>
</table>
<p><br>
</p>
</body>
</html>

 Maõ nguoàn cuûa trang höôùng daãn


<html>
<head>
<meta name="GENERATOR" content="Microsoft FrontPage 3.0">
<title></title>
</head>
<body>
<p><font face="VNI-Times" color="#FF0000">
<a name="phone-book">Danh baï ñieän thoaïi rieâng<br>

Trang 41
</a></font><small><font face="VNI-Times" color="#000000">(Personal Number)
<br>&nbsp;&nbsp;&nbsp; Laø moät menu con ñöôïc duøng ñeå taïo vaø quaûn lyù danh
saùch caùc soá ñieän thoaïi caù nhaân. Ñeå vaøo muïc naøy, duøng caùc phím cuoän
<img src="up.jpg" width="26" height="20" alt="up.bmp (2550 bytes)"> ,
<img src="down.jpg" width="28" height="20" alt="down.bmp (2262 bytes)">
</font><font face="VNI-Times" color="#000000"> cuoän ñeán muïc &quot;
<strong>Phone Book</strong>&quot;, nhaán
</font><font face="VNI-Times">
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)">
&nbsp; 2 laàn ñeå vaøo menu con cuûa muïc &quot;
<strong>Personal Number</strong>&quot;<br>&nbsp;&nbsp;
<a href="use-phonebook.htm#find-name">Find Entry By Name
</a> (tìm soá ñieän thoaïi theo teân)
<br>&nbsp;&nbsp;
<a href="use-phonebook.htm#find-location">Find Entry By Location
</a> (tìm soá ñieän thoaïi theo vò trí)<br>
&nbsp;&nbsp;
<a href="use-phonebook.htm#add-entry">Add Entry
</a> (theâm vaøo soá ñieän thoaïi môùi)<br>
&nbsp;&nbsp;
<a href="use-phonebook.htm#check-capacity">Check Capacity
</a> (Kieåm tra söùc chöùa)</small><br>
<small>&nbsp;&nbsp;
<a href="file:///C:/Lv/use-phonebook.htm#prevent">Prevent Access
</a>(Ngaên ngöøa truy nhaäp)</small><br>
</font><small>&nbsp;&nbsp;
<font face="VNI-Times">Duøng caùc phím cuoän ñeå ñeán haïng muïc caàn choïn. Nhaán
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)"> ñeå choïn. Baám
phím <img src="cancel.jpg" width="17" height="19" alt="cancel.bmp (1526 bytes)">
ñeå thoaùt ra.</font></small></p>
<hr>
<p><font face="VNI-Times" color="#FF0000">
<a name="nhap-ky-tu">Caùch nhaäp moät kyù töï</a></font><small><br>
<font face="VNI-Times">
&nbsp;&nbsp;&nbsp; Duøng caùc phím soá ñeå nhaäp kyù töï. Ví duï : khi baám phím soá
</font><img src="5.jpg" width="24" height="17" alt="5.bmp (1734 bytes)">
<font face="VNI-Times">laàn ñaàu tieân thì noù seõ hieån thò kyù töï J. Nhaán phím naøy laàn
nöõa seõ thay baèng chöõ K, ...hieån thò soá 5.<br>
&nbsp;&nbsp;&nbsp; Baám vaø giöõ baát kyø moät phím seõ chuyeån taát caû caùc kyù töï thaønh
chöõ thöôøng, laëp laïi thao taùc naøy seõ chuyeån taát caû laïi thaønh chöõ hoa.<br>
&nbsp;&nbsp;&nbsp; Ta coù theå duøng phím

Trang 42
Laäp Trình Web Vôùi Visual Basic

<img src="right.jpg" width="22" height="17" alt="right.bmp (1818 bytes)"> ñeå nhaäp


vaøo kyù töï gioáng nhö kyù töï vöøa nhaäp tröôùc ñoù. Nhaán phím naøy laàn nöõa seõ taïo ra khoaûng
traéng.<br>
&nbsp;&nbsp;&nbsp; Xoùa moät kyù töï baèng caùch nhaán
<img src="cancel.jpg" width="17" height="19" alt="cancel.bmp (1526 bytes)">. <br>
&nbsp;&nbsp;&nbsp; Nhaán
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)"> ñeå löu laïi
thoâng tin.</font></small></p>
<hr>
<p><font face="vni-times" color="#FF0000">
<a name="find-name">Tìm moät soá ñieän thoaïi theo teân</a></font>
<small> <br>(Find Entry By Name) </small>
<ol>
<li><small><font face="VNI-Times">Duøng caùc phím cuoän
<img src="up.jpg" width="26" height="20" alt="up.bmp (2550 bytes)">,&nbsp;
<img src="down.jpg" width="28" height="20" alt="down.bmp (2262 bytes)"> cuoän
ñeán muïc &quot;
<strong>Phone Book</strong>&quot;&nbsp;
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)"> 3 laàn ñeå
vaøo muïc tìm soá ñieän thoaïi theo vò trí.</font></small></li>
<li><small><font face="VNI-Times">Maøn hình hieån thò thoâng baùo
&quot;<strong>Enter Name</strong>
&quot;, nhaäp vaøo teân cuûa soá ñieän thoaïi caàn tìm (toái ña3 kyù töï). Khi ñoù, maùy seõ tìm vaø
hieån thò teân cuûa soá ñieän thoaïi phuø hôïp. </font></small></li>
<li><small><font face="VNI-Times">Duøng caùc phím cuoän ñeå hieån thò nhöõng muïc
lieàn keá noù.</font></small></li>
<li><small><font face="VNI-Times">Khi tìm ñöôïc soá mong muoán, nhaán
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)"> ñeå vaøo menu
con<br>
- <strong>Call Number </strong>(goïi soá ñieän thoaïi naøy)<br>
- <strong>Modify Name or Number</strong> (söûa teân hoaëc soá ñieän thoaïi)<br>
- <strong>Erase Name and Number</strong> (Xoùa teân vaø soá ñieän thoaïi)
- </font></small></li>
</ol>
<p><small><font face="VNI-Times">Duøng caùc phím cuoän ñeå di chuyeån giöõa
nhöõng muïc naøy. Nhaán
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)"> ñeå choïn. Baám
phím
<img src="cancel.jpg" width="17" height="19" alt="cancel.bmp (1526 bytes)"> ñeå
thoaùt ra.</font></small></p>
<hr>

Trang 43
<p><font face="vni-times" color="#FF0000">
<a name="find-location">Tìm moät soá ñieän thoaïi theo vò trí </a><small><br>
</font><font face="vni-times" color="#000000">(Find Entry by Location)</font>
</small>
<ol>
<li><small><font face="VNI-Times">Duøng caùc phím cuoän
<img src="up.jpg" width="26" height="20" alt="up.bmp (2550 bytes)">,&nbsp;
<img src="down.jpg" width="28" height="20" alt="down.bmp (2262 bytes)"> ñeå cuoän
ñeán muïc &quot;
<strong>Phone Book</strong>&quot;,&nbsp;
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)"> 2 laàn ñeå vaøo
menu con cuûa muïc
<strong>Personal Number</strong>. Duøng phím
<img src="down.jpg" width="28" height="20" alt="down.bmp (2262 bytes)">&nbsp;
ñeå cuoän ñeán muïc &quot;tìm soá ñieän thoaïi theo vò trí&quot;,
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)">.
</font></small></li>
<li><small><font face="VNI-Times">Maøn hình hieån thò thoâng baùo
&quot;<strong>Enter Location</strong>
&quot;, nhaäp vaøo vò trí cuûa soá ñieän thoaïi caàn tìm. Khi ñoù, maùy seõ tìm vaø hieån thò teân
cuûa soá ñieän thoaïi phuø hôïp.</font></small></li>
<li><small>
<font face="VNI-Times">Duøng caùc phím cuoän ñeå hieån thò nhöõng muïc lieàn keá noù.
</font></small></li>
<li><small><font face="VNI-Times">Khi tìm ñöôïc soá mong muoán, nhaán
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)"> ñeå vaøo menu
con<br>
-<strong> Call Number</strong> (goïi soá ñieän thoaïi naøy)<br>
-<strong> Modify Name or Number</strong> (söûa teân hoaëc soá ñieän thoaïi)<br>
-<strong> Erase Name and Number</strong> (Xoùa teân vaø soá ñieän thoaïi)
</font></small></li>
</ol>
<p><small><font face="VNI-Times">Duøng caùc phím cuoän ñeå di chuyeån giöõa
nhöõng muïc naøy. Nhaán
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)"> ñeå choïn. Baám
phím
<img src="cancel.jpg" width="17" height="19" alt="cancel.bmp (1526 bytes)"> ñeå
thoaùt ra.</font></small></p>
<hr>
<p><font face="vni-times" color="#FF0000">
<a NAME="add-entry">Theâm vaøo soá ñieän thoaïi môùi</a> <small><br>

Trang 44
Laäp Trình Web Vôùi Visual Basic

</font><font face="vni-times" color="#000000">(Add Entry)</font> </small>


<ol>
<li><font face="VNI-Times"><small>Duøng caùc phím cuoän
<img src="up.jpg" width="26" height="20" alt="up.bmp (2550 bytes)">,&nbsp;
<img src="down.jpg" width="28" height="20" alt="down.bmp (2262 bytes)"> ñeå cuoän
ñeán muïc &quot;
<strong>Phone Book</strong>&quot;,&nbsp;
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)"> 2 laàn ñeå vaøo
menu con cuûa muïc
<strong>Personal Number</strong>. Duøng phím
<img src="down.jpg" width="28" height="20" alt="down.bmp (2262 bytes)">
&nbsp; ñeå cuoän ñeán muïc
&quot;theâm vaøo soá ñieän thoaïi môùi&quot;,
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)">
</small></font></li>
<li><small>
<font face="VNI-Times">Duøng caùc phím cuoän ñeå choïn vò trí
&quot;Cho vaøo boä nhôù cuûa maùy ñieän thoaïi
&quot; [<strong>Add to phone memory</strong>]hay 'Cho vaøo theû SIM
&quot; [<strong>Add to SIM card memory</strong>], baám
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)">
</font></small></li>
<li><small><font face="VNI-Times">Nhaäp vaøo soá ñieän thoaïi</font>,
<font face="VNI-Times">
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)">, ghi
teân, vò trí, baám
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)"> ñeå löu. Baám
phím
<img src="cancel.jpg" width="17" height="19" alt="cancel.bmp (1526 bytes)"> ñeå
thoaùt ra.</font></small></li>
</ol>
<hr>
<p><font face="vni-times" color="#FF0000">
<a name="check-capacity">Kieåm tra söùc chöùa</a></font>
<small><br>(Check Capacity)</small></p>
<p><small>
<font face="VNI-Times">Kieåm tra soá muïc coøn troáng trong boä nhôù cuûa ñieän thoaïi hay
boä nhôù SIM card</font><br>
<font face="VNI-Times">1.&nbsp;&nbsp;&nbsp; Duøng caùc phím cuoän
<img src="up.jpg" width="26" height="20" alt="up.bmp (2550 bytes)">,&nbsp;

Trang 45
<img src="down.jpg" width="28" height="20" alt="down.bmp (2262 bytes)"> ñeå cuoän
ñeán muïc &quot;
<strong>Phone Book</strong>&quot;,&nbsp;
<img src="ok.jpg" width="28" height="17"alt="ok.bmp (1902 bytes)"> 2 laàn ñeå vaøo
menu con&nbsp; cuûa muïc Personal Number.Tieáp tuïc duøng phím cuoän ñeå cuoän ñeán
muïc &quot;Kieåm tra söùc chöùa&quot;
<strong>[Check Capacity</strong>],
<img src="ok.jpg" width="28" height="17"alt="ok.bmp (1902 bytes)">.</small><br>
<small>2.&nbsp;&nbsp;&nbsp; Duøng caùc phím cuoän ñeå choïn vò trí &quot;Kieåm
tra söùc chöùa cuûa maùy ñieän thoaïi&quot;
[<strong>Check Phone Capacity</strong>]hay
&quot;Kieåm tra söùc chöùa cuûa theû SIM&quot;
[<strong>Check SIM apacity</strong>],baám
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)">. Maøn hình
seõ hieän thoâng baùo &quot;XX Unused Location&quot;.</small></font></p>

<hr>
<p><font face="VNI-Times">
<a name="prevent"><font color="#FF0000">Ngaên ngöøa truy nhaäp</font><br>
</a><small>(Prevent Access)</small><br>
<small>&nbsp;&nbsp; Ngaên ngöøa khoâng cho truy nhaäp vaøo nhöõng muïc ñaõ
ñöôïc löu trong boä nhôù, trong theû SIM hay caû hai.</small><br>
<small>1.&nbsp;&nbsp;&nbsp; Duøng caùc phím&nbsp;
<img src="up.jpg" width="26" height="20" alt="up.bmp (2550 bytes)">,&nbsp;
<img src="down.jpg" width="28" height="20" alt="down.bmp (2262 bytes)"> (phím
cuoän) ñeå cuoän ñeán muïc &quot;
<strong>Phone Book</strong>&quot;,&nbsp;
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)"> 2 laàn ñeå vaøo
menu con cuûa muïc
<strong>Personal Number</strong>. Tieáp tuïc duøng phím cuoän ñeå cuoän ñeán muïc
&quot;Ngaên ngöøa truy nhaäp &quot;
[<strong>Prevent Access</strong>],
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)">.<br>
2.&nbsp;&nbsp;&nbsp; Duøng caùc phím cuoän&nbsp; ñeå tuøy choïn nhöõng muïc
&quot;Khoâng giôùi haïn truy nhaäp&quot;
[<strong>No Memory Restrictions</strong>],
&quot;Giôiù haïn truy nhaäp ñeán theû SIM&quot;
[<strong>To SIM Card Memory</strong>],
&quot;Giôùi haïn truy nhaäp ñeán boä nhôù maùy&quot;
[<strong>To Phone Memory</strong>],
hay giôùi haïn caû hai, boä nhôù vaø theû SIM

Trang 46
Laäp Trình Web Vôùi Visual Basic

[<strong>To Phone &amp; SIM Memory</strong>].


Duøng caùc phím cuoän ñeå di chuyeån ñeán muïc caàn choïn nhaán
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)"> . Khi ñoù maøn
hình seõ hieän thoâng baùo nhaéc nhaäp vaøo maõ baûo maät
[<strong>Security Code</strong>]. Neáu nhaäp maõ ñuùng thì söï ngaên ngöøa truy nhaäp môùi
coù taùc duïng (Maõ maëc ñònh laø &quot;000000&quot; vaø coù theå thay ñoåi ñöôïc trong
phaàn Phone Setup).</small></font></p>
<hr>
<p><font face="VNI-Times" color="#FF0000">
<a name="fixed dial">Goïi soá coá ñònh<br>
</a></font><font face="VNI-Times"><small>(Fixed Dialling)</small><br>
<small>&nbsp;&nbsp;&nbsp; Tính naêng naøy cho pheùp baïn giôùi haïn vieäc duøng
ñieän thoaïi trong moät danh saùch soá ñieän thoaïi ñaõ ñöôïc ñònh nghóa tröôùc, hay laø moät
danh saùch maõ quoác gia, maõ vuøng hay laø moät tieàn toá naøo ñoù maø baïn choïn.</small><br>
<small>&nbsp;
&nbsp;&nbsp; Khi Fixed Dialling ñöôïc thieát laäp möùc On, baïn chæ goïi ñöôïc nhöõng soá
coù soá (hay tieàn toá) truøng vôùi nhöõng soá (hay tieån toá) ñaõ löu trong danh saùch Fixed Dial.
Neáu baïn thöû goïi soá khaùc thì thoâng baùo &quot;Restricted&quot; seõ hieån thò.</small>
<br><small>&nbsp;&nbsp;&nbsp;
<a href="#view fixed">View Fixed Dial List</a></small>
<small>(Xem danh saùch soá coá ñònh)</small><br>
<small>&nbsp;&nbsp;&nbsp;
<a href="#setup fixed">Setup Fixed Dialling</a> (Thieát laäp soá coá ñònh)</small>
<br><small>Duøng caùc phím cuoän ñeå di chuyeån giöõa nhöõng muïc naøy. Nhaán
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)"> ñeå choïn. Baám
phím <img src="cancel.jpg" width="17" height="19" alt="cancel.bmp (1526 bytes)">
ñeå thoaùt ra.</small></font></p>
<hr>
<p><font face="VNI-Times"><font color="#FF0000">
<a name="view fixed">Xem danh saùch soá coá ñònh<big><br>
</big></a></font><small>( View Fixed Dial List)</small><br>
<small>&nbsp;&nbsp;&nbsp; Xem danh saùch soá coá ñònh ñaõ ñöôïc löu trong Fixed Dial.
</small><br>
<small>1.&nbsp; Duøng caùc phím <small>
<img src="up.jpg" width="26" height="20" alt="up.bmp (2550 bytes)">,
<img src="down.jpg" width="28" height="20" alt="down.bmp (2262 bytes)">
</small>(phím cuoän)<small>&nbsp; </small>ñeå di chuyeån ñeán muïc
<strong> Phone Book</strong>, nhaán<small>
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)">
</small></font><br>2.&nbsp;&nbsp;&nbsp;
<font face="VNI-Times">Nhaán phím cuoän ñeå ñeán muïc &quot;

Trang 47
<strong>Fixed Dialling</strong>&quot;, nhaán
<small><img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)">
</small><br> .&nbsp;Tieáp tuïc duøng phím cuoän ñeå di chuyeån ñeán muïc
<strong>View Fixed Dial List</strong> . Muoán choïn nhaán <small>
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)">, </small>ñeå
thoaùt ra duøng phím <small>
<img src="cancel.jpg" width="17" height="19" alt="cancel.bmp (1526 bytes)">
</small></font></small><br>4.&nbsp; <small>
<font face="VNI-Times">Duøng phím cuoän ñeå duyeät qua danh saùch caùc soá trong
<strong>Fixed Dial List</strong> . Khi baïn ñaõ tìm thaáy soá baïn caàn, nhaán
<small><img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)">
</small>ñeå laøm cuoäc goïi.</font></small></p>
<hr>
<p><font color="#FF0000">
<a name="setup fixed"><font face="VNI-Times">Thieát laäp soá coá ñònh</font>
<big><br>
</big></a></font><font face="VNI-Times"><small>(Setup Fixed Dialling)</small>
<br><small>Baïn duøng tuøy choïn naøy ñeå chuyeån
<strong>Fixed Dialling</strong> ôû möùc
<strong>On</strong> hay <strong>Off</strong> vaø duøng ñeå theâm hay thay
ñoåi nhöõng muïc trong danh saùch
<strong>Fixed Dial</strong>.</small></font><br>
<small><font face="VNI-Times">Baïn phaûi nhaäp vaøo maõ PIN2 (maëc ñònh laø 13579)
khi baïn choïn muïc naøy. </font></small>&nbsp; </p>
<p><small><font face="VNI-Times">1.&nbsp; Duøng caùc phím <small>
<img src="up.jpg" width="26" height="20" alt="up.bmp (2550 bytes)">,
<img src="down.jpg" width="28" height="20" alt="down.bmp (2262 bytes)"></small>
&nbsp;(phím cuoän)<small> </small>ñeå di chuyeån ñeán muïc
<strong>Phone Book</strong>, nhaán<small>
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)">
</small></font><br>2.&nbsp;&nbsp;&nbsp;
<font face="VNI-Times">Nhaán phím</small>
<small>cuoän<small> </small>ñeå vaøo muïc &quot;
<strong>Fixed Dialling</strong>&quot;, nhaán <small>
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)"></small>.
<br>3.&nbsp; Tieáp tuïc duøng phím cuoän&nbsp; ñeå di chuyeån ñeán muïc &quot;
<strong>Setup Fixed Dialling</strong>&quot;. Muoán choïn nhaán <small>
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)">,
</small>ñeå thoaùt ra duøng phím<small>
<img src="cancel.jpg" width="17" height="19" alt="cancel.bmp (1526 bytes)">
</small></small></font>.<br>4.&nbsp;

Trang 48
Laäp Trình Web Vôùi Visual Basic

<font face="VNI-Times"><small>Nhaäp vaøo maõ PIN2 . Baám&nbsp; <small>


<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)">
</small>ñeå vaøo menu con cuûa noù, ñeå thoaùt ra duøng phím<small>
<img src="cancel.jpg" width="17" height="19" alt="cancel.bmp (1526 bytes)">
</small></small></font>.<br>
<font face="VNI-Times"><small><strong><font color="#000000">On</font>
</strong> </small><br>
<small>Chuyeån Fixed Dialling ôû möùc On</small><br>
<strong><font color="#000000"><small>Off</small></font></strong><br>
<small>Chuyeån Fixed Dialling ôû möùc Off</small><br>
<font color="#000000"><strong><small>Edit Entry</small></strong></font><br>
<small>Söûa ñoåi moät muïc trong danh saùch Fixed Dial. Khi baïn choïn muïc naøy, vò trí
ñaàu tieân trong danh saùch khoâng roãng seõ ñöôïc hieån thò. Duøng&nbsp; phím<small>
</small>cuoän<small> </small>ñeå di chuyeån ñeán&nbsp; muïc baïn muoán thay ñoåi, nhaán
<small><img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)">.
</small>Maøn hình seõ hieån thò moät promt ñeå baïn söûa ñoåi teân vaø soá ñieän hoaïi.
</small><br>
<font color="#400000"><strong><small>Add Entry</small></strong></font><br>
<small>Theâm vaøo moät teân vaø ñieän thoaïi vaøo trong danh saùch Fixed Dial.Maøn hình seõ
hieån thò moät promt ñeå baïn nhaäp vaøo teân, soá ñieän thoaïi vaø vò trí cuûa noù trong danh
saùch.</small><br>
<strong><font color="#400000"><small>Erase Entry</small></font>
<font color="#FF0000"><br>
</font></strong><small>Xoaù moät muïc ñaõ löu trong danh saùch Fixed Dial. Muïc
ñaàu tieân trong danh saùch seõ ñöôïc hieån thò. Di chuyeån ñeán muïc baïn muoán xoùa vaø nhaán
<small><img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)">
.</small></small><br>
<br>
<small>Duøng caùc phím cuoän<small> </small>ñeå di chuyeån giöõa caùc muïc naøy,
nhaán<small>
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)">
</small>ñeå choïn.</small></font></p>
<hr>
<p><font face="VNI-Times">
<a name="one touch"><font color="#FF0000">Quay soá vôùi 1 phím</font><br>
</a><small>(One-Touch Dial Setting)</small><br>
<small>&nbsp;&nbsp;&nbsp; Baïn duøng muïc naøy ñeå chæ ñònh danh saùch Phone
Book naøo coù theå ñöôïc quay soá chæ vôùi 1 phím.</small></font></p>
<p><small>
<font face="VNI-Times">1.&nbsp; Duøng caùc phím <small>
<img src="up.jpg" width="26" height="20" alt="up.bmp (2550 bytes)">,

Trang 49
<img src="down.jpg" width="28" height="20" alt="down.bmp (2262 bytes)">&nbsp;
</small>(phím cuoän) ñeå di chuyeån ñeán muïc
<strong>Phone Book</strong>, nhaán<small>
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)">
</small></font><br>2.&nbsp;&nbsp;&nbsp;
<font face="VNI-Times">Tieáp tuïc duøng&nbsp; phím&nbsp; cuoän ñeå vaøo muïc
&quot;<strong>One-Touch Dial Setting</strong>
&quot;.&nbsp;Nhaán <small>
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)">
</small>ñeå vaøo menu con</small><br>
<font color="#400000"><small>&nbsp;&nbsp;
<strong>To Phone Memory</strong></small></font><br>
<small>&nbsp;&nbsp;Cho vaøo boä nhôù ñieän thoaïi</small>
(<small>nhöõng vò trí töø 1 ñeán 9)</small><br>
<small><font color="#FF0000">&nbsp;&nbsp;</font>
<font color="#400000"><strong>To SIM Memory</strong></font></small>
<font color="#FF0000"><br>
</font><small>&nbsp;&nbsp; Cho vaøo boä nhôù theû SIM </small>
(<small>nhöõng vò trí töø 101 ñeán 109)</small><br>
<small><font color="#FF0000">&nbsp;&nbsp;</font>
<font color="#400000"><strong>To Fixed Dial List</strong></font></small>
<font color="#FF0000"><br>
</font><small>&nbsp;&nbsp; Cho vaøo danh saùch Fixed Dial </small>
(<small>nhöõng vò trí töø 1 ñeán 9)</small><br>
<small>Duøng caùc phím cuoän ñeå di chuyeån giöõa nhöõng muïc naøy. Nhaán
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)"> ñeå choïn. Baám
phím
<img src="cancel.jpg" width="17" height="19" alt="cancel.bmp (1526 bytes)"> ñeå
thoaùt ra.</small></font></p>
<hr>
<p><font face="VNI-Times"><font color="#FF0000">
<a name="call related">Caùc ñaëc ñieåm veà cuoäc ñieän thoaïi<big><br>
</big></a></font><small>(Call Related Features)</small></font></p>
<p><font face="VNI-Times">Duøng ñeå thay ñoåi, thieát laäp caáu hình cuûa nhöõng tính
naêng lieân quan ñeán cuoäc goïi.</font></p>
<hr>
<p><font face="VNI-Times"><font color="#FF0000">
<a name="show battery">Hieän ñoàng hoà pin<br>
</a></font><small>(Show Bttery Meter)</small><br>
<small>Hieån thò ñoàng hoà cho bieát möùc naêng löôïng coøn laïi cuûa pin</small></font>
</p><p><font face="VNI-Times"><small>1.&nbsp;Duøng caùc phím <small>

Trang 50
Laäp Trình Web Vôùi Visual Basic

<img src="up.jpg" width="26" height="20" alt="up.bmp (2550 bytes)">,


<img src="down.jpg" width="28" height="20" alt="down.bmp (2262 bytes)">
</small>(phím cuoän) ñeå di chuyeån ñeán muïc &quot;
<strong>Call Related Features</strong>&quot;, nhaán <small>
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)"></small> 2 laàn
ñeå vaøo muïc &quot;<strong>Show Battery Meter</strong>&quot;, nhaán <small>
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)"></small>
</small> <small>ñeå hieån thò ñoàng hoà.</small><br>
<small>2.&nbsp;Ñeå thoaùt ra duøng phím <small>
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)">
</small></small></font></p>
<hr>
<p><font face="VNI-Times" color="#FF0000">
<a name="restrict ID">Haïn cheá soá ñieän thoaïi cuûa toâi<br>
</a></font><font face="VNI-Times" color="#400040">
<small>(Restrict My Phone Number)</small><br>
</font><font face="VNI-Times"><small>1.&nbsp;Duøng caùc phím <small>
<img src="up.jpg" width="26" height="20" alt="up.bmp (2550 bytes)">,
<img src="down.jpg" width="28" height="20" alt="down.bmp (2262 bytes)">
</small>(phím cuoän) ñeå di chuyeån ñeán muïc &quot;
<strong>Call Related Features</strong>&quot;, nhaán <small>
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)"></small>
</small><br>
<small>2.&nbsp; Tieáp tuïc duøng caùc phím cuoän ñeå cuoän ñeán muïc &quot;</font>
<font face="VNI-Times" color="#400040">Restrict My Phone Number</font>
<font face="VNI-Times">&quot;,nhaán <small>
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)">
</small>ñeå vaøo menu con</small><br>
<small>&nbsp;&nbsp;<strong>Show ID on Next Call</strong></small><br>
<small>&nbsp;&nbsp;Soá ñieän thoaïi cuûa baïn ñöôïc göûi ñi vôùi cuoäc goïi keá</small>
<br>
<small>&nbsp;&nbsp;
<strong>Restric ID on Next Call&nbsp; </strong></small><br>
</font>&nbsp;&nbsp; <font face="VNI-Times">
<small>Soá ñieän thoaïi cuûa baïn seõ khoâng göûi ñi vôùi cuoäc goïi keá</small></font> <br>
<font face="VNI-Times"><small>Duøng caùc phím cuoän ñeå di chuyeån giöõa caùc
muïc naøy, nhaán <small>
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)">
</small> ñeå choïn. </small></font></p>
<hr>
<p><font face="VNI-Times"><font color="#FF0000">

Trang 51
<a name="call divert">Chuyeån cuoäc goïi</a><big><big><br>
</big></big></font><small>(Call<small>
</small>Diverting)</small><br>
<small>Ñaây laø moät tính naêng maïng , neáu ñieän thoaïi cuûa baïn khoâng coù gía trò hay baïn
khoâng muoán nhaän cuoäc goïi, nhöõng cuoäc goïi ñeán seõ ñöôïc chuyeån ñeán nhöõng soá ñieän
thoaïi khaùc</small><br>
<small>1.&nbsp; Duøng caùc phím <small>
<img src="up.jpg" width="26" height="20"
alt="up.bmp (2550 bytes)">,
<img src="down.jpg" width="28" height="20" alt="down.bmp (2262 bytes)">&nbsp;
</small>(phím cuoän) ñeå di chuyeån ñeán muïc
&quot;<strong>Call Related Features</strong>
&quot;, nhaán<small>
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)">
</small></font><br>2.&nbsp;&nbsp;&nbsp;
<font face="VNI-Times">Tieáp tuïc duøng phím cuoän ñeå ñeán muïc &quot;
<strong>Call Diverting</strong>&quot;, nhaán <small>
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)"></small>
</small> <small>ñeå vaøo menu con.</small><br>
&nbsp;&nbsp;<small>&nbsp;
<a href="#divert voice">Divert Voice Calls</a> (chuyeån cuoäc goïi)<br>
&nbsp;&nbsp;&nbsp;
<a href="#divert fax">Divert Fax Calls</a> (chuyeån cuoäc nhaän baèng fax)<br>
&nbsp;&nbsp;&nbsp;
<a href="#divert data">Divert Data Calls</a> (chuyeån cuoäc nhaän baèng döõ lieäu)<br>
&nbsp;&nbsp;&nbsp;
<a href="#cancel divert">Cancel All Diverting</a> (huûy toaøn boä chöùc naêng chuyeån)
</small><br>
<small>Duøng caùc phím cuoän ñeå di chuyeån giöõa caùc muïc naøy, nhaán <small>
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)">
</small> ñeå choïn. </small></font></p>
<hr>
<p><font face="VNI-Times"><a name="divert voice">
<font color="#FF0000">Chuyeån cuoäc goïi</font><br>
</a><small>(Divert Voice Calls)</small></font></p>
<p><small><font face="VNI-Times">1.&nbsp; Duøng caùc phím <small>
<img src="up.jpg" width="26" height="20" alt="up.bmp (2550 bytes)">,
<img src="down.jpg" width="28" height="20" alt="down.bmp (2262 bytes)">
&nbsp; </small>ñeå di chuyeån ñeán muïc
&quot;<strong>Call Related Features</strong>&quot;, nhaán<small>
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)">

Trang 52
Laäp Trình Web Vôùi Visual Basic

</small></font><br>2.&nbsp;&nbsp;&nbsp;
<font face="VNI-Times">Tieáp tuïc duøng phím cuoän ñeå vaøo muïc &quot;
<strong>Call Diverting</strong>&quot;, nhaán <small>
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)"></small>
</small> <small>2 laàn ñeå vaøo muïc &quot;
<strong>Divert Voice Calls</strong>&quot;.</small><br>
<small>3.&nbsp;Nhaán phím <small>
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)">
</small>ñeå vaøo menu&nbsp; con</small><br>
<small>&nbsp;&nbsp;
<strong> Divert When Unavailable</strong> (Chuyeån khi khoâng ñaùp)</small>
<br>
<small>&nbsp;&nbsp;
<strong>Divert All Voice Calls</strong> (chuyeån taát caû)</small><br>
<small>&nbsp;&nbsp;
<strong>Detail Diverting</strong> (chuyeån theo loaïi)</small><br>
<small>Duøng caùc phím cuoän ñeå di chuyeån giöõa nhöõng muïc naøy. Nhaán
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)"> ñeå choïn. Baám
phím <img src="cancel.jpg" width="17" height="19" alt="cancel.bmp (1526 bytes)">
ñeå thoaùt ra.</small></font></p>
<hr>
<p><font face="VNI-Times"><font color="#FF0000">
<a name="divert fax">Chuyeån cuoäc nhaän baèng Fax<big><br>
</big></a></font><small>(Diver Fax Calls)</small></font></p>
<p><font face="VNI-Times">
<small>Duøng ñeå chuyeån taát caû nhöõng cuoäc nhaän baèng Fax ñeán moät soá ñieän thoaïi
ñôn.</small><br>
<small>Muïc naøy coù 2 tuøy choïn On vaø Off. Neáu baïn thay ñoåi ôû möùc On, baïn phaûi nhaäp
vaøo soá ñieän thoaïi nôi chuyeån ñeán</small>.<br>
<small>1.&nbsp; Duøng caùc phím <small>
<img src="up.jpg" width="26" height="20" alt="up.bmp (2550 bytes)">,
<img src="down.jpg" width="28" height="20" alt="down.bmp (2262 bytes)">&nbsp;
</small>(phím cuoän) ñeå di chuyeån ñeán muïc
&quot;Call Related Features&quot;, nhaán<small>
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)">
</small></font><br>2.&nbsp;&nbsp;&nbsp;
<font face="VNI-Times">Nhaán caùc phím</small>
<small>cuoän ñeå vaøo muïc &quot;Call Diverting&quot;, nhaán <small>
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)"></small>
</small>.<br>
<small>3</small>.&nbsp;<small>Tieáp tuïc</small> <small>duøng caùc phím <small>

Trang 53
<img src="up.jpg" width="26" height="20" alt="up.bmp (2550 bytes)">,
<img src="down.jpg" width="28" height="20" alt="down.bmp (2262 bytes)">
</small>&nbsp; ñeå vaøo muïc
&quot;Divert Fax&nbsp; Calls&quot;.
<small> </small>Nhaán <small>
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)">
</small>ñeå&nbsp; choïn.</small></font></p>
<hr>
<p><font face="VNI-Times"><font color="#FF0000">
<a name="divert data">Chuyeån cuoäc nhaän baèng döõ lieäu<big><br>
</big></a></font><small>(Diver Data Calls)</small></font></p>
<p><font face="VNI-Times">
<small>Duøng ñeå chuyeån taát caû nhöõng cuoäc nhaän baèng Fax ñeán moät soá ñieän thoaïi ñôn.
</small><br>
<small>Muïc naøy coù 2 tuøy choïn On vaø Off. Neáu baïn thay ñoåi ôû möùc On, baïn phaûi nhaäp
vaøo soá ñieän thoaïi nôi chuyeån ñeán</small>.<br>
<small>1.&nbsp; Duøng caùc phím <small>
<img src="up.jpg" width="26" height="20" alt="up.bmp (2550 bytes)">,
<img src="down.jpg" width="28" height="20" alt="down.bmp (2262 bytes)">
&nbsp;&nbsp; </small>(phím cuoän) ñeå di chuyeån ñeán muïc &quot;
<strong>Call Related Features</strong>&quot;, nhaán<small>
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)"></small>
</font><br> 2.&nbsp;&nbsp;&nbsp;
<font face="VNI-Times">Nhaán caùc phím<small>
</small>cuoän ñeå vaøo muïc &quot;
<strong>Call Diverting</strong>&quot;, nhaán <small>
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)"></small>.
</small><br>
<small>3</small>.&nbsp;<small>Tieáp tuïc</small>
<small>duøng caùc phím cuoän ñeå vaøo muïc &quot;
<strong>Divert Data Calls</strong>&quot;.<small> </small>Nhaán <small>
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)">
</small>ñeå&nbsp; choïn.</small></font></p>
<hr>
<p><font face="VNI-Times"><font color="#FF0000">
<a name="cancel divert">Huyû boû toaøn boä chöùc naêng chuyeån<br>
</a></font><small>(Cancel All Diverting)</small></font></p>
<p><font face="VNI-Times"><small>Chöùc naêng naøy cho pheùp baïn huûy chöùc
naêng chuyeån nhöõng cuoäc goïi ñeán.</small> <br>
<small>1.&nbsp; Duøng caùc phím <small>
<img src="up.jpg" width="26" height="20" alt="up.bmp (2550 bytes)">,

Trang 54
Laäp Trình Web Vôùi Visual Basic

<img src="down.jpg" width="28" height="20" alt="down.bmp (2262 bytes)">


&nbsp; </small>(phím cuoän)<small>&nbsp;
</small>ñeå di chuyeån ñeán muïc &quot;
<strong>Call Related Features</strong>&quot;, nhaán<small>
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)">
</small></font><br>2.&nbsp;&nbsp;&nbsp;
<font face="VNI-Times">Nhaán caùc phím cuoän ñeå ñeán muïc&quot;
<strong>Call Diverting</strong>&quot;, nhaán <small>
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)">
</small>.</small><br><small>3</small>.
&nbsp;<small>Tieáp tuïc duøng caùc phím cuoän ñeå vaøo muïc &quot;
<strong>Cancel All Diverting</strong>&quot;.<small> </small>Nhaán&nbsp;
<small><img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)">
</small>ñeå choïn.</small></font></p>
<hr>
<p><font face="VNI-Times" color="#FF0000">
<a name="talk fax">Noùi vaø Fax<br>
</a></font><font face="VNI-Times" color="#000000">
<small>(Talk and Fax)</small><br>
<small>Ñaây laø moät tính naêng maïng cho pheùp baïn ñaøm thoaïi vaø sau ñoù göûi hoaëc nhaän
fax trong suoát cuoäc goïi ñoù. Muïc naøy coù 2 cheá ñoä On vaø Off.</small><br>
</font><small><font face="VNI-Times">1.&nbsp; Duøng caùc phím <small>
<img src="up.jpg" width="26" height="20" alt="up.bmp (2550 bytes)">,
<img src="down.jpg" width="28" height="20" alt="down.bmp (2262 bytes)">
&nbsp; </small>(phím cuoän)<small>&nbsp;
</small>ñeå di chuyeån ñeán muïc &quot;
<strong>Call Related Features</strong>&quot;, nhaán<small>
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)">
</small></font><br>2.&nbsp;&nbsp;&nbsp;
<font face="VNI-Times">Tieáp tuïc duøng caùc phím cuoän ñeå ñeán muïc
&quot;<strong>Talk and Fax</strong>&quot;, nhaán <small>
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)">
</small> ñeå choïn.</font></small></p>

<hr>

<p><font face="VNI-Times" color="#FF0000">


<a name="call waiting">Call Waiting<br>
</a></font><font face="VNI-Times" color="#000000">
<small>(Cuoäc goïi ñang chôø)</small><br>

Trang 55
<small>Tính naêng naøy coù 2 cheá ñoä On vaø Off. Neáu ñöôïc thieát laäp ôû möùc On, maùy seõ
baùo hieäu khi coù moät cuoäc goïi ñang chôø.</small><br>
</font><small>
<font face="VNI-Times">1.&nbsp; Duøng caùc phím <small>
<img src="up.jpg" width="26" height="20" alt="up.bmp (2550 bytes)">,
<img src="down.jpg" width="28" height="20" alt="down.bmp (2262 bytes)">&nbsp;
</small>(phím cuoän)<small>&nbsp;
</small>ñeå di chuyeån ñeán muïc &quot;
<strong>Call Related Features</strong>&quot;, nhaán<small>
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)">
</small></font><br>
2.&nbsp;&nbsp;&nbsp;
<font face="VNI-Times">Tieáp tuïc duøng caùc phím cuoän ñeå ñeán muïc &quot;
<strong>Call Waiting</strong>&quot;, nhaán <small>
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)">
</small> ñeå choïn.</font></small></p>

<hr>

<p><font face="VNI-Times">
<a name="call bar"><font color="#FF0000">Chaën cuoäc goïi<big><br>
</big></font></a><small>(Call Barring)</small></font></p>
<p><font face="VNI-Times">
<small>Laø moät tính naêng maïng, coù theå duøng ñeå chaën nhöõng cuoäc goïi ñi hay nhöõng
cuoäc goïi ñeán.</small><br>
<small>Moãi khi baïn thay ñoåi
&nbsp; vieäc ngaên chaën, baïn phaûi nhaäp vaøo maõ chaën cuoäc goïi (maëc ñònh laø 6789).
</small><br>
<small>1.&nbsp;Duøng caùc phím <small>
<img src="up.jpg" width="26" height="20" alt="up.bmp (2550 bytes)">,
<img src="down.jpg" width="28" height="20" alt="down.bmp (2262 bytes)">&nbsp;
</small>(phím cuoän)<small>&nbsp;
</small>ñeå di chuyeån ñeán muïc &quot;
<strong>Call Related Features</strong>&quot;, nhaán<small>
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)">
</small></font><br> 2.&nbsp;&nbsp;
&nbsp;<font face="VNI-Times">Tieáp tuïc duøng
&nbsp; phím cuoän ñeå vaøo muïc &quot;
<strong>Call Barring</strong>&quot;, nhaán <small>
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)">
</small>.</small><br>

Trang 56
Laäp Trình Web Vôùi Visual Basic

<small>3.&nbsp; Nhaäp vaøo maõ chaën cuoäc goïi</small>.


<small><small> </small>Nhaán phím <small>
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)">
</small>ñeå vaøo menu con.</small><br>
<small>&nbsp;&nbsp;&nbsp;
<a href="#bar outgoing">Bar&nbsp;Outgoing Calls</a></small>
<small>(chaën nhöõng cuoäc goïi ñi)</small><br>
<small>&nbsp;&nbsp;&nbsp;<a href="#bar incoming">
Bar&nbsp; Incoming Calls</a> (chaën nhöõng cuoäc goïi ñeán)</small>
<br>
<small>&nbsp;&nbsp;&nbsp;
<a href="#cancel bar">Cancel All Barring
</a> (huûy chöùc naêng chaën cuoäc goïi)</small><br>
<small>&nbsp;&nbsp;&nbsp;
<a href="#change bar password">Change Bar Password
</a> (Thay ñoåi maõ chaën cuoäc goïi)</small><br>
<small>Duøng caùc phím cuoän<small>&nbsp; </small>ñeå di chuyeån giöõa caùc
&nbsp; muïc naøy, nhaán<small>
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)">
</small> ñeå choïn.</small></font></p>

<hr>

<p><font face="VNI-Times"><a name="bar outgoing">


<font color="#FF0000">Chaën nhöõng cuoäc goïi ñi</font><br>
</a><small>(Bar Outgoing Calls)</small></font></p>
<p><font face="VNI-Times">
<small>Tuøy theo muïc maø baïn choïn, maùy seõ töï ñoäng chaën nhöõng cuoäc goïi ñi khoâng
hôïp leä.</small><br>
<small>1.&nbsp; Duøng caùc phím <small>
<img src="up.jpg" width="26" height="20" alt="up.bmp (2550 bytes)">,
<img src="down.jpg" width="28" height="20" alt="down.bmp (2262 bytes)">&nbsp;
</small>(phím cuoän) ñeå di chuyeån ñeán muïc&quot;
<strong>Call Related Features</strong>&quot;, nhaán<small>
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)">
</small></font><br>2.&nbsp;&nbsp;&nbsp;
<font face="VNI-Times">Tieáp tuïc duøng phím cuoän ñeå vaøo muïc &quot;
<strong>Call Barring</strong>&quot;, nhaán <small>
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)"></small>.
</small><br>
<small>3.&nbsp;&nbsp;Nhaäp vaøo maõ chaën cuoäc goïi</small><br>

Trang 57
<small><small>4.&nbsp;&nbsp;</small> Nhaán phím <small>
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)">
</small>2 laàn ñeå vaøo menu con cuûa muïc &quot;
<strong>Bar&nbsp; Outgoing Calls</strong>&quot;. </small><br>
<small>&nbsp;&nbsp;&nbsp;<font color="#400000">
<strong>Int'l Calls</strong></font></small><br>
<small>&nbsp;&nbsp;&nbsp; Chaën nhöõng cuoäc goïi ñi quoác teá</small><br>
<strong><small><font color="#FF0000">&nbsp;&nbsp;&nbsp; </font>
<font color="#400000">Int'l Calls Expect Home</font></small>
<font color="#FF0000"><br>
</font></strong><small>&nbsp;
&nbsp;&nbsp; Chaën nhöõng cuoäc goïi quoác teá ngoaïi tröø ñaát nöôùc cuûa baïn.</small><br>
<strong><small><font color="#FF0000">&nbsp;&nbsp;&nbsp; </font>
<font color="#400000">All Calls</font></small>
<font color="#FF0000"><br>
</font></strong>
<small>&nbsp;&nbsp;&nbsp; Chaën taát caû nhöõng cuoäc goïi.</small><br>
<small>&nbsp;&nbsp;&nbsp;&nbsp;
<font color="#400000"><strong>Off</strong></font></small><br>
<small>&nbsp;&nbsp;
&nbsp; Khi ñöôïc choïn, maùy seõ trôû veà cheá ñoä bình thöôøng (khoâng chaën cuoäc goïi)
</small><br>
<br>
<small>Duøng caùc phím cuoän<small>
</small>ñeå di chuyeån giöaõ caùc&nbsp;muïc trong menu con, nhaán<small>
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)"> ñeå
choïn.</small>
</small></font></p>

<hr>

<p><font face="VNI-Times"><font color="#FF0000">


<a name="bar incoming">Chaën nhöõng cuoäc goïi ñeán<big><br>
</big></a></font><small>(Bar Incoming Calls)</small></font></p>
<p><small><font face="VNI-Times">1.&nbsp; Duøng caùc phím <small>
<img src="up.jpg" width="26" height="20" alt="up.bmp (2550 bytes)">,
<img src="down.jpg" width="28" height="20" alt="down.bmp (2262 bytes)">&nbsp;
</small>(phím cuoän) ñeå di chuyeån ñeán muïc &quot;
<strong>Call Related Features</strong>&quot;, nhaán<small>
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)">
</small></font><br>

Trang 58
Laäp Trình Web Vôùi Visual Basic

2.&nbsp;&nbsp;&nbsp;
<font face="VNI-Times">Tieáp tuïc duøng phím cuoän ñeå vaøo muïc &quot;
<strong>Call Barring</strong>&quot;, nhaán <small>
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)">
</small>.</small><br>
<small>3.&nbsp; Nhaäp vaøo maõ chaën cuoäc goïi</small>, <small>nhaán <small>
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)">
</small></small><br>
<small>4<small>.&nbsp;&nbsp;</small>Duøng caùc phím cuoän ñeå di chuyeån ñeán
&nbsp; muïc &quot;
<strong>Bar Incoming Calls</strong>&quot;, nhaán&nbsp; <small>
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)">
</small> ñeå vaøo menu con</small><br>
<strong><font color="#400000">
<small>&nbsp;&nbsp;&nbsp; When Roaming</small></font>
<font color="#FF0000"><br>
</font></strong><small>&nbsp;
&nbsp;&nbsp; Chaën nhöõng cuoäc goïi ñeán khi baïn ñang roaming</small><br>
<strong><font color="#400000"><small>&nbsp;&nbsp;
&nbsp; All Calls</small></font>
<font color="#FF0000"><br>
</font></strong>
<small>&nbsp;&nbsp;&nbsp; Chaën taát caû nhöõng cuoäc goïi ñeán.</small><br>
<strong><font color="#400000"><small>&nbsp;&nbsp;&nbsp; Off</small></font>
<font color="#FF0000"><br>
</font></strong>
<small>&nbsp;&nbsp;&nbsp; Khi ñöôïc choïn, maùy seõ trôû veà cheá ñoä bình thöôøng
(khoâng chaën cuoäc goïi)</small></font></p>
<p><font face="VNI-Times">
<small>Duøng caùc phím cuoän ñeå di chuyeån giöaõ caùc &nbsp;muïc trong menu con,
nhaán<small>
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)"> ñeå
choïn.</small></small></font></p>

<hr>

<p><font face="VNI-Times"><font color="#FF0000">


<a name="cancel bar">Huûy vieäc chaën<big><br>
</big></a></font><small>(Cancel All Barring)</small><br>
<br>
<small>Duøng ñeå thieát laäp taát caû caùc tuyø choïn chaën cuoäc goïi veà möùc Off</small><br>

Trang 59
<small>1.&nbsp; Duøng caùc phím <small>
<img src="up.jpg" width="26" height="20" alt="up.bmp (2550 bytes)">,
<img src="down.jpg" width="28" height="20" alt="down.bmp (2262 bytes)">&nbsp;
</small>(phím cuoän) ñeå di chuyeån ñeán muïc &quot;
<strong>Call Related Features</strong>&quot;, nhaán<small>
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)">
</small></font><br>
2.&nbsp;&nbsp;&nbsp;
<font face="VNI-Times">Tieáp tuïc duøng&nbsp; phím <small>
<img src="down.jpg" width="28" height="20" alt="down.bmp (2262 bytes)">
</small>, <small>
<img src="up.jpg" width="26" height="20" alt="up.bmp (2550 bytes)">
</small> ñeå ñeán muïc&quot;
<strong>Call Barring</strong>&quot;, nhaán <small>
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)">
</small>.</small><br>
<small>3.&nbsp;&nbsp;Nhaäp vaøo maõ chaën cuoäc goïi</small>,
<small>nhaán <small>
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)">
</small></small><br>
<small>4<small>.&nbsp;&nbsp;
</small>Duøng caùc phím cuoän<small>
</small>ñeå di chuyeån ñeán&nbsp; muïc &quot;
<strong> Cancel All Barring</strong>&quot;, nhaán&nbsp;
<small><img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)">
</small> ñeå hoaøn thaønh taùc vuï.</small></font></p>

<hr>

<p><font face="VNI-Times"><font color="#FF0000">


<a name="change bar password">Thay ñoåi maõ chaën cuoäc goïi<big><br>
</big></a></font><small>(Change Bar Password)</small></font></p>

<p><small><font face="VNI-Times">1.&nbsp; Duøng caùc phím <small>


<img src="up.jpg" width="26" height="20" alt="up.bmp (2550 bytes)">,
<img src="down.jpg" width="28" height="20" alt="down.bmp (2262 bytes)">&nbsp;
</small>(phím cuoän) ñeå di chuyeån ñeán muïc &quot;
<strong>Call Related Features</strong>&quot;, nhaán<small>
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)">
</small></font><br>
2.&nbsp;&nbsp;&nbsp;

Trang 60
Laäp Trình Web Vôùi Visual Basic

<font face="VNI-Times">Tieáp tuïc duøng phím cuoän ñeå ñeán muïc &quot;
<strong>Call Barring</strong>&quot;, nhaán <small>
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)">
</small>.</small><br>
<small>3.&nbsp; Nhaäp vaøo maõ chaën cuoäc goïi</small>, <small>nhaán&nbsp;
<small><img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)">
</small></small><br>
<small>4<small>.&nbsp;
</small>Duøng caùc phím cuoän ñeå di chuyeån ñeán &nbsp;muïc &quot;
<strong> Change Bar Password</strong>&quot;, nhaán&nbsp; <small>
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)"></small>
.</small><br>
<small>5.&nbsp; Nhaäp vaøo maõ hieän taïi (maëc ñònh laø 6789)</small><br>
<small>6.&nbsp; Nhaäp vaøo maõ môùi (4 con soá)&nbsp; nhaán&nbsp; <small>
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)">
</small></small> <small>ñeå hoaøn thaønh taùc vuï.</small></font></p>

<hr>

<p><font face="VNI-Times"><font color="#FF0000">


<a name="key answer">Traû lôøi baèng phím<br>
</a></font><small>(Key Answer Only)</small></font></p>
<p><font face="VNI-Times"><small>Tính naêng naøy coù 2 choïn löïa On vaø Off
</small><br>
<small>Khi noù ñöôïc thieát laäp ôû möùc On, môû naép maùy seõ khoâng
traû lôøi cuoäc goïi ñeán.
</small><br>
<small>Khi noù ñöôïc thieát laäp ôû möùc Off, môû naép maùy seõ traû lôøi cuoäc goïi ñeán.
</small><br>
<small>1.&nbsp; Duøng caùc phím <small>
<img src="up.jpg" width="26" height="20" alt="up.bmp (2550 bytes)">,
<img src="down.jpg" width="28" height="20" alt="down.bmp (2262 bytes)">
&nbsp;&nbsp; </small>(phím cuoän) ñeå di chuyeån ñeán muïc &quot;
<strong>Call Related Features</strong>&quot;, nhaán<small>
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)">
</small></font><br>
2.&nbsp;&nbsp;&nbsp;
<font face="VNI-Times">Tieáp tuïc duøng phím cuoän ñeå ñeán muïc &quot;
<strong>Key Answer Only</strong>&quot;, nhaán <small>
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)">
</small> ñeå&nbsp; choïn</small>.</font></p>

Trang 61
<hr>

<p><font face="VNI-Times"><a name="setup">


<font color="#FF0000">Caøi ñaët ñieän thoaïi<br>
</font></a><small>(Phone Setup)<br>
&nbsp;&nbsp;
&nbsp; Muïc naøy duøng ñeå thieát laäp, thay ñoåi&nbsp; caùc caáu hình cho ñieän thoaïi ñang
söû duïng</small></font></p>
<p><font face="VNI-Times"><font color="#FF0000">
<a name="line">Choïn ñöôøng daây<br>
</a></font><small>(Select Phone Line)<br>
&nbsp;&nbsp;&nbsp; Cho pheùp chuyeån ñoåi giöõa Line 1 vaø Line 2<br>
1.&nbsp; Duøng caùc phím <small>
<img src="up.jpg" width="26" height="20" alt="up.bmp (2550 bytes)">,
<img src="down.jpg" width="28" height="20" alt="down.bmp (2262 bytes)">&nbsp;
</small>(phím cuoän) ñeå di chuyeån ñeán muïc &quot;
<strong>Phone Setup</strong>&quot;, nhaán<small>
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)">
</small></font><br>
2.&nbsp;&nbsp;&nbsp;
<font face="VNI-Times">Nhaán phím <small>
<img src="down.jpg" width="28" height="20" alt="down.bmp (2262
bytes)"></small>,
<small><img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)">
</small> ñeå vaøo muïc &quot;<strong>Select Phone Line</strong>&quot;
<br>
3.&nbsp; Duøng caùc phím cuoän ñeå di chuyeån giöõa
<strong>Line 1</strong> vaø<strong> Line 2</strong>. Muoán choïn nhaán <small>
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)">,
</small>ñeå thoaùt ra duøng phím <small>
<img src="cancel.jpg" width="17" height="19" alt="cancel.bmp (1526 bytes)">
</small></font></small></p>

<hr>

<p><font face="VNI-Times">
<span style="font-family: VNI-Times"><font color="#FF0000">
<a name="volume">Ñieàu chænh aâm löôïng chuoâng<br>
</a></font><small>(Adjust Ring Volume)<br>&nbsp;&nbsp;
&nbsp; Thieát laäp aâm löôïng cuûa tieáng chuoâng khi coù moät cuoäc goïi ñeán<br>

Trang 62
Laäp Trình Web Vôùi Visual Basic

</span>1.&nbsp; Duøng caùc phím <small>


<img src="up.jpg" width="26" height="20" alt="up.bmp (2550 bytes)">,
<img src="down.jpg" width="28" height="20" alt="down.bmp (2262 bytes)">
&nbsp;</small>(phím cuoän)<small>&nbsp;
</small>ñeå di chuyeån ñeán muïc &quot;
<strong>Phone Setup</strong>&quot;, nhaán<small>
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)">
</small></font><br>
2.&nbsp;&nbsp;&nbsp;
<font face="VNI-Times">Nhaán phím <small>
<img src="down.jpg" width="28" height="20" alt="down.bmp (2262 bytes)">
</small> 2 laàn, <small>
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)">
</small> ñeå vaøo muïc <span style="font-family: VNI-Times">&quot;
<strong>Adjust Ring Volume</strong></span>&quot;<br>
3.&nbsp; Duøng phím <small>
<img src="right.jpg" width="22" height="17" alt="right.bmp (1818 bytes)">
</small>, <small>
<img src="left.jpg" width="25" height="16" alt="left.bmp (1974 bytes)">
</small> ñeå ñieàu chænh aâm löôïng. Nhaán <small>
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)">
</small> ñeå löu caáu hình vaø thoaùt ra.</font></small></p>

<hr>

<p><font face="VNI-Times"><font color="#FF0000">


<a name="ring">Chuoâng hoaëc rung<br>
</a></font><small>(Ring or Vibrate)
<br>Thieát laäp caùch thöùc maø maùy seõ baùo hieäu khi coù moät cuoäc goïi ñeán<br>
1.&nbsp; Duøng caùc phím <small>
<img src="up.jpg" width="26" height="20"
alt="up.bmp (2550 bytes)">,
<img src="down.jpg" width="28" height="20" alt="down.bmp (2262 bytes)">&nbsp;
</small>(phím cuoän)<small>&nbsp;
</small>ñeå di chuyeån ñeán muïc &quot;
<strong>Phone Setup</strong>&quot;, nhaán<small>
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)">
</small></font><br>
2.&nbsp;&nbsp;&nbsp; <font face="VNI-Times">Nhaán phím <small>
<img src="down.jpg" width="28" height="20" alt="down.bmp (2262 bytes)"></small>
3 laàn, <small>

Trang 63
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)">
</small> ñeå vaøo muïc &quot;
<strong>Ring or Vibrate</strong>&quot;<br>
3.&nbsp; Duøng caùc phím&nbsp;cuoän ñeå chuyeån ñoåi giöõa caùc muïc quot;
<strong>Ring Only</strong>&quot; (chæ chuoâng), &quot;
<strong>Vibrate Only</strong>&quot; (chæ rung), &quot;
<strong>Vibrate then Ring</strong>&quot; (rung tröôùc chuoâng sau), hay &quot;
<strong>No Ring or Vibrate</strong>&quot; (khoâng chuoâng, khoâng rung). Muoán
choïn nhaán <small>
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)">,
</small>ñeå thoaùt ra duøng phím <small>
<img src="cancel.jpg" width="17" height="19" alt="cancel.bmp (1526 bytes)">.
</small></font></small></p>

<hr>
<p><font face="VNI-Times"><font color="#FF0000">
<a name="ringer">Ñaët tieáng chuoâng<br>
</a></font><small>(Set Ringer Tone)
<br>Xaùc ñònh loaïi tieáng chuoâng moãi khi coù moät cuoäc goïi ñeán<br>
1.&nbsp; Duøng caùc phím <small>
<img src="up.jpg" width="26" height="20" alt="up.bmp (2550 bytes)">,
<img src="down.jpg" width="28" height="20" alt="down.bmp (2262 bytes)">&nbsp;
</small>(phím cuoän) ñeå di chuyeån ñeán muïc &quot;
<font color="#400000">
<strong>Phone Setup</strong></font>&quot;, nhaán<small>
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)">
</small></font><br>
2.&nbsp;&nbsp;&nbsp;
<font face="VNI-Times">Nhaán caùc phím cuoän ñeå ñeán muïc
&quot;<strong><font color="#400000">Set Ringer Tone</font>
</strong>&quot; , <small>
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)"></small>
<br>
3.&nbsp; Tieáp tuïc duøng caùc phím<small> </small>cuoän ñeå chuyeån ñoåi giöõa caùc muïc
&quot;<font color="#400000">
<strong>Standard Tone</strong></font>&quot
(tieáng chuaån), &quot;<strong>
<font color="#400000">Music Tone</font>
</strong>&quot;(tieáng nhaïc). Muoán choïn nhaán <small>
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)">,
</small>ñeå thoaùt ra duøng phím <small>

Trang 64
Laäp Trình Web Vôùi Visual Basic

<img src="cancel.jpg" width="17" height="19" alt="cancel.bmp (1526 bytes)">


</small></font></small></p>

<hr>

<p><font face="VNI-Times"><font color="#FF0000">


<a name="tone2">Ñaët tieáng chuoâng 2<br>
</a></font><small>(Set Ringer Tone 2)<br> Xaùc ñònh loaïi tieáng chuoâng moãi khi coù
moät cuoäc goïi ñeán. Muïc naøy chæ xuaát hieän khi ta choïn ñöôøng daây laø Line 2 trong muïc
&quot;
<strong>Select Phone Line</strong>&quot;
<br>1.&nbsp; Duøng caùc phím <small>
<img src="up.jpg" width="26" height="20" alt="up.bmp (2550 bytes)">,
<img src="down.jpg" width="28" height="20"alt="down.bmp (2262 bytes)">&nbsp;
</small>(phím cuoän)<small>&nbsp;
</small>ñeå di chuyeån ñeán muïc <font color="#400000">
<strong>Phone Setup</strong></font>, nhaán<small>
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)">
</small></font><br>
2.&nbsp;&nbsp;&nbsp;
<font face="VNI-Times">Nhaán caùc phím cuoän ñeå ñeán muïc
&quot;<font color="#400000">
<strong>Set Ringer Tone 2</strong></font>&quot; ,&nbsp; nhaán<small>
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)">
</small> <br>
3.&nbsp; Tieáp tuïc duøng caùc phím cuoän<small>
</small>ñeå chuyeån ñoåi giöõa caùc muïc &quot;
<strong><font color="#400000">Standard Tone</font>
</strong>&quot;(tieáng chuaån), &quot;<font color="#400000">
<strong>Music Tone</strong></font>&quot;(tieáng nhaïc). Muoán choïn nhaán
<small><img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)">,
</small>ñeå thoaùt ra duøng phím <small>
<img src="cancel.jpg" width="17" height="19" alt="cancel.bmp (1526 bytes)">
</small></font></small></p>

<hr>

<p><font face="VNI-Times"><span style="font-family: VNI-Times">


<font color="#FF0000"><a name="lock">Khoùa ñieän thoaïi<br>
</a></font>
<small>(Phone Lock)<br>

Trang 65
Duøng ñeå thieát laäp, thay ñoåi maõ môû khoùa moãi khi ñieän thoaïi bò khoùa. Maõ maëc ñònh cuûa
noù laø &quot;1234&quot; vaø coù theå thay ñoåi ñöôïc.
<br>
</span>1.&nbsp; Duøng caùc phím <small>
<img src="up.jpg" width="26" height="20" alt="up.bmp (2550 bytes)">,
<img src="down.jpg" width="28" height="20" alt="down.bmp (2262 bytes)">&nbsp;
</small>(phím cuoän)<small>&nbsp;
</small>ñeå di chuyeån ñeán muïc <font color="#400000">
<strong>Phone Setup</strong></font>, nhaán<small>
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)">
</small></font><br>
2.&nbsp;&nbsp;&nbsp;
<font face="VNI-Times">Nhaán caùc phím cuoän ñeå ñeán muïc&quot;
<font color="#400000"><strong>Phone Lock</strong>
</font>&quot;, nhaán <small>
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)">
</small> <br>
3.&nbsp; Tieáp tuïc duøng caùc phím cuoän<small>
</small>ñeå chuyeån ñoåi giöõa caùc muïc &quot;<font color="#400000">
<strong>Automatic Lock</strong></font>&quot; (töï ñoäng khoùa maùy moãi khi môû
maùy), &quot;<font color="#400000">
<strong>Lock Now</strong></font>&quot; (khoùa maùy ngay laäp töùc), hoaëc
&quot;<font color="#400000">
<strong>Change Unlock Code</strong></font>&quot; (thay ñoåi maõ môû
khoùa). Muoán choïn nhaán <small>
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)">, </small>ñeå
thoaùt ra duøng phím <small>
<img src="cancel.jpg" width="17" height="19" alt="cancel.bmp (1526 bytes)">.
</small></font></small></p>
<hr>

<p><font face="VNI-Times"><font color="#FF0000">


<a name="code">Maõ soá baûo maät môùi<br>
</a></font><small>(New Security Code)
<br>Thay ñoåi maõ baûo maät cuûa maùy. Maõ naøy duøng ñeå ñieàu khieån vieäc truy xuaát, vaø
nhöõng muïc khaùc beân trong menu<br>
1.&nbsp; Duøng caùc phím <small>
<img src="up.jpg" width="26" height="20" alt="up.bmp (2550 bytes)">,
<img src="down.jpg" width="28" height="20" alt="down.bmp (2262 bytes)">
</small> (phím cuoän)<small> </small>ñeå di chuyeån ñeán muïc <font color="#400000">
<strong>Phone Setup</strong></font>, nhaán<small>

Trang 66
Laäp Trình Web Vôùi Visual Basic

<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)">


</small></font><br>
2.&nbsp;&nbsp;&nbsp;
<font face="VNI-Times">Tieáp tuïc duøng caùc&nbsp; phím cuoän ñeå ñeán muïc quot;
<font color="#400000">
<strong>New Security Code</strong></font>&quot;, nhaán &nbsp; <small>
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)">
</small>
<br>
3.&nbsp; Maùy seõ yeâu caàu nhaäp vaøo maõ soá cuõ. Neáu nhaäp ñuùng, ta seõ nhaäp tieáp 6 con
soá thay cho maõ soá cuõ. Muoán löu caáu hình nhaán <small>
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)">,
</small>ñeå thoaùt ra duøng phím <small>
<img src="cancel.jpg" width="17" height="19" alt="cancel.bmp (1526 bytes)">.
</small></font></small></p>

<hr>

<p><font face="VNI-Times"><font color="#FF0000">


<a name="extended">Nhöõng menu môû roäng<br>
</a></font><small>(Extended Menus)<br> Chuyeån ñoåi nhöõng menu môû roäng ôû möùc
On hay Off. Neáu noù ñöôïc thieát laäp ôû möùc Off, nhöõng tính naêng môû roäng seõ khoâng
ñöôïc hieån thò<br>
1.&nbsp; Duøng caùc phím <small>
<img src="up.jpg" width="26" height="20" alt="up.bmp (2550 bytes)">,
<img src="down.jpg" width="28" height="20" alt="down.bmp (2262 bytes)">
</small> (phím cuoän)<small> </small>ñeå di chuyeån ñeán muïc
<strong>Phone Setup</strong>, nhaán<small>
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)">
</small></font><br>
2.&nbsp;&nbsp;&nbsp;
<font face="VNI-Times">Nhaán caùc phím cuoän ñeå vaøo muïc &quot;
<strong>Extended Menus</strong>&quot;, nhaán&nbsp; <small>
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)"></small>
<br>
3.&nbsp;Tieáp tuïc duøng caùc phím cuoän ñeå chuyeån ñoåi giöõa caùc muïc
<strong>On</strong> hay <strong>Off</strong>. Muoán löu caáu hình nhaán <small>
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)">,
</small>ñeå thoaùt ra duøng phím
<img src="cancel.jpg" width="17" height="19" alt="cancel.bmp (1526 bytes)">
</small> </font></p>

Trang 67
<hr>

<p><font face="VNI-Times"><font color="#FF0000">


<a name="show">Hieån thò ngaøy vaø giôø<br>
</a></font>
<small>(Show Time and Date)<br> Moãi khi ñöôïc choïn, maøn hình seõ hieån thò ngaøy vaø
giôø cho ñeán khi moät phím baát kyø ñöôïc nhaán. Chöùc naêng naøy chæ ñöôïc hieån thò khi
menu &quot;
<strong>Extended Menus</strong>&quot; ôû traïng thaùi
<strong>On</strong>.<br>
1.&nbsp; Duøng caùc phím <small>
<img src="up.jpg" width="26" height="20" alt="up.bmp (2550 bytes)">,
<img src="down.jpg" width="28" height="20" alt="down.bmp (2262 bytes)">&nbsp;
</small>(phím cuoän) ñeå di chuyeån ñeán muïc <strong>Phone
Setup</strong>, nhaán<small>
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)">
</small></font><br>
2.&nbsp;&nbsp;&nbsp;
<font face="VNI-Times">Tieáp tuïc duøng caùc phím cuoän ñeå ñeán muïc &quot;
<strong>Show Time and Date</strong>&quot;.<br>
3.&nbsp; Muoán choïn nhaán <small>
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)">,
</small>ñeå thoaùt ra duøng phím <small>
<img src="cancel.jpg" width="17" height="19" alt="cancel.bmp (1526 bytes)">
</small> </font></small></p>

<hr>

<p><font face="VNI-Times"><font color="#FF0000">


<a name="set">Ñaët&nbsp;laïi ngaøy vaø giôø<br>
</a></font><small>(Set Time and Date)
<br>Duøng ñeå ñaët laïi ngaøy vaø giôø. Chöùc naêng naøy chæ ñöôïc hieån thò khi menu
&quot;<strong>Extended Menus</strong>&quot; ôû traïng thaùi On.<br>
1.&nbsp; Duøng caùc phím <small>
<img src="up.jpg" width="26" height="20" alt="up.bmp (2550 bytes)">,
<img src="down.jpg" width="28" height="20" alt="down.bmp (2262 bytes)">&nbsp;
</small>(phím cuoän) ñeå di chuyeån ñeán muïc
<strong>Phone Setup</strong>, nhaán<small>
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)">
</small></font><br>

Trang 68
Laäp Trình Web Vôùi Visual Basic

2.&nbsp;&nbsp;&nbsp;
<font face="VNI-Times">Tieáp tuïc duøng caùc phím cuoän ñeå ñeán muïc &quot;
<strong>Set Time and Date</strong>&quot;, <small>
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)"></small>
<br>
3.&nbsp; Maøn hình seõ hieån thò thoâng baùo &quot;<strong>Enter Time</strong>&quot;.
Thôøi gian nhaäp vaøo phaûi ôû daïng thöùc 24h. Tieáp ñoù laø thoâng baùo nhaéc nhôû nhaäp vaøo
ngaøy &quot;<strong>Enter Date</strong>&quot;.&nbsp; Muoán löu caáu hình nhaán
<small><img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)">,
</small>ñeå thoaùt ra duøng phím <small>
<img src="cancel.jpg" width="17" height="19" alt="cancel.bmp (1526 bytes)">
</small> </font></small></p>

<hr>

<p><font face="VNI-Times"><font color="#FF0000">


<a name="format">Ñaët kieåu giôø 12/24<br>
</a></font><small>(Set Time Format)
<br>Duøng ñeå ñaët laïi daïng thöùc hieån thò giôø. Chöùc naêng naøy chæ ñöôïc hieån thò khi menu
&quot;<strong>Extended Menus</strong>&quot; ôû traïng thaùi
<strong>On</strong>.<br>
1.&nbsp; Duøng caùc phím <small>
<img src="up.jpg" width="26" height="20" alt="up.bmp (2550 bytes)">,
<img src="down.jpg" width="28" height="20" alt="down.bmp (2262 bytes)">&nbsp;
</small>(phím cuoän) ñeå di chuyeån ñeán muïc
<strong>Phone Setup</strong>, nhaán<small>
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)">
</small></font><br>
2.&nbsp;&nbsp;&nbsp; <font face="VNI-Times">Nhaán caùc phím cuoän ñeå ñeán muïc
&quot;<strong>Set Time Format</strong>&quot;,nhaán&nbsp; <small>
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)"></small>
<br>
3.&nbsp; Tieáp tuïc duøng caùc phím<small> </small>cuoän<small> </small>ñeå
chuyeån ñoåi giöõa caùc muïc &quot;
<strong>12-hour?</strong>&quot;(daïng 12h), hay &quot;
<strong>24-hour</strong>&quot;(daïng 24h).&nbsp; Muoán löu caáu hình nhaán
<small><img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)">,
</small>ñeå thoaùt ra duøng phím <small>
<img src="cancel.jpg" width="17" height="19" alt="cancel.bmp (1526 bytes)">
</small> </font></small></p>

Trang 69
<hr>

<p><font face="VNI-Times"><font color="#FF0000">


<a name="battery">Cheá ñoä tieát kieäm pin<br>
</a></font><small>(Battery Saving Mode)
<br>Tính naêng naøy cho pheùp ñieän thoaïi hoaït ñoäng ôû cheá ñoä tieát kieäm pin. Chöùc naêng
naøy chæ ñöôïc hieån thò khi menu &quot;
<strong>Extended Menus</strong>&quot; ôû traïng thaùi <strong>On</strong>.
<br>
1.&nbsp; Duøng caùc phím <small>
<img src="up.jpg" width="26" height="20" alt="up.bmp (2550 bytes)">,
<img src="down.jpg" width="28" height="20" alt="down.bmp (2262 bytes)">&nbsp;
</small>(phím cuoän) ñeå di chuyeån ñeán muïc
<strong>Phone Setup</strong>, nhaán<small>
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)">
</small></font><br>
2.&nbsp;&nbsp;&nbsp;
<font face="VNI-Times">Tieáp tuïc duøng caùc phím cuoän ñeå ñeán muïc &quot;
<strong>Battery Saving Mode</strong>&quot;,nhaán <small>
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)"></small>
<br>
3.&nbsp; Muoán löu caáu hình nhaán <small>
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)">,
</small>ñeå thoaùt ra duøng phím <small>
<img src="cancel.jpg" width="17" height="19" alt="cancel.bmp (1526 bytes)">
</small> </font></small></p>

<hr>

<p><font face="VNI-Times"><font color="#FF0000">


<a name="keypad">Choïn tieáng nuùt baám<br>
</a></font><small>(Select Keypad Tones)
<br> Cho pheùp baïn thay ñoåi hoaëc khoâng cho pheùp coù tieáng moãi khi moät phím
ñöôïc nhaán. Chöùc naêng naøy chæ ñöôïc hieån thò khi menu &quot;
<strong>Extended Menus</strong>&quot; ôû traïng thaùi <strong>On</strong>.
<br>
1.&nbsp; Duøng caùc phím <small>
<img src="up.jpg" width="26" height="20" alt="up.bmp (2550 bytes)">,
<img src="down.jpg" width="28" height="20" alt="down.bmp (2262 bytes)">&nbsp;
</small>(phím cuoän) ñeå di chuyeån ñeán muïc
<strong>Phone Setup</strong>, nhaán<small>

Trang 70
Laäp Trình Web Vôùi Visual Basic

<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)">


</small></font><br>
2.&nbsp;&nbsp;&nbsp;
<font face="VNI-Times">Nhaán caùc phím cuoän ñeå ñeán muïc&quot;
<strong>Select Keypad Tones</strong>&quot;,nhaán <small>
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)"></small>
<br>
3.&nbsp; Tieáp tuïc duøng caùc phím cuoän ñeå chuyeån ñoåi giöõa caùc muïc &quot;
<strong>Normal Tones</strong>&quot; (tieáng bình thöôøng), &quot;
<strong>Single Tone</strong>&quot; (tieáng ñôn), hay &quot;
<strong>No Tones</strong>&quot; (khoâng coù tieáng).&nbsp; Muoán löu caáu hình nhaán
<small><img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)">,
</small>ñeå thoaùt ra duøng phím <small>
<img src="cancel.jpg" width="17" height="19" alt="cancel.bmp (1526 bytes)">
</small> </font></small></p>

<hr>

<p><a name="messages">
<font color="#FF0000">Tin Nh</font>
<font face="VNI-Times" color="#FF0000">aén<br>
</font></a><font face="VNI-Times"><small>(Messages)
<br>Duøng ñeå soaïn thaûo tin nhaén, xem noäi dung tin nhaén, thieát laäp hoaëc thay ñoåi caùc
caáu hình lieân quan ñeán tin nhaén.</small></font></p>

<p><font face="VNI-Times"><font color="#FF0000">


<a name="call voicemail">Goïi hoäp thö thoaïi<br>
</a></font>(Call Voicemail)<br>
<small>Chöùc naêng duøng ñeå laøm moät cuoäc goïi ñeán soá hoäp thö thoaïi hieän haønh.
<br> Soá cuûa hoäp thö thoaïi coù theå thay ñoåi ñöôïc trong muïc &quot;
<strong>Voicemail Number</strong>&quot;.
<br> Ñeå duøng chöùc naêng naøy, baïn laøm nhö sau :
<br>Duøng caùc phím <small>
<img src="up.jpg" width="26" height="20" alt="up.bmp (2550 bytes)">,
<img src="down.jpg" width="28" height="20" alt="down.bmp (2262 bytes)">&nbsp;
</small>ñeå di chuyeån ñeán muïc &quot;
<strong>Messages</strong>&quot;, nhaán<small>
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)">
</small></small> <small>2 laàn vaøo muïc &quot;
<strong>Call Voicemail</strong>&quot;, nhaán<small>
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)">

Trang 71
</small></font>. Khi <font face="VNI-Times">ñoù, maùy seõ töï ñoäng quay soá cuûa hoäp
thö thoaïi. Nhaán <small>
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)">
</small> ñeå keát thuùc cuoäc goïi.</font></small></p>

<hr>

<p><font face="VNI-Times"><a name="outgoing msg">


<font color="#FF0000">Caùc tin göûi ñi</font><br>
</a><small>(Outgoing Messages)</small><br>
<small>Chöùc naêng naøy ñöôïc duøng ñeå xem vaø quaûn lyù baát kyø tin nhaén naøo göûi ñi
<small>.</small> Khi choïn muc naøy, tin nhaén ñaàu tieân seõ ñöôïc hieån thò.</small>
<br>
<small>1.&nbsp; Duøng caùc phím <small>
<img src="up.jpg" width="26" height="20" alt="up.bmp (2550 bytes)">,
<img src="down.jpg" width="28" height="20" alt="down.bmp (2262 bytes)">&nbsp;
</small>(phím cuoän) ñeå di chuyeån ñeán muïc &quot;
<strong> Messages</strong>&quot;, nhaán<small>
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)">
</small></small>.<br>
<small>2.&nbsp; Duøng caùc phím cuoän ñeå cuoän ñeán muïc &quot;
<strong>Outgoing Massages</strong>&quot;<small>, </small>nhaán<small>
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)">
</small></small>.
<small>Maøn hình seõ hieån thò danh saùch caùc tin nhaén göûi ñi</small>.<br>
<small>3<small>.&nbsp; </small>Tieáp tuïc duøng caùc phím cuoän&nbsp; ñeå di chuyeån
giöõa caùc tin nhaén. Ñeå hieån thò 1 tin nhaén chæ ñònh, nhaäp vaøo soá thöù töï cuûa tin nhaén ñoù,
ví duï nhaán phím </font>
<img src="5.jpg" width="24" height="17" alt="5.bmp (1734 bytes)">
<font face="VNI-Times"> &nbsp; ñeå hieån thò tin nhaén thöù 5. Neáu tin nhaén ñoù khoâng
toàn taïi, thoâng baùo &quot;<strong>Invalid Msg Number</strong>&quot; seõ ñöôïc hieån
thò. Nhaán&nbsp; <small>
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)">
</small> ñeå vaøo menu con.</small><br>
<small>&nbsp;&nbsp;
<strong>Send Message</strong> (Göûi tin nhaén)</small><br>
<small>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
<strong><em>Enter Number</em></strong>duøng caùc phím soá ñeå nhaäp soá ñieän thoaïi
</small><br><small>
<strong><em>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Find Entry by Name</em>
</strong>(tìm moät soá ñieän thoaïi ñaõ löu trong boä nhôù theo teân)</small>

Trang 72
Laäp Trình Web Vôùi Visual Basic

<br><small>
<strong><em>&nbsp;&nbsp;&nbsp; &nbsp;&nbsp; Find Entry by Location</em>
</strong>&nbsp;(tìm moät soá ñieän thoaïi ñaõ löu trong boä nhôù theo vò trí)
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </small><br>
<small><strong>&nbsp;&nbsp;Store Message</strong> (Löu tin nhaén)</small>
<br><small><strong>&nbsp;&nbsp;Edit Message
</strong> (hieäu chænh tin nhaén)</small><br><small>
<strong>&nbsp;&nbsp;Delete Message</strong> (Xoùa tin nhaén hieån thò hieän taïi)
<br>
<strong>&nbsp;&nbsp;Go to Next Message</strong> (hieån thò tin nhaén göûi ñi keá
tieáp)&nbsp; </small></font></p>

<p><font face="VNI-Times"><small>Duøng caùc phím <small>


<img src="up.jpg" width="26" height="20" alt="up.bmp (2550 bytes)">,
<img src="down.jpg" width="28" height="20" alt="down.bmp (2262 bytes)">
</small> ñeå di chuyeån giöõa caùc menu con, nhaán<small>
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)">
</small>&nbsp; ñeå choïn.</small></font></p>

<hr>

<p><font face="VNI-Times"><font color="#FF0000">


<a name="msg editor">Soaïn thaûo tin nhaén<br>
</a></font>(<small>Message Editor</small>)<br>
<sub>Duøng ñeå taïo hay hieäu chænh nhöõng tin nhaén.</sub> <br>
<small>1.&nbsp; Duøng caùc phím <small>
<img src="up.jpg" width="26" height="20" alt="up.bmp (2550 bytes)">,
<img src="down.jpg" width="28" height="20" alt="down.bmp (2262 bytes)">
&nbsp;</small> (phím cuoän) ñeå di chuyeån ñeán muïc &quot;
<strong> Messages</strong>&quot;, nhaán<small>
<img src="ok.jpg" width="28"height="17" alt="ok.bmp (1902 bytes)">
</small></small>.<br>
<small>2.&nbsp; Tieáp tuïc duøng caùc phím<small>
</small>cuoän<small> </small>ñeå cuoän ñeán muïc &quot;
<strong>Massage Editor</strong>&quot;<small>, </small>nhaán<small>&nbsp;
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)">
</small></small>.<small><small>
</small>Khi ñoù maøn hình seõ hieån thò</small>
<small>tin nhaén cuoái cuøng. Nhaán vaø giöõ phím <small>
<img src="cancel.jpg" width="17" height="19" alt="cancel.bmp (1526 bytes)">

Trang 73
</small> ñeå xoùa tin nhaén vaø baét ñaàu moät tin nhaén môùi, hay hieäu chænh tin nhaén ñang
hieån thò,<small> </small>nhaán<small>
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)">
</small>&nbsp; moãi khi hoaøn thaønh tin nhaén, ñeå vaøo caùc tuøy choïn cuûa noù
</small><br>
<sub><strong>&nbsp;&nbsp;&nbsp; Send Message</strong> (Göûi tin nhaén)<br>
<strong>&nbsp;&nbsp;&nbsp; Store Message</strong> (löu tin nhaén laïi trong danh
saùch nhöõng tin nhaén göûi ñi)</sub><br>
<br>
<small>Ñeå tham khaûo veà caùch nhaäp kyù töï, xin xem muïc &quot;
<a href="#nhap-ky-tu"><small>Caù</small>ch nhaäp kyù tö</a>ï&quot;
</small></font></p>

<hr>

<p><font face="VNI-Times"><font color="#FF0000"><big>


<a name="msg setting"><sub>Caøi ñaët tin nhaén</sub><br>
</a></big></font><sub>(Message Settings)</sub></font></p>

<p><font face="VNI-Times"><small>1.&nbsp;Duøng caùc phím <small>


<img src="up.jpg" width="26" height="20" alt="up.bmp (2550 bytes)">,
<img src="down.jpg" width="28" height="20" alt="down.bmp (2262 bytes)">&nbsp;
</small>(phím cuoän) ñeå di chuyeån ñeán muïc &quot;
<strong> Messages</strong>&quot;, nhaán<small>
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)">
</small></small>.<br>
<small>2.&nbsp;Tieáp tuïc duøng caùc phím cuoän ñeå cuoän ñeán muïc &quot;
<strong>Massage Settings</strong>&quot;<small>, </small>nhaán <small>&nbsp;
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)">
</small>ñeå vaøo menu con</small><br>
<br>
<strong><small>Voicemail Number</small></strong><br>
<small>Duøng ñeå nhaäp vaøo moät soá ñieän thoaïi, laø soá ñöôïc duøng cho muïc &quot;Call
Voicemail&quot;. Neáu ñaõ toàn taïi 1 soá, noù seõ ñöôïc hieån thò treân maøn hình. Luùc ñoù, ta
coù theå duøng, thay ñoåi hay xoùa&nbsp; noù neáu muoán.</small><br>
<strong><small>Service Centre</small></strong><br>
<small>Tröôùc khi baïn göûi ñi baát kyø tin nhaén naøo, baïn phaûi duøng tuøy choïn naøy ñeå nhaäp
vaøo soá ñieän thoaïi cuûa trung taâm dòch vuï tin nhaén.cuûa baïn. Neáu ñaõ toàn taïi 1 soá, noù seõ
ñöôïc hieån thò treân maøn hình. Luùc ñoù, ta coù theå duøng, thay ñoåi hay xoùa&nbsp; noù
neáu muoán.</small><br>
<strong><small>Expiry Period</small></strong><br>

Trang 74
Laäp Trình Web Vôùi Visual Basic

<small>Duøng ñeå chæ ñònh khoaûng thôøi gian toái ña ñeå nhöõng tin nhaén chöa göûi ñi, ñöôïc
löu treân trung taâm dòch vuï tin nhaén tröôùc khi noù ñöôïc göûi ñi. Khi ñöôïc choïn, maøn hình
seõ hieån thò thôøi gian ñaõ chæ ñònh hieän taïi. </small><br>
<strong><small>Outgoing Message Type</small></strong><br>
<small>Duøng ñeå chæ ñònh daïng thöùc cuûa tin nhaén göûi ñi.</small></font></p>

<p><font face="VNI-Times"><small>Duøng caùc phím <small>


<img src="up.jpg" width="26" height="20" alt="up.bmp (2550 bytes)">,
<img src="down.jpg" width="28" height="20" alt="down.bmp (2262 bytes)">&nbsp;
</small>ñeå di chuyeån giöõa caùc muïc trong menu con, nhaán<small>
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)">
</small> ñeå choïn.</small></font></p>

<hr>

<p><font face="VNI-Times"><font color="#FF0000">


<a name="network select">Choïn maïng hoaït ñoäng<br>
</a></font><small>(Network Selection)</small></font></p>

<p><small><font face="VNI-Times">Ñeå ñieän thoaïi coù theå nhaän hoaëc laøm moät cuoäc
goïi, noù phaûi ñaêng kyù vôùi moät trong nhöõng maïng coù giaù trò. Nhöõng maïng ñoù coù theå laø
GSM900, GSM1800 hay laø keát hôïp cuûa GSM900/1800. Tính naêng naøy ñöôïc duøng ñeå
choïn maïng hoaït ñoäng, thay ñoåi baêng taàn, hay tìm moät maïng môùi....</font>
</small></p>

<p><font face="VNI-Times"><font color="#FF0000">


<a name="change band">Thay ñoåi baêng taàn<br>
</a></font><small>(Change Band)</small></font></p>
<p><font face="VNI-Times"><small>Duøng caùc phím <small>
<img src="up.jpg" width="26"height="20" alt="up.bmp (2550 bytes)">,
<img src="down.jpg" width="28" height="20" alt="down.bmp (2262 bytes)">&nbsp;
</small>(phím cuoän) ñeå di chuyeån ñeán muïc &quot;
<strong>Network Selection</strong>&quot;, nhaán<small>
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)">
</small></small> <small>2 laàn ñeå vaøo caùc menu con cuûa muïc &quot;
<strong>Change Band</strong>&quot;</small></font></p>

<p><font face="VNI-Times"><small><strong>Change to 900/1800<br>


</strong>Thay ñoåi sang daõy baêng taàn 900/1800<br>
<strong>Change to 900</strong><br>Thay ñoåi sang daõy baêng taàn 900<br>
<strong>Change to 1800</strong><br>Thay ñoåi sang daõy baêng taàn 1800</small>

Trang 75
<br>
<small>Duøng caùc phím cuoän ñeå di chuyeån giöõa caùc menu con cuûa muïc &quot;
<strong>Change Band</strong>&quot;<small>, </small>nhaán<small>&nbsp;
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)">
</small>ñeå&nbsp; choïn</small></font></p>

<hr>

<p><font face="VNI-Times"><font color="#FF0000">


<a name="avail network">Nhöõng maïng coù theå duøng<br>
</a></font><small>(Available Networks)</small></font></p>

<p><font face="VNI-Times"><small>1.&nbsp; Duøng caùc phím <small>


<img src="up.jpg" width="26" height="20" alt="up.bmp (2550 bytes)">,
<img src="down.jpg" width="28" height="20" alt="down.bmp (2262 bytes)">&nbsp;
</small>(phím cuoän) ñeå di chuyeån ñeán muïc &quot;
<strong> Network Selection</strong>&quot;, nhaán<small>
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)">
</small></small> .<br>
<small>2.&nbsp; Tieáp tuïc duøng caùc phím cuoän ñeå di chuyeån ñeán muïc &quot;
<strong>Available Network</strong>&quot;, nhaán<small>
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)">
</small></small> .<br>
<small>Khi ñöôïc choïn, chöùc naêng naøy seõ queùt ñeå tìm xem nhöõng maïng naøo ñang hoaït
ñoäng ôû vò trí hieän taïi cuûa baïn. Khi vieäc queùt ñaõ hoaøn thaønh, duøng caùc phím cuoän ñeå di
chuyeån giöõa caùc muïc trong danh saùch. Khi baïn tìm thaáy moät maïng vaø muoán ñaêng kyù
hoaëc löu noù trong danh saùch nhöõng maïng öu tieân, nhaán <small><small>
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)">
</small></small> . Khi ñoù baïn seõ vaøo menu con cuûa muïc</small>
<small>&quot;<strong>Available Network</strong>&quot;.</small><br>
<br>
<strong><small>Register Now </small></strong><br>
<small>Moãi khi ñöôïc choïn, maùy seõ coá gaéng ñaêng kyù vôùi maïng ñaõ choïn.</small><br>
<strong><small>Make Preferred</small></strong><br>
<small>Moãi khi ñöôïc choïn, baïn seõ phaûi nhaäp vaøo vò trí cuûa maïng ñaõ choïn trong danh
saùch nhöõng maïng öu tieân.</small><br>
<small>Duøng caùc phím cuoän ñeå di chuyeån giöõa caùc menu con cuûa noù<small>,
</small>nhaán<small>&nbsp;
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)">
</small>ñeå&nbsp; choïn.</small></font></p>

Trang 76
Laäp Trình Web Vôùi Visual Basic

<hr>

<p><font face="VNI-Times"><font color="#FF0000">


<a name="find network">Tìm maïng <br>
</a></font><small>(Network Search)<br> Laø moät tính naêng trong ñoù coù nhöõng tuøy
choïn quyeát ñònh caùch laøm theá naøo hoaëc bao laâu thì maùy cuûa baïn seõ ñaêng kyù vôùi moät
maïng.<br>
1.&nbsp; Duøng caùc phím <small>
<img src="up.jpg" width="26" height="20" alt="up.bmp (2550 bytes)">,
<img src="down.jpg" width="28" height="20" alt="down.bmp (2262 bytes)">&nbsp;
</small>(phím cuoän) ñeå di chuyeån ñeán muïc &quot;
<strong> Network Selection</strong>&quot;, nhaán<small>
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)">
</small></small> .<br>
<small>2.&nbsp; Tieáp tuïc duøng caùc phím cuoän ñeå<small>
</small>di chuyeån ñeán muïc &quot;
<strong>Network Search</strong>&quot;, nhaán<small>
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)">
</small></small> <small>ñeå vaøo menu con </small><br>
<br>
<strong><small>Registration Preferences</small><br>
</strong><small>Quy ñònh maùy cuûa baïn seõ laøm theá naøo ñeå ñaêng kyù vôùi moät maïng.
Tuøy choïn naøy coù 2 cheá ñoä <br>
<em><strong>Automatic Search</strong></em></small><br>
<small>Trong cheá ñoä töï ñoäng tìm, may seõ coá gaéng ñaêng kyù vôùi maïng ñaàu tieân trong
danh saùch ñaõ löu. Neáu thaønh coâng, noù seõ hieån thò teân cuûa maïng vaø sau ñoù vaøo cheá ñoä
chôø.<br> Neáu vieäc ñaêng kyù khoâng thaønh coâng, noù seõ tieáp tuïc ñaêng kyù vôùi nhöõng maïng
keá tieáp.<br>
<em><strong>Manual Search Mode.</strong></em></small><br>
<small>Trong cheá ñoä tìm thuû coâng, maùy seõ trình baøy danh saùch cuûa nhöõng maïng ñaõ
löu. Duøng caùc phím vaø ñeå choïn moät töø trong danh saùch ñoù. Maùy ñieän thoaïi cuûa baïn seõ
coá gaéng ñaêng kyù vôùi maïng ñaõ choïn.</small></font></p>

<p><font face="VNI-Times">
<small><strong>Frequency of Search</strong></small><br>
<small>Tuøy choïn naøy duøng ñeå quy ñònh maùy seõ chôø bao laâu, tröôùc khi coá gaéng ñaêng
kyù laïi sau khi vieäc ñaêng kyù tröôùc ñoù ñaõ thaát baïi. Tuøy choïn naøy coù nhöõng thieát laäp sau
:<br>
<strong><em>Slow Search</em><br>
<em>Medium Search</em><br>
<em>Fast Search</em><br>

Trang 77
<em>Continuous Search</em></strong></small><br>
<small>Duøng caùc phím cuoän ñeå di chuyeån giöõa caùc menu con<small>,
</small>nhaán<small>
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)">
</small>ñeå choïn.</small></font></p>

<hr>

<p><font face="VNI-Times"><font color="#FF0000">


<a name="prefer network">Nhöõng maïng öu tieân<br>
</a></font><small>(Preferred Networks)<br>
1.&nbsp; Duøng caùc phím <small>
<img src="up.jpg" width="26" height="20" alt="up.bmp (2550 bytes)">,
<img src="down.jpg" width="28" height="20" alt="down.bmp (2262 bytes)">&nbsp;
</small>(phím cuoän) ñeå di chuyeån ñeán muïc&quot;
<strong> Network Selection</strong>&quot;, nhaán<small>
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)">
</small></small> .<br>
<small>2.&nbsp; Tieáp tuïc duøng caùc phím cuoän ñeå di chuyeån ñeán muïc &quot;
<strong>Preferred Network</strong>&quot;, nhaán<small>
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)">
</small></small> <small>ñeå vaøo menu con </small><br>
<br><small>
<a href="#add list">Add Network to List</a> (Theâm maïng vaøo trong danh saùch
öu tieân)<br>
<a href="#show list">Show List of Networks</a> (Hieån thò danh saùch maïng öu
tieân)</small><br>
<small>Duøng caùc phím cuoän ñeå di chuyeån giöõa caùc menu con<small>,
</small>nhaán<small>
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)">
</small>ñeå choïn.</small></font></p>

<hr>

<p><font face="VNI-Times"><font color="#FF0000">


<a name="add list">Theâm maïng vaøo trong danh saùch<br>
</a></font><small>(Add Network to List)
<br>Tính naêng naøy cho pheùp baïn theâm maïng vaøo trong danh saùch maïng öu tieân.
</small><br>
<small>1.&nbsp; Duøng caùc phím <small>
<img src="up.jpg" width="26" height="20" alt="up.bmp (2550 bytes)">,

Trang 78
Laäp Trình Web Vôùi Visual Basic

<img src="down.jpg" width="28" height="20" alt="down.bmp (2262 bytes)">&nbsp;


</small>(phím cuoän)&nbsp; ñeå di chuyeån ñeán muïc &quot;
<strong> Network Selection</strong>&quot;, nhaán<small>
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)">
</small></small> .<br>
<small>2.&nbsp; Tieáp tuïc duøng caùc phím cuoän ñeå di chuyeån ñeán muïc &quot;
<strong>Preferred Network</strong>&quot;, nhaán<small>
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)">
</small></small> <small>2 laàn ñeå vaøo &nbsp;menu con cuûa muïc &quot;
<strong>Add Network to List</strong>&quot;.</small></font><br>
<font face="VNI-Times"><small>
<strong>Choose From Available</strong></small><br>
<small>Tuøy choïn seõ queùt ñeå tìm nhöõng maïng ñang hoaïy ñoäng ôû vò trí hieän taïi cuûa
baïn. Khi vieäc queùt ñaõ hoaøn thaønh, duøng caùc phím cuoän ñeå di chuyeån giöõa caùc muïc
trong danh saùch. Khi baïn tìm thaáy moät maïng vaø muoán löu noù trong danh saùch nhöõng
maïng öu tieân, nhaán <small><small>
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)">
</small></small> . Khi ñoù baïn seõ ñöôïc hoûi ñeå nhaäp vaøo vò trí cuûa maïng ñaõ choïn trong
danh saùch nhöõng maïng tham khaûo.</small><br>
<small><strong>Choose From Known</strong></small><br>
<small>Khi ñöôïc choïn, maùy seõ trình baøy moät danh saùch caùc maïng. Duøng caùc phím
cuoän ñeå duyeät qua danh saùch. Khi baïn tìm thaáy moät maïng vaø muoán löu noù trong danh
saùch nhöõng maïng öu tieân, nhaán <small><small>
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)">
</small></small> . Khi ñoù baïn seõ ñöôïc hoûi ñeå nhaäp vaøo vò trí cuûa maïng ñaõ choïn trong
danh saùch nhöõng maïng tham khaûo.</small><br>
<small>Duøng caùc phím cuoän ñeå di chuyeån giöõa caùc menu con<small>,
</small>nhaán<small>
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)">
</small>ñeå choïn.</small></font></p>

<hr>

<p><font face="VNI-Times"><font color="#FF0000">


<a name="show list">Hieån thò danh saùch maïng öu tieân<br>
</a></font><small>(Show List of Networks)<br>
Duøng ñeå hieån thò nhöõng maïng baïn ñaõ löu trong danh saùch.</small><br>
<small>1.&nbsp;&nbsp;Duøng caùc phím <small>
<img src="up.jpg" width="26" height="20" alt="up.bmp (2550 bytes)">,
<img src="down.jpg" width="28" height="20" alt="down.bmp (2262 bytes)">&nbsp;
</small>(phím cuoän)&nbsp; ñeå di chuyeån ñeán muïc &quot;

Trang 79
<strong>Network Selection</strong>&quot;, nhaán<small>
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)">
</small></small> .<br>
<small>2.&nbsp;&nbsp;Duøng caùc phím cuoän<small>
</small>di chuyeån ñeán muïc &quot;
<strong>Preferred Network</strong>&quot;, nhaán<small>
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)">
</small></small> <small>ñeå vaøo menu con.<br>
3.&nbsp;&nbsp;Tieáp tuïc duøng caùc phím cuoän cuoän ñeán muïc &quot;
<strong>Show List of Networks</strong>&quot;, nhaán <small>
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)">
</small> seõ hieån thò danh saùch nhöõng maïng ñaõ ñöôïc löu.
<br> Ñeå duyeät qua danh saùch naøy duøng phím cuoän, nhaán <small>
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)">
</small> seõ choïn muïc hieän taïi vaø ñi vaøo menu con </small><br>
<small><strong>Move to New Location</strong>
<br>Baïn seõ phaûi nhaäp vaøo giaù trò vò trí môùi cuûa maïng ñaõ choïn.<br>
<strong>Delete Selection<br>
</strong>Xoùa maïng ñaõ choïn.</small><br>
<small>Duøng caùc phím cuoän ñeå di chuyeån giöõa caùc menu con<small>,
</small>nhaán<small>
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)">
</small>ñeå choïn.</small></font></p>

<hr>

<p><font face="VNI-Times"><font color="#FF0000">


<a name="find new">Tìm maïng môùi<br>
</a></font><small>(Find New Network)<br>
1.&nbsp; Duøng caùc phím <small>
<img src="up.jpg" width="26" height="20" alt="up.bmp (2550 bytes)">,
<img src="down.jpg" width="28" height="20" alt="down.bmp (2262 bytes)">&nbsp;
</small>(phím cuoän)&nbsp; ñeå di chuyeån ñeán muïc &quot;
<strong>Network Selection</strong>&quot;, nhaán<small>
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)">
</small></small> .<br>
<small>2.&nbsp; Duøng caùc phím cuoän<small>
</small>di chuyeån ñeán muïc &quot;
<strong>FindNew Network</strong>&quot;, nhaán<small>
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)">
</small></small> <small>ñeå thöïc hieän vieäc tìm maïng môùi.</small></font></p>

Trang 80
Laäp Trình Web Vôùi Visual Basic

<hr>

<p><font face="VNI-Times">
<font color="#FF0000">Thieát laäp nhöõng thieát bò ñính keøm</font>
<br>(Accessory Setup Menu)</font></p>

<p>&nbsp;</p>

<p><font face="VNI-Times"><br>
</font><font face="VNI-Times" color="#FF0000">
<a name="quick access">Duøng Menu truy caäp nhanh<br>
</a></font><small>
<font face="vni-times">(Quick Access Menu)</font></small></p>

<p><small><font face="vni-times">Ñaây laø öu ñieåm ñoäc ñaùo cuûa maùy Motorola maø
caùc maùy khaùc khoâng coù ñöôïc. Noù cho pheùp baïn choïn 9 chöùc naêng thöôøng duøng maø
khoâng phaûi raø tìm loøng voøng trong caùc menu. Baèng caùch baám phím</font>
<img src="arrow.jpg" width="20" height="20" alt="arrow.bmp (1954 bytes)">
<font face="VNI-Times">vaø keát hôïp moät trong caùc phím soá töø 1 ñeán 9 ; hoaëc baám
phím </font>
<img src="arrow.jpg" width="20" height="20" alt="arrow.bmp (1954 bytes)">
<font face="VNI-Times">keát hôïp vôùi caùc phím<small> <small>
<img src="up.jpg" width="26" height="20" alt="up.bmp (2550 bytes)">,
<img src="down.jpg" width="28" height="20" alt="down.bmp (2262 bytes)">
</small></small> (phím cuoän) ñeå tìm chöùc naêng. Baám <small><small>
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)">
</small></small> ñeå choïn.
<br>Baïn cuõng coù theå thieát keá laïi menu truy caäp nhanh ôû treân cho phuø hôïp vôùi yù thích.
Motorola ñöa ra ñeán 20 chöùc naêng thoâng duïng ñeå baïn choïn laáy 9 chöùc naêng.<br>
&nbsp;&nbsp;&nbsp; * Caùch laøm nhö sau :<br>Baám </font>
<img src="arrow.jpg" width="20" height="20" alt="arrow.bmp (1954 bytes)">
<font face="VNI-Times">vaø duøng phím cuoän hay duøng phím soá cuoän ñeán vò trí maø
baïn muoán ñoåi, baám vaø giöõ phím <small><small>
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)">
</small></small> moät luùc, maøn hình seõ hieån thò danh saùch caùc chöùc naêng, tieáp tuïc
duøng caùc phím cuoän ñeå tìm chöùc naêng maø baïn thích. Baám <small><small>
<img src="ok.jpg" width="28" height="17" alt="ok.bmp (1902 bytes)">
</small></small> khi muoán choïn.Chöùc naêng môùi seõ ñöôïc thay theá vaøo vò trí
ñoù.</font>
</small></p>

Trang 81
<p align="center"><a href="use-phonebook.htm">
<img src="backtop.gif" width="196"height="31" alt="backtop.gif (754
bytes)"></a></p>

<p><font face="VNI-Times"><br>
</font></p>
</body>
</html>

3.2. Maõ nguoàn cuûa ActiveX Control


 Khai baùo caùc bieán chung
Option Explicit
Private Type entry 'khai bao entry la muc kieu ban ghi
name As String * 10
number As String * 10
location As Integer
End Type

Private Type access 'khai bao access la mot kieu ban ghi
feature As String * 16 'luu giu ten tinh nang trong menu quick access
thutu As Integer
End Type

Private Type messages


tin As String * 25
sothutu As Integer
End Type

Private Type netselect


mang As String * 10
End Type

Dim found As Boolean 'la true khi tim thay entry can tim
Const filename3 = "c:\menuquickaccess.lst"
Const filename = "c:\entryphone.lst"
Const filename1 = "c:\entrysim.lst"
Const filename2 = "c:\entryprevent.lst"
Const filename4 = "c:\messages.lst"
Const filetam = "c:\filetam.lst"
Const filename5 = "c:\filenetwork.list"

Trang 82
Laäp Trình Web Vôùi Visual Basic

Const filename6 = "c:\preferrednetwork.list"


Const filefixed = "c:\fixeddialling.lst"
Dim i As Integer
Dim st1 As String
Dim lo As Integer 'bien luu location
Dim nu As String 'bien luu number
Dim st As String 'bien luu name
Dim vitri As Integer 'giu vi tri khi tim thay hoac di chuyen giua cac entry
Dim flag As Boolean
Dim prevent As Integer 'giu trang thai trong muc Prevent Access
Dim formattime As Boolean
Dim unlocked As String 'luu chuoi giai ma khi phone o trang thai lock
Dim line2 As Boolean 'co bang true khi line2 o trang thai ON
Dim securitycode As String
Dim pin2code As String 'luu chuoi ma PIN2
Dim advolume As Boolean 'bien co khi vao muc Adjust Ring Volume
Dim vol As Integer 'luu gia tri hien tai cua volume o muc thu bao nhieu
Dim menucon As Boolean 'bien giu vao menu con cua Find
Dim aftermouseup As Date
Dim aftermousedown As Date
Dim danhso As Boolean 'ghi trang thai ban phim la so
Dim cancle As Boolean
Dim longpress As Boolean 'khi nguoi su dung nhan va giu phim
Dim quickaccess As Boolean 'khi vao trong menu quickaccess
Dim orderinquick As Integer
Dim thu As Boolean 'bien co khi nhan va giu mot phim de vao menu quick access
Dim changecase As Boolean 'doi chu hoa thanh thuong va nguoc lai
Dim onetouchphone As Boolean 'goi so bang 1 phim trong bo nho may
Dim onetouchof As Byte 'nhan biet One Touch Dial cua muc nao
Dim messagelist As Boolean 'bien co khi vao trong danh sach message
Dim taomoi As Boolean 'bien co cho biet la tao tin nhan moi hay la thay doi tin nhan
Dim voicemailnumber As String 'luu so voicemail
Dim servicecentre As String 'luu so service centre
Dim expiryperiod As String 'bien luu gia tri max hour cua 1 tin nhan khi chua gui di
trong message setting
Dim messagenumber As Integer 'so thu tu cua message
Dim editor As Boolean 'bien co khi hieu chinh tin nhan
Dim availablenetwork As Boolean 'bien khi lam viec trong muc available networks
Dim tam1 As Integer
Dim cancall As Boolean 'de biet mot so co the goi duoc hay khong
Dim setupfixed As Boolean 'trong muc setup fixed dialling

Trang 83
Dim listdial As Boolean 'bien co dung de di chuyen giua nhung muc trong danh sach
Fixed Dial
Dim editentrylist As Boolean 'bien dung trong muc edit entry cua Fixed dial
Dim eraseentrylist As Boolean 'bien dung trong muc edit entry cua Fixed dial
Dim addentrylist As Boolean 'bien dung trong Add Entry cua Fixed Dialling
Dim callbarring As Boolean 'bien dung trong muc Call Barring
Dim barpassword As String 'luu ma chan cuoc goi
Dim showtime As Boolean
Dim luumuc As Integer 'luu muc trong menu quick access

 Thuû tuïc khi nhaán phím chuoät


Private Sub so_MouseDown(Index As Integer, Button As Integer, Shift As Integer, X
As Single, Y As Single)
aftermousedown = Time
End Sub

 Thuû tuïc khi thaû chuoät


Private Sub so_MouseUp(Index As Integer, Button As Integer, Shift As Integer, X As
Single, Y As Single)
Dim k As Integer
Dim st As String
Dim st1 As String
Static switch As Boolean
Dim starttime As Date
Dim menuaccess As access
Dim news As entry
Dim banghi As Byte
Dim j As Byte
Dim co As Boolean

aftermouseup = Time
starttime = aftermouseup - aftermousedown
If Second(starttime) > 2 Then
'xu ly khi user nhan va giu phim OK de vao bang chuc nang trong Quick Access
If Index = 13 And thu = True Then
If volume.Visible = True Then
volume.Visible = False
tbnhap.Visible = True
Frame1.Height = 500
Frame1.Width = 1800
End If

Trang 84
Laäp Trình Web Vôùi Visual Basic

showtime = False
tbnhap.Text = "Find by Name"
Image2.Visible = False
st = tbnhap.Text
longpress = True
cancle = True
danhso = False
Exit Sub
End If

'xu ly cua muc chuyen chu hoa thanh chu thuong trong khi nhap chu
If changecase = True Then
If switch = False Then
k = InStr(tbnhap.Text, vbLf)
st = LCase(Mid(tbnhap.Text, k + 1))
st1 = tbnhap.Text
Mid(st1, k + 1) = st
tbnhap.Text = Left(st1, Len(st1) - 1)
switch = True
Exit Sub
Else
k = InStr(tbnhap.Text, vbLf)
st = UCase(Mid(tbnhap.Text, k + 1))
st1 = tbnhap.Text
Mid(st1, k + 1) = st
tbnhap.Text = Left(st1, Len(st1) - 1)
switch = False
Exit Sub
End If
End If

'xu ly khi nhan va giu phim cancle de xoa va bat dau tin nhan moi
If Index = 10 And editor = True Then 'messagelist = True Then
tbnhap.Text = ""
danhso = False
cancle = False
taomoi = True
messagelist = False
Exit Sub
End If

Trang 85
'xu ly cua phan One-touch Dial Setting
If onetouchphone = True Then
danhso = False
Select Case Index
Case 1
Call onetouch(1)
Case 2
Call onetouch(2)
Case 3
Call onetouch(3)
Case 4
Call onetouch(4)
Case 5
Call onetouch(5)
Case 6
Call onetouch(6)
Case 7
Call onetouch(7)
Case 8
Call onetouch(8)
Case 9
Call onetouch(9)
End Select
Else
danhso = True
Exit Sub
End If
Else
Exit Sub
End If
End Sub

 Thuû tuïc khi nhaán moät phím soá


Private Sub so_Click(Index As Integer)
Dim n As Byte 'bien luu len(tbnhap)cho su kien index
Dim j As Byte 'giu gia tri cho vong lap
Static swit As Boolean 'xet luu o dt hay SIM
Dim k As Integer
Dim ch As String
Dim news As entry
Static tam As Integer 'luu gia tri tam khi o trong tinh nang Prevent Access

Trang 86
Laäp Trình Web Vôùi Visual Basic

Dim menuaccess As access


Dim message As messages
Static onoff As Boolean
Dim banghi As Byte
Static setup As Boolean 'bien co khi lam viec voi muc Phone setup
Static extend As Boolean 'bien co devao nhung muc cua menu mo rong
Static newdate As Date
Static newtime As Date
Static locked As Boolean 'bien co khi lam viec voi muc Phone lock
Static autolocked As Boolean
Static phonebook As Boolean 'bien co khi lam viec voi muc Phone Book
Static accessory As Boolean 'bien co trong menu Accessory
Static network As Boolean 'bien co trong menu Network
Static features As Boolean 'bien co trong menu CAll related features
Static message1 As Boolean
Static callnumberfixed As Boolean
Static sending As Boolean 'bien co de biet co gui tin nhan di khong
Static voice As Boolean 'co khi vao trong muc voice mail number
Static service As Boolean 'co khi vao trong muc service centre
Static expiry As Boolean 'co khi vao trong muc expiry period
Static setting As Boolean 'co khi vao trong message setting va nhan cancle
Static send As Boolean 'de nhan biet trong muc send message
Static callnumber As Boolean
Dim networks As netselect
Static showlist As Boolean 'danh sach preferred network
Static manualsearch As Boolean 'bien co trong muc Manual Search Mode
Static addnetwork As Boolean 'bien co trong muc Add Network to List
Dim cd As Integer
Static timthay As Boolean 'tim duoc muc trong Fixed dial
Dim chuoitam As String

If tbnhap.Text = "Locked" Then


tbnhap.Text = "Unlock Code" & vbCrLf
danhso = True
cancle = True
Exit Sub
End If

If showtime = True Then


tbnhap.Text = "Menu"
showtime = False

Trang 87
Exit Sub
End If

If tbnhap.Text = "Menu" Then


If Index >= 0 And Index < 10 Then
tbnhap.Text = ""
danhso = True
cancle = True
End If
End If

'khi nguoi su dung nhan so de lam cuoc goi


If (danhso = True) Or Left(tbnhap.Text, 11) = "Unlock Code" Then
Select Case Index
Case 0
tbnhap.Text = tbnhap.Text & "0"
Case 1
tbnhap.Text = tbnhap.Text & "1"
Case 2
tbnhap.Text = tbnhap.Text & "2"
Case 3
tbnhap.Text = tbnhap.Text & "3"
Case 4
tbnhap.Text = tbnhap.Text & "4"
Case 5
tbnhap.Text = tbnhap.Text & "5"
Case 6
tbnhap.Text = tbnhap.Text & "6"
Case 7
tbnhap.Text = tbnhap.Text & "7"
Case 8
tbnhap.Text = tbnhap.Text & "8"
Case 9
tbnhap.Text = tbnhap.Text & "9"
End Select
End If

'truong hop cho phep user dung ban phim de nhap ky tu


If cancle = False Then
Select Case Index

Trang 88
Laäp Trình Web Vôùi Visual Basic

'********** phim so 0 *****************


Case 0
'user dung phim so trong menu message
If quickaccess = True Then
Exit Sub
End If
If messagelist = True Then
tbnhap.Text = "Invalid Msg Number"
messagelist = False
Exit Sub
End If

'user dung phim so de nhap ky tu


Select Case i
Case 0
tbnhap.Text = tbnhap.Text & "+"
i=i+1
Case 1
n = Len(tbnhap.Text)
tbnhap.Text = Left(tbnhap.Text, n - 1) & "-"
i=i+1
Case 2
n = Len(tbnhap.Text)
tbnhap.Text = Left(tbnhap.Text, n - 1) & "0"
i=i+1
Case 3
n = Len(tbnhap.Text)
tbnhap.Text = Left(tbnhap.Text, n - 1) & "="
i=i+1
Case 4
n = Len(tbnhap.Text)
tbnhap.Text = Left(tbnhap.Text, n - 1) & "*"
i=i+1
Case 5
n = Len(tbnhap.Text)
tbnhap.Text = Left(tbnhap.Text, n - 1) & "/"
'i = 0
End Select

'**************phim so 1*****************
Case 1

Trang 89
'user dung phim so trong menu quick access
If quickaccess = True Then
luumuc = clickquickaccess(1)
orderinquick = 1
Exit Sub
End If

'user dung phim so trong menu message


If messagelist = True Then
Call clickmessage(1)
Exit Sub
End If

'user dung phim de nhap ky tu


Select Case i
Case 0
tbnhap.Text = tbnhap.Text & " "
i=i+1
Case 1
n = Len(tbnhap.Text)
tbnhap.Text = Left(tbnhap.Text, n - 1) & "."
i=i+1
Case 2
n = Len(tbnhap.Text)
tbnhap.Text = Left(tbnhap.Text, n - 1) & "1"
i=i+1
Case 3
n = Len(tbnhap.Text)
tbnhap.Text = Left(tbnhap.Text, n - 1) & "?"
i=i+1
Case 4
n = Len(tbnhap.Text)
tbnhap.Text = Left(tbnhap.Text, n - 1) & "!"
i=i+1
Case 5
n = Len(tbnhap.Text)
tbnhap.Text = Left(tbnhap.Text, n - 1) & ":"
'i = 0
End Select

'**************phim so 2******************

Trang 90
Laäp Trình Web Vôùi Visual Basic

Case 2
'user dung phim so trong menu quick access
If quickaccess = True Then
luumuc = clickquickaccess(2)
orderinquick = 2
Exit Sub
End If

'user dung phim so trong menu message


If messagelist = True Then
Call clickmessage(2)
Exit Sub
End If

'user dung phim so de nhap ky tu


Select Case i
Case 0
tbnhap.Text = tbnhap.Text & "A"
i=i+1
Case 1
n = Len(tbnhap.Text)
tbnhap.Text = Left(tbnhap.Text, n - 1) & "B"
i=i+1
Case 2
n = Len(tbnhap.Text)
tbnhap.Text = Left(tbnhap.Text, n - 1) & "C"
i=i+1
Case 3
n = Len(tbnhap.Text)
tbnhap.Text = Left(tbnhap.Text, n - 1) & "2"
'i = 0
End Select

'****************phim so 3***************
Case 3
'user dung phim so trong menu quick access
If quickaccess = True Then
luumuc = clickquickaccess(3)
orderinquick = 3
Exit Sub
End If

Trang 91
'user dung phim so trong menu message
If messagelist = True Then
Call clickmessage(3)
Exit Sub
End If

'user dung phim so de nhap ky tu


Select Case i
Case 0
tbnhap.Text = tbnhap.Text & "D"
i=i+1
Case 1
n = Len(tbnhap.Text)
tbnhap.Text = Left(tbnhap.Text, n - 1) & "E"
i=i+1
Case 2
n = Len(tbnhap.Text)
tbnhap.Text = Left(tbnhap.Text, n - 1) & "F"
i=i+1
Case 3
n = Len(tbnhap.Text)
tbnhap.Text = Left(tbnhap.Text, n - 1) & "3"
'i = 0
End Select

'***************phim so 4****************
Case 4
'user dung phim so trong menu quick access
If quickaccess = True Then
luumuc = clickquickaccess(4)
orderinquick = 4
Exit Sub
End If

'user dung phim so trong menu message


If messagelist = True Then
Call clickmessage(4)
Exit Sub
End If

Trang 92
Laäp Trình Web Vôùi Visual Basic

'user dung phim so de nhap ky tu


Select Case i
Case 0
tbnhap.Text = tbnhap.Text & "G"
i=i+1
Case 1
n = Len(tbnhap.Text)
tbnhap.Text = Left(tbnhap.Text, n - 1) & "H"
i=i+1
Case 2
n = Len(tbnhap.Text)
tbnhap.Text = Left(tbnhap.Text, n - 1) & "I"
i=i+1
Case 3
n = Len(tbnhap.Text)
tbnhap.Text = Left(tbnhap.Text, n - 1) & "4"
'i = 0
End Select

'************** phim so 5 ***************


Case 5
'user dung phim so trong menu quick access
If quickaccess = True Then
luumuc = clickquickaccess(5) 'menuaccess.thutu
orderinquick = 5
Exit Sub
End If

'user dung phim so trong menu message


If messagelist = True Then
Call clickmessage(5)
Exit Sub
End If

'user dung phim so de nhap ky tu


Select Case i
Case 0
tbnhap.Text = tbnhap.Text & "J"
i=i+1
Case 1
n = Len(tbnhap.Text)

Trang 93
tbnhap.Text = Left(tbnhap.Text, n - 1) & "K"
i=i+1
Case 2
n = Len(tbnhap.Text)
tbnhap.Text = Left(tbnhap.Text, n - 1) & "L"
i=i+1
Case 3
n = Len(tbnhap.Text)
tbnhap.Text = Left(tbnhap.Text, n - 1) & "5"
'i = 0
End Select

'*************** phim so 6 ***************


Case 6
'user dung phim so trong menu quick access
If quickaccess = True Then
luumuc = clickquickaccess(6) 'menuaccess.thutu
orderinquick = 6
Exit Sub
End If

'user dung phim so trong menu message


If messagelist = True Then
Call clickmessage(6)
Exit Sub
End If

'user dung phim so de nhap ky tu


Select Case i
Case 0
tbnhap.Text = tbnhap.Text & "M"
i=i+1
Case 1
n = Len(tbnhap.Text)
tbnhap.Text = Left(tbnhap.Text, n - 1) & "N"
i=i+1
Case 2
n = Len(tbnhap.Text)
tbnhap.Text = Left(tbnhap.Text, n - 1) & "O"
i=i+1
Case 3

Trang 94
Laäp Trình Web Vôùi Visual Basic

n = Len(tbnhap.Text)
tbnhap.Text = Left(tbnhap.Text, n - 1) & "6"
'i = 0
End Select

'**************** phim so 7 **************


Case 7
'user dung phim so trong menu quick access
If quickaccess = True Then
luumuc = clickquickaccess(7)
orderinquick = 7
Exit Sub
End If

'user dung phim so trong menu message


If messagelist = True Then
Call clickmessage(7)
Exit Sub
End If

'user dung phim so de nhap ky tu


Select Case i
Case 0
tbnhap.Text = tbnhap.Text & "P"
i=i+1
Case 1
n = Len(tbnhap.Text)
tbnhap.Text = Left(tbnhap.Text, n - 1) & "Q"
i=i+1
Case 2
n = Len(tbnhap.Text)
tbnhap.Text = Left(tbnhap.Text, n - 1) & "R"
i=i+1
Case 3
n = Len(tbnhap.Text)
tbnhap.Text = Left(tbnhap.Text, n - 1) & "S"
i=i+1
Case 4
n = Len(tbnhap.Text)
tbnhap.Text = Left(tbnhap.Text, n - 1) & "7"
'i = 0

Trang 95
End Select

'*********** phim so 8 *******************


Case 8
'user dung phim so trong menu quick access
If quickaccess = True Then
luumuc = clickquickaccess(8)
orderinquick = 8
Exit Sub
End If

'user dung phim so trong menu message


If messagelist = True Then
Call clickmessage(8)
Exit Sub
End If

'user dung phim so de nhap ky tu


Select Case i
Case 0
tbnhap.Text = tbnhap.Text & "T"
i=i+1
Case 1
n = Len(tbnhap.Text)
tbnhap.Text = Left(tbnhap.Text, n - 1) & "U"
i=i+1
Case 2
n = Len(tbnhap.Text)
tbnhap.Text = Left(tbnhap.Text, n - 1) & "V"
i=i+1
Case 3
n = Len(tbnhap.Text)
tbnhap.Text = Left(tbnhap.Text, n - 1) & "8"
'i = 0
End Select

'************* phim so 9 *****************


Case 9
'user dung phim so trong menu quick access
If quickaccess = True Then
luumuc = clickquickaccess(9)

Trang 96
Laäp Trình Web Vôùi Visual Basic

orderinquick = 9
Exit Sub
End If

'user dung phim so trong menu message


If messagelist = True Then
Call clickmessage(9)
Exit Sub
End If

'user dung phim so de nhap ky tu


Select Case i
Case 0
tbnhap.Text = tbnhap.Text & "W"
i=i+1
Case 1
n = Len(tbnhap.Text)
tbnhap.Text = Left(tbnhap.Text, n - 1) & "X"
i=i+1
Case 2
n = Len(tbnhap.Text)
tbnhap.Text = Left(tbnhap.Text, n - 1) & "Y"
i=i+1
Case 3
n = Len(tbnhap.Text)
tbnhap.Text = Left(tbnhap.Text, n - 1) & "Z"
i=i+1
Case 4
n = Len(tbnhap.Text)
tbnhap.Text = Left(tbnhap.Text, n - 1) & "9"
'i = 0
End Select
End Select
End If

'********** phim cancle ******************


Select Case Index
Case 10
If volume.Visible = True Then
Exit Sub
End If

Trang 97
If locked = True Or autolocked = True Then
Exit Sub
End If

If callnumberfixed = True Then


callnumberfixed = False
End If

If listdial = True Then


listdial = False
'Exit Sub
End If

If callnumber = True Then


tbnhap.Text = "Menu"
callnumber = False
'Exit Sub
End If

If found = True Then 'And setup = False Then


tbnhap.Text = "Phone Book"
found = False
flag = False
menucon = False
Exit Sub
End If

If phonebook = True Then


tbnhap.Text = "Phone Book"
phonebook = False
send = False
Exit Sub
End If

'se thoat ra muc Phone Setup khi dang lam viec voi menu con cua no
If setup = True Then
tbnhap.Text = "Phone Setup"
setup = False
Exit Sub
End If

Trang 98
Laäp Trình Web Vôùi Visual Basic

'neu dang nam trong menu quick access then


If quickaccess = True Then
tbnhap.Text = "Menu"
quickaccess = False
danhso = True
Exit Sub
End If

If longpress = True Then


tbnhap.Text = "Menu"
longpress = False
danhso = True
Exit Sub
End If

If tbnhap.Text = "Overwritten?" Then


tbnhap.Text = "Enter Location!" & vbCrLf
Exit Sub
End If

If accessory = True Then


tbnhap.Text = "Accessory Setup"
accessory = False
Exit Sub
End If

If network = True Then


tbnhap.Text = "Network Selection"
network = False
showlist = False
Exit Sub
End If

If features = True Then


tbnhap.Text = "Call Related Features"
features = False
Exit Sub
End If

If message1 = True Then

Trang 99
tbnhap.Text = "Messages"
message1 = False
messagelist = False
Exit Sub
End If

If tbnhap.Text = "Phone Book" Or tbnhap.Text = "Messages" Or tbnhap.Text =


"Phone Setup" Then
tbnhap.Text = "Menu"
Exit Sub
End If

If tbnhap.Text = "Call Related Features" Or tbnhap.Text = "Network Selection" Or


tbnhap.Text = "Accessory Setup" Then
tbnhap.Text = "Menu"
Exit Sub
End If

If tbnhap.Text = "Are you sure?" Then


tbnhap.Text = "Network Selection"
network = False
showlist = False
Exit Sub
End If

If availablenetwork = True Or addnetwork = True Then


tbnhap.Text = "Network Selection"
availablenetwork = False
addnetwork = False
Exit Sub
End If

If editentrylist = True Or eraseentrylist = True Or addentrylist = True Then


editentrylist = False
addentrylist = False
eraseentrylist = False
Exit Sub
End If

If danhso = False And cancle = True Then


tbnhap.Text = "Menu"

Trang 100
Laäp Trình Web Vôùi Visual Basic

danhso = True
Exit Sub
End If

If danhso = True Or cancle = False Then


If editor = True Then
n = Len(tbnhap.Text)
If n = 0 Then
tbnhap.Text = "Messages"
editor = False
danhso = False
cancle = True
Exit Sub
Else
tbnhap.Text = Left(tbnhap.Text, n - 1)
Exit Sub
End If
End If

If setting = True Then


n = Len(tbnhap.Text)
If n = 0 Then
tbnhap.Text = "Messages"
danhso = False
cancle = True
setting = False
Else
tbnhap.Text = Left(tbnhap.Text, n - 1)
End If
Exit Sub
End If
k = InStr(tbnhap.Text, vbCr)
n = Len(tbnhap.Text)
If n = 0 Then
tbnhap.Text = "Menu"
Exit Sub
End If
If n = k + 1 Then
'Beep
tbnhap.Text = "Phone Book" '"Personal Number"
cancle = True

Trang 101
danhso = False
changecase = False
'Exit Sub
Else
If tbnhap.Text = "Menu" Then
Beep
Else
tbnhap.Text = Left(tbnhap.Text, n - 1)
Exit Sub
End If
End If
End If

'************ Phim menu-up ***************


Case 11
If tbnhap.Text = "Network Selection" Then
tbnhap.Text = "Phone Setup"
Exit Sub
End If

If tbnhap.Text = "Phone Setup" Then


tbnhap.Text = "Messages"
Exit Sub
End If

If tbnhap.Text = "Messages" Then


tbnhap.Text = "Call Related Features"
Exit Sub
End If

If tbnhap.Text = "Call Related Features" Then


tbnhap.Text = "Phone Book"
Exit Sub
End If

If tbnhap.Text = "Phone Book" Then


tbnhap.Text = "Accessory Setup"
Exit Sub
End If

If tbnhap.Text = "Accessory Setup" Then

Trang 102
Laäp Trình Web Vôùi Visual Basic

tbnhap.Text = "Network Selection"


Exit Sub
End If

'menu con cua muc Phone Book


If tbnhap.Text = "One-Touch Dial Setting" Then
tbnhap.Text = "Fixed Dialling"
Exit Sub
End If

If Trim(tbnhap.Text) = "Fixed Dialling" Then


tbnhap.Text = "Personal Number"
Exit Sub
End If

If tbnhap.Text = "Personal Number" Then


tbnhap.Text = "One-Touch Dial Setting"
Exit Sub
End If

'vao menu con cua muc Personal Number


If tbnhap.Text = "Prevent Access" Then
tbnhap.Text = "Check Capacity"
Exit Sub
End If

If tbnhap.Text = "Check Capacity" Then


tbnhap.Text = "Add Entry"
Exit Sub
End If

If tbnhap.Text = "Add Entry" Then


tbnhap.Text = "Find Entry by Location"
Exit Sub
End If

If tbnhap.Text = "Find Entry by Location" Then


tbnhap.Text = "Find Entry by Name"
Exit Sub
End If

Trang 103
If tbnhap.Text = "Find Entry by Name" Then
tbnhap.Text = "Prevent Access"
Exit Sub
End If

'vao menu con cua muc Check Capacity


If tbnhap.Text = "Check SIM Capacity" Then
tbnhap.Text = "Check Phone Capacity"
Exit Sub
End If

If tbnhap.Text = "Check Phone Capacity" Then


tbnhap.Text = "Check SIM Capacity"
Exit Sub
End If

'vao menu con cua muc Find Entry


If tbnhap.Text = "Erase Name and Number" Then
tbnhap.Text = "Modify Name or Number"
Exit Sub
End If

If tbnhap.Text = "Modify Name or Number" Then


tbnhap.Text = "Call Number"
Exit Sub
End If

If tbnhap.Text = "Call Number" Then


tbnhap.Text = "Erase Name and Number"
Exit Sub
End If

'menu con cua muc Prevent Access


If tbnhap.Text = "To Phone & SIM Memory" Then
tbnhap.Text = "To Phone Memory"
Exit Sub
End If

If tbnhap.Text = "To Phone Memory" Then


tbnhap.Text = "To SIM Card Memory"
Exit Sub

Trang 104
Laäp Trình Web Vôùi Visual Basic

End If

If tbnhap.Text = "To SIM Card Memory" Then


tbnhap.Text = "No Memory Restrictions"
Exit Sub
End If

If tbnhap.Text = "No Memory Restrictions" Then


tbnhap.Text = "To Phone & SIM Memory"
Exit Sub
End If

'menu con cua muc Add Entry


If tbnhap.Text = "Add To SIM Card Memory" Then
tbnhap.Text = "Add To Phone Memory"
Exit Sub
End If

If tbnhap.Text = "Add To Phone Memory" Then


tbnhap.Text = "Add To SIM Card Memory"
Exit Sub
End If

'xu ly cua muc Fixed Dialling


If tbnhap.Text = "Setup Fixed Dialling" Then
tbnhap.Text = "View Fixed Dial List"
Exit Sub
End If

If tbnhap.Text = "View Fixed Dial List" Then


tbnhap.Text = "Setup Fixed Dialling"
Exit Sub
End If

'xu ly cua muc Setup Fixed Dialling


If tbnhap.Text = "Off." Then
tbnhap.Text = "On."
Exit Sub
End If

If tbnhap.Text = "Erase Entry" Then

Trang 105
tbnhap.Text = " Add Entry"
Exit Sub
End If

If tbnhap.Text = " Add Entry" Then


tbnhap.Text = "Edit Entry"
Exit Sub
End If

If tbnhap.Text = "Edit Entry" Then


tbnhap.Text = "Off."
Exit Sub
End If

If tbnhap.Text = "On." Then


tbnhap.Text = "Erase Entry"
Exit Sub
End If

'phan xu ly khi vao menu con cua muc One-Touch Dial Setting
If tbnhap.Text = " To SIM Memory" Then
tbnhap.Text = " To Phone Memory"
Exit Sub
End If

If tbnhap.Text = " To Phone Memory" Then


tbnhap.Text = " To Fixed Dial List"
Exit Sub
End If

If tbnhap.Text = " To Fixed Dial List" Then


tbnhap.Text = " To SIM Memory"
Exit Sub
End If

'phan xu ly cua menu Call Related Features


If tbnhap.Text = "Key Answer Only" Then
tbnhap.Text = "Call Barring"
Exit Sub
End If

Trang 106
Laäp Trình Web Vôùi Visual Basic

If tbnhap.Text = "Call Barring" Then


tbnhap.Text = "Call Waiting"
Exit Sub
End If

If tbnhap.Text = "Call Waiting" Then


tbnhap.Text = "Talk and Fax"
Exit Sub
End If

If tbnhap.Text = "Talk and Fax" Then


tbnhap.Text = "Call Diverting"
Exit Sub
End If

If tbnhap.Text = "Call Diverting" Then


tbnhap.Text = "Restrict My Phone Number"
Exit Sub
End If

If tbnhap.Text = "Restrict My Phone Number" Then


tbnhap.Text = "Show Battery Meter"
Exit Sub
End If

If tbnhap.Text = "Show Battery Meter" Then


tbnhap.Text = "Key Answer Only"
Exit Sub
End If

'vao menu con cua muc Restrict My Phone Number


If tbnhap.Text = "Show ID On Next Call" Then
tbnhap.Text = "Restrict ID On Next Call"
Exit Sub
End If

If tbnhap.Text = "Restrict ID On Next Call" Then


tbnhap.Text = "Show ID On Next Call"
Exit Sub
End If

Trang 107
'vao menu con cua muc Call Diverting
If tbnhap.Text = "Divert Voice Calls" Then
tbnhap.Text = "Cancel All Diverting"
Exit Sub
End If

If tbnhap.Text = "Cancel All Diverting" Then


tbnhap.Text = "Divert Data Calls"
Exit Sub
End If

If tbnhap.Text = "Divert Data Calls" Then


tbnhap.Text = "Divert Fax Calls"
Exit Sub
End If

If tbnhap.Text = "Divert Fax Calls" Then


tbnhap.Text = "Divert Voice Calls"
Exit Sub
End If

'vao menu con cua muc Divert Voice Calls


If tbnhap.Text = "Divert When Unavailable" Then
tbnhap.Text = "Detailed Diverting"
Exit Sub
End If

If tbnhap.Text = "Detailed Diverting" Then


tbnhap.Text = "Divert All Voice Calls"
Exit Sub
End If

If tbnhap.Text = "Divert All Voice Calls" Then


tbnhap.Text = "Divert When Unavailable"
Exit Sub
End If

'vao menu con cua muc Detailed Diverting


If tbnhap.Text = "If No Answer" Then
tbnhap.Text = "If Not Reachable"
Exit Sub

Trang 108
Laäp Trình Web Vôùi Visual Basic

End If

If tbnhap.Text = "If Not Reachable" Then


tbnhap.Text = "If Busy"
Exit Sub
End If

If tbnhap.Text = "If Busy" Then


tbnhap.Text = "If No Answer"
Exit Sub
End If

'vao menu con cua muc Call Barring


If tbnhap.Text = "Change Bar Password" Then
tbnhap.Text = "Cancel All Barring"
Exit Sub
End If

If tbnhap.Text = "Cancel All Barring" Then


tbnhap.Text = "Bar Incoming Calls"
Exit Sub
End If

If tbnhap.Text = "Bar Incoming Calls" Then


tbnhap.Text = "Bar Outgoing Calls"
Exit Sub
End If

If tbnhap.Text = "Bar Outgoing Calls" Then


tbnhap.Text = "Change Bar Password"
Exit Sub
End If

'vao menu con cua muc Bar Outgoing Calls


If tbnhap.Text = "Off?" Then
tbnhap.Text = "All Calls"
Exit Sub
End If

If tbnhap.Text = "All Calls" Then


tbnhap.Text = "Int'l Calls Expect Home"

Trang 109
Exit Sub
End If

If tbnhap.Text = "Int'l Calls Expect Home" Then


tbnhap.Text = "Int'l Calls"
Exit Sub
End If

If tbnhap.Text = "Int'l Calls" Then


tbnhap.Text = "Off?"
Exit Sub
End If

'vao menu con cua muc Bar Incoming Call


If tbnhap.Text = "Off? " Then
tbnhap.Text = " All Calls"
Exit Sub
End If

If tbnhap.Text = " All Calls" Then


tbnhap.Text = "When Roaming"
Exit Sub
End If

If tbnhap.Text = "When Roaming" Then


tbnhap.Text = "Off? "
Exit Sub
End If

'phan xu ly cua menu Message


If tbnhap.Text = "Outgoing Messages" Then
tbnhap.Text = "Call Voicemail"
Exit Sub
End If

If tbnhap.Text = "Message Editor" Then


tbnhap.Text = "Outgoing Messages"
Exit Sub
End If

If tbnhap.Text = "Cell Broadcast" Then

Trang 110
Laäp Trình Web Vôùi Visual Basic

tbnhap.Text = "Message Editor"


Exit Sub
End If

If tbnhap.Text = "Message Settings" Then


tbnhap.Text = "Cell Broadcast"
Exit Sub
End If

If tbnhap.Text = "Call Voicemail" Then


tbnhap.Text = "Message Settings"
Exit Sub
End If

'vao menu con cua muc Outgoing Message


If tbnhap.Text = "Edit Message" Then
tbnhap.Text = "Send Message"
Exit Sub
End If

If tbnhap.Text = "Delete Message" Then


tbnhap.Text = "Edit Message"
Exit Sub
End If

If tbnhap.Text = "Go to Next Message" Then


tbnhap.Text = "Delete Message"
Exit Sub
End If

If tbnhap.Text = "Send Message" Then


tbnhap.Text = "Go to Next Message"
Exit Sub
End If

'vao menu con cua muc Edit Message


If tbnhap.Text = " Send Message" Then
tbnhap.Text = "Store Message"
Exit Sub
End If

Trang 111
If tbnhap.Text = "Store Message" Then
tbnhap.Text = " Send Message"
Exit Sub
End If

'vao menu con cua muc Send Message


If tbnhap.Text = " Find Entry by Location" Then
tbnhap.Text = " Find Entry by Name"
Exit Sub
End If

If tbnhap.Text = " Find Entry by Name" Then


tbnhap.Text = " Enter Number"
Exit Sub
End If

If tbnhap.Text = " Enter Number" Then


tbnhap.Text = " Find Entry by Location"
Exit Sub
End If

'vao menu con cua muc Message Setting


If tbnhap.Text = "Service Centre" Then
tbnhap.Text = "Voicemail Number"
Exit Sub
End If

If tbnhap.Text = "Expiry Period" Then


tbnhap.Text = "Service Centre"
Exit Sub
End If

If tbnhap.Text = "Outgoing Message Type" Then


tbnhap.Text = "Expiry Period"
Exit Sub
End If

If tbnhap.Text = "Voicemail Number" Then


tbnhap.Text = "Outgoing Message Type"
Exit Sub
End If

Trang 112
Laäp Trình Web Vôùi Visual Basic

'vao menu con cua muc Outgoing Message Type


If tbnhap.Text = "Fax" Then
tbnhap.Text = "Text"
Exit Sub
End If

If tbnhap.Text = "X400" Then


tbnhap.Text = "Fax"
Exit Sub
End If

If tbnhap.Text = "Paging" Then


tbnhap.Text = "X400"
Exit Sub
End If

If tbnhap.Text = "Email" Then


tbnhap.Text = "Paging"
Exit Sub
End If

If tbnhap.Text = "ERMES" Then


tbnhap.Text = "Email"
Exit Sub
End If

If tbnhap.Text = "Voice" Then


tbnhap.Text = "ERMES"
Exit Sub
End If

If tbnhap.Text = "Text" Then


tbnhap.Text = "Voice"
Exit Sub
End If

'phan xu ly khi dung phim menu de di chuyen giua nhung tin nhan
If messagelist = True Then
Open filename4 For Random As #1 Len = Len(message)
banghi = LOF(1) \ Len(message)

Trang 113
If messagenumber = 1 Then
Get #1, banghi, message
tbnhap.Text = Trim(message.tin)
messagenumber = banghi
Else
messagenumber = messagenumber - 1
Get #1, messagenumber, message
tbnhap.Text = Trim(message.tin)
End If
Close #1
Exit Sub
End If

'nhung muc con cua Phone Setup


If tbnhap.Text = "Adjust Ring Volume" Then
tbnhap.Text = "Select Phone Line"
Exit Sub
End If

If tbnhap.Text = "Ring or Vibrate" Then


tbnhap.Text = "Adjust Ring Volume"
Exit Sub
End If

If tbnhap.Text = "Set Ringer Tone" Then


tbnhap.Text = "Ring or Vibrate"
Exit Sub
End If

If tbnhap.Text = "Set Ringer Tone 2" Then


tbnhap.Text = "Set Ringer Tone"
Exit Sub
End If

If line2 = True Then


If tbnhap.Text = "Phone Lock" Then
tbnhap.Text = "Set Ringer Tone 2"
Exit Sub
End If
Else
If tbnhap.Text = "Phone Lock" Then

Trang 114
Laäp Trình Web Vôùi Visual Basic

tbnhap.Text = "Set Ringer Tone"


Exit Sub
End If
End If

If tbnhap.Text = "Change SIM PIN2 Code" Then


tbnhap.Text = "Phone Lock"
Exit Sub
End If

If tbnhap.Text = "New Security Code" Then


tbnhap.Text = "Change SIM PIN2 Code"
Exit Sub
End If

If tbnhap.Text = "Extended Menus" Then


tbnhap.Text = "New Security Code"
Exit Sub
End If

If extend = False Then


If tbnhap.Text = "Select Phone Line" Then
tbnhap.Text = "Extended Menus"
Exit Sub
End If
End If
'nhung menu mo rong khi extended menus o trang thai on
If extend = True Then
If tbnhap.Text = "Show Time and Date" Then
tbnhap.Text = "Extended Menus"
Exit Sub
End If

If tbnhap.Text = "Set Time and Date" Then


tbnhap.Text = "Show Time and Date"
Exit Sub
End If

If tbnhap.Text = "Set Time Format" Then


tbnhap.Text = "Set Time and Date"
Exit Sub

Trang 115
End If

If tbnhap.Text = "Battery Saving Mode" Then


tbnhap.Text = "Set Time Format"
Exit Sub
End If

If tbnhap.Text = "Select Keypad Tones" Then


tbnhap.Text = "Battery Saving Mode"
Exit Sub
End If

If tbnhap.Text = "Select Phone Line" Then


tbnhap.Text = "Select Keypad Tones"
Exit Sub
End If
End If

'vao menu con cua muc Select phone line


If tbnhap.Text = "Line 2" Then
tbnhap.Text = "Line 1"
Exit Sub
End If

If tbnhap.Text = "Line 1" Then


tbnhap.Text = "Line 2"
Exit Sub
End If

'vao menu con cua muc Ring or vibrate


If tbnhap.Text = "Vibrate Only" Then
tbnhap.Text = "Ring Only"
Exit Sub
End If

If tbnhap.Text = "Vibrate Then Ring" Then


tbnhap.Text = "Vibrate Only"
Exit Sub
End If

If tbnhap.Text = "No Ring or Vibrate" Then

Trang 116
Laäp Trình Web Vôùi Visual Basic

tbnhap.Text = "Vibrate Then Ring"


Exit Sub
End If

If tbnhap.Text = "Ring Only" Then


tbnhap.Text = "No Ring or Vibrate"
Exit Sub
End If

'vao menu con cua muc Set Ringer Tone


If tbnhap.Text = "Music Tone" Then
tbnhap.Text = "Standard Tone"
Exit Sub
End If

If tbnhap.Text = "Standard Tone" Then


tbnhap.Text = "Music Tone"
Exit Sub
End If

'vao menu con cua muc Phone Lock


If tbnhap.Text = "Lock Now" Then
tbnhap.Text = "Automatic Lock"
Exit Sub
End If

If tbnhap.Text = " Change Unlock Code" Then


tbnhap.Text = "Lock Now"
Exit Sub
End If

If tbnhap.Text = "Automatic Lock" Then


tbnhap.Text = " Change Unlock Code"
Exit Sub
End If

'vao menu con cua muc Automatic phone lock


If tbnhap.Text = " Off " Then
tbnhap.Text = " On "
Exit Sub
End If

Trang 117
If tbnhap.Text = " On " Then
tbnhap.Text = " Off "
Exit Sub
End If

'vao menu con cua muc Extended menus


If tbnhap.Text = " Off" Then
tbnhap.Text = " On"
Exit Sub
End If

If tbnhap.Text = " On" Then


tbnhap.Text = " Off"
Exit Sub
End If

'vao menu con cua muc Require SIM card pin


If tbnhap.Text = "Change SIM PIN Code" Then
tbnhap.Text = " Off."
Exit Sub
End If

If tbnhap.Text = " Off." Then


tbnhap.Text = " On."
Exit Sub
End If

If tbnhap.Text = " On." Then


tbnhap.Text = "Change SIM PIN Code"
Exit Sub
End If

'vao menu con cua muc Set time format


If tbnhap.Text = "24-hour?" Then
tbnhap.Text = "12-hour?"
Exit Sub
End If

If tbnhap.Text = "12-hour?" Then


tbnhap.Text = "24-hour?"

Trang 118
Laäp Trình Web Vôùi Visual Basic

Exit Sub
End If

'vao menu cua muc Select Keypad tone


If tbnhap.Text = "Single Tone" Then
tbnhap.Text = "Normal Tones"
Exit Sub
End If

If tbnhap.Text = "No Tones" Then


tbnhap.Text = "Single Tone"
Exit Sub
End If

If tbnhap.Text = "Normal Tones" Then


tbnhap.Text = "No Tones"
Exit Sub
End If

'vao menu con cua muc Phone Status


If tbnhap.Text = "Master Reset" Then
tbnhap.Text = "Status Review"
Exit Sub
End If

If tbnhap.Text = "Master Clear" Then


tbnhap.Text = "Master Reset"
Exit Sub
End If

If tbnhap.Text = "Status Review" Then


tbnhap.Text = "Master Clear"
Exit Sub
End If

'phan xu ly cua menu Network Selection


If tbnhap.Text = "Find New Network" Then
tbnhap.Text = "Preferred Networks"
Exit Sub
End If

Trang 119
If tbnhap.Text = "Preferred Networks" Then
tbnhap.Text = "Network Search"
Exit Sub
End If

If tbnhap.Text = "Network Search" Then


tbnhap.Text = "Available Networks"
Exit Sub
End If

If tbnhap.Text = "Available Networks" Then


tbnhap.Text = " Change Band"
Exit Sub
End If

If tbnhap.Text = " Change Band" Then


tbnhap.Text = "Find New Network"
Exit Sub
End If
'vao menu con cua Change Band
If tbnhap.Text = "Change to 1800" Then
tbnhap.Text = "Change to 900"
Exit Sub
End If

If tbnhap.Text = "Change to 900" Then


tbnhap.Text = "Change to 900/1800"
Exit Sub
End If

If tbnhap.Text = "Change to 900/1800" Then


tbnhap.Text = "Change to 1800"
Exit Sub
End If

'vao menu con cua muc Available Networks


If tbnhap.Text = "Register Now" Then
tbnhap.Text = "Make Preferred"
Exit Sub
End If

Trang 120
Laäp Trình Web Vôùi Visual Basic

If tbnhap.Text = "Make Preferred" Then


tbnhap.Text = "Register Now"
Exit Sub
End If

'vao menu con cua muc Network Search


If tbnhap.Text = "Registration Preferences" Then
tbnhap.Text = "Frequency of Search"
Exit Sub
End If

If tbnhap.Text = "Frequency of Search" Then


tbnhap.Text = "Registration Preferences"
Exit Sub
End If

'vao menu con cua muc "Registration Preferences


If tbnhap.Text = "Manual Search Mode" Then
tbnhap.Text = "Automatic Search Mode"
Exit Sub
End If

If tbnhap.Text = "Automatic Search Mode" Then


tbnhap.Text = "Manual Search Mode"
Exit Sub
End If

'vao menu con cua muc Frequency


If tbnhap.Text = "Continuous Search" Then
tbnhap.Text = "Fast Search"
Exit Sub
End If

If tbnhap.Text = "Fast Search" Then


tbnhap.Text = "Medium Search"
Exit Sub
End If

If tbnhap.Text = "Medium Search" Then


tbnhap.Text = "Slow Search"
Exit Sub

Trang 121
End If

If tbnhap.Text = "Slow Search" Then


tbnhap.Text = "Continuous Search"
Exit Sub
End If

'vao menu con cua muc Preferred networks


If tbnhap.Text = "Add Network to List" Then
tbnhap.Text = "Show List of Networks"
Exit Sub
End If

If tbnhap.Text = "Show List of Networks" Then


tbnhap.Text = "Add Network to List"
Exit Sub
End If

If tbnhap.Text = "Choose From Available" Then


tbnhap.Text = "Choose From Known"
Exit Sub
End If

If tbnhap.Text = "Choose From Known" Then


tbnhap.Text = "Choose From Available"
Exit Sub
End If

If tbnhap.Text = "Move to New Location" Then


tbnhap.Text = "Delete Network"
Exit Sub
End If

If tbnhap.Text = "Delete Network" Then


tbnhap.Text = "Move to New Location"
Exit Sub
End If

'phan xu ly cua menu Accessory Setup


If tbnhap.Text = "Auxiliary Alert" Then
tbnhap.Text = "Safety Timer"

Trang 122
Laäp Trình Web Vôùi Visual Basic

Exit Sub
End If

If tbnhap.Text = "Safety Timer" Then


tbnhap.Text = "Automatic Handsfree"
Exit Sub
End If

If tbnhap.Text = "Automatic Handsfree" Then


tbnhap.Text = "Automatic Answer"
Exit Sub
End If

If tbnhap.Text = "Automatic Answer" Then


tbnhap.Text = "Mute Car Radio"
Exit Sub
End If

If tbnhap.Text = "Mute Car Radio" Then


tbnhap.Text = "Auxiliary Alert"
Exit Sub
End If

If tbnhap.Text = "On" Then


tbnhap.Text = "Off"
Exit Sub
End If

If tbnhap.Text = "Off" Then


tbnhap.Text = "On"
Exit Sub
End If

'phan xu ly khi vao menu truy cap nhanh


If quickaccess = True Then
Open filename3 For Random As #1 Len = Len(menuaccess)
If orderinquick = 1 Then
orderinquick = 9
Get #1, 9, menuaccess
tbnhap.Text = Trim(menuaccess.feature)
luumuc = menuaccess.thutu

Trang 123
Close #1
Exit Sub
Else
orderinquick = orderinquick - 1
Get #1, orderinquick, menuaccess
tbnhap.Text = Trim(menuaccess.feature)
luumuc = menuaccess.thutu
Close #1
Exit Sub
End If
End If

'vao nhung tinh nang trong Quick Access khi nhan va giu phim OK
If longpress = True Then
quickaccess = False
showtime = False
If tbnhap.Text = "Find by Location" Then
tbnhap.Text = "Find by Name"
st = "Find Name?"
luumuc = 1
Exit Sub
End If

If tbnhap.Text = "Add Entry to Phone" Then


tbnhap.Text = "Find by Location"
st = "Find Location?"
luumuc = 2
Exit Sub
End If

If tbnhap.Text = "Add Entry to SIM" Then


tbnhap.Text = "Add Entry to Phone"
st = "Add to Phone?"
luumuc = 3
Exit Sub
End If

If tbnhap.Text = "Call VoiceMail" Then


tbnhap.Text = "Add Entry to SIM"
st = "Add to SIM?"
luumuc = 4

Trang 124
Laäp Trình Web Vôùi Visual Basic

Exit Sub
End If

If tbnhap.Text = "Battery Meter" Then


tbnhap.Text = "Call VoiceMail"
st = "Call Voicemail?"
luumuc = 12
Exit Sub
End If

If tbnhap.Text = "Phone Lock Now" Then


tbnhap.Text = "Battery Meter"
st = "Battery Meter?"
luumuc = 11
Exit Sub
End If

If tbnhap.Text = "Ring Volume" Then


tbnhap.Text = "Phone Lock Now"
st = "Lock Now?"
luumuc = 5
Exit Sub
End If

If tbnhap.Text = "VibraCall On or Off" Then


tbnhap.Text = "Ring Volume"
st = "Adjust Ring?"
luumuc = 6
Exit Sub
End If

If tbnhap.Text = " Outgoing Messages" Then


tbnhap.Text = "VibraCall On or Off"
st = "Vibrate On/Off?"
luumuc = 9
Exit Sub
End If

If tbnhap.Text = " Message Editor" Then


tbnhap.Text = " Outgoing Messages"
st = "Outgoing SMS?"

Trang 125
luumuc = 14
Exit Sub
End If

If tbnhap.Text = "Switch Line 1/2" Then


tbnhap.Text = " Message Editor"
st = "Message Editor?"
luumuc = 15
Exit Sub
End If

If tbnhap.Text = "Change Band" Then


tbnhap.Text = "Switch Line 1/2"
st = "Switch Line 1/2?"
luumuc = 7
Exit Sub
End If

If tbnhap.Text = " Show Time and Date" Then


tbnhap.Text = "Change Band"
st = "Change Band?"
luumuc = 10
Exit Sub
End If

If tbnhap.Text = "Find by Name" Then


tbnhap.Text = " Show Time and Date"
st = "Show Time/Date?"
luumuc = 8
Exit Sub
End If
End If

'phan xu ly khi dung phim menu de di chuyen giua cac muc con
If found = True Then
Call menu_upswitchentry
End If

'khi dung phim menu de di chuyen giua nhung muc trong Fixed Dial
If listdial = True Then

Trang 126
Laäp Trình Web Vôùi Visual Basic

Call menu_uplistdial
End If

'xu ly khi dung phim menu de di chuyen giua cac mang


If availablenetwork = True Or addnetwork = True Then
tam1 = tam1 - 1
Open filename5 For Random As #1 Len = Len(networks)
banghi = LOF(1) \ Len(networks)
If tam1 >= 1 Then
Get #1, tam1, networks
tbnhap.Text = networks.mang
st = networks.mang
Close #1
Else
tam1 = banghi
Get #1, banghi, networks
tbnhap.Text = networks.mang
st = networks.mang
Close #1
End If
Exit Sub
End If

'xu ly cua muc Preferred network


If showlist = True Then
Open filename6 For Random As #1 Len = Len(networks)
banghi = LOF(1) \ Len(networks)
tam1 = tam1 - 1
If tam1 >= 1 Then
Get #1, tam1, networks
tbnhap.Text = networks.mang
st = networks.mang
Else
tam1 = banghi
Get #1, banghi, networks
tbnhap.Text = networks.mang
st = networks.mang
End If
Close #1
Exit Sub
End If

Trang 127
'********** phim menu-down ************
Case 12
If tbnhap.Text = "Menu" Then
tbnhap.Text = "Phone Book"
cancle = True
danhso = False
Exit Sub
End If

If tbnhap.Text = "Phone Book" Then


tbnhap.Text = "Call Related Features"
Exit Sub
End If

If tbnhap.Text = "Call Related Features" Then


tbnhap.Text = "Messages"
Exit Sub
End If

If tbnhap.Text = "Messages" Then


tbnhap.Text = "Phone Setup"
Exit Sub
End If

If tbnhap.Text = "Phone Setup" Then


tbnhap.Text = "Network Selection"
Exit Sub
End If

If tbnhap.Text = "Network Selection" Then


tbnhap.Text = "Accessory Setup"
Exit Sub
End If

If tbnhap.Text = "Accessory Setup" Then


tbnhap.Text = "Phone Book"
Exit Sub
End If

'vao menu con cua muc Phone Book


If tbnhap.Text = "Personal Number" Then

Trang 128
Laäp Trình Web Vôùi Visual Basic

tbnhap.Text = "Fixed Dialling"


Exit Sub
End If

If tbnhap.Text = "Fixed Dialling" Then


tbnhap.Text = "One-Touch Dial Setting"
Exit Sub
End If

If tbnhap.Text = "One-Touch Dial Setting" Then


tbnhap.Text = "Personal Number"
Exit Sub
End If

'vao menu con cua muc Personal Number


If tbnhap.Text = "Find Entry by Name" Then
tbnhap.Text = "Find Entry by Location"
Exit Sub
End If

If tbnhap.Text = "Find Entry by Location" Then


tbnhap.Text = "Add Entry"
flag = False
found = False
Exit Sub
End If

If tbnhap.Text = "Add Entry" Then


tbnhap.Text = "Check Capacity"
Exit Sub
End If

If tbnhap.Text = "Check Capacity" Then


tbnhap.Text = "Prevent Access"
Exit Sub
End If

If tbnhap.Text = "Prevent Access" Then


tbnhap.Text = "Find Entry by Name"
Exit Sub
End If

Trang 129
'vao menu con cua muc Prevent Access
If tbnhap.Text = "No Memory Restrictions" Then
tbnhap.Text = "To SIM Card Memory"
Exit Sub
End If

If tbnhap.Text = "To SIM Card Memory" Then


tbnhap.Text = "To Phone Memory"
Exit Sub
End If

If tbnhap.Text = "To Phone Memory" Then


tbnhap.Text = "To Phone & SIM Memory"
Exit Sub
End If

If tbnhap.Text = "To Phone & SIM Memory" Then


tbnhap.Text = "No Memory Restrictions"
Exit Sub
End If

'vao menu con cua muc Add Entry


If tbnhap.Text = "Add To Phone Memory" Then
tbnhap.Text = "Add To SIM Card Memory"
Exit Sub
End If

If tbnhap.Text = "Add To SIM Card Memory" Then


tbnhap.Text = "Add To Phone Memory"
Exit Sub
End If

'vao menu con cua muc Check Capacity


If tbnhap.Text = "Check Phone Capacity" Then
tbnhap.Text = "Check SIM Capacity"
Exit Sub
End If

If tbnhap.Text = "Check SIM Capacity" Then


tbnhap.Text = "Check Phone Capacity"

Trang 130
Laäp Trình Web Vôùi Visual Basic

Exit Sub
End If

'vao menu con cua muc Find Entry


If tbnhap.Text = "Call Number" Then
tbnhap.Text = "Modify Name or Number"
Exit Sub
End If

If tbnhap.Text = "Modify Name or Number" Then


tbnhap.Text = "Erase Name and Number"
Exit Sub
End If

If tbnhap.Text = "Erase Name and Number" Then


tbnhap.Text = "Call Number"
Exit Sub
End If

'phan xu ly khi vao menu One-Touch Dial Setting


If tbnhap.Text = " To SIM Memory" Then
tbnhap.Text = " To Fixed Dial List"
Exit Sub
End If

If tbnhap.Text = " To Phone Memory" Then


tbnhap.Text = " To SIM Memory"
Exit Sub
End If

If tbnhap.Text = " To Fixed Dial List" Then


tbnhap.Text = " To Phone Memory"
Exit Sub
End If

'xu ly cua muc Fixed Dialling


If tbnhap.Text = "View Fixed Dial List" Then
tbnhap.Text = "Setup Fixed Dialling"
Exit Sub
End If

Trang 131
If tbnhap.Text = "Setup Fixed Dialling" Then
tbnhap.Text = "View Fixed Dial List"
Exit Sub
End If

'xu ly trong muc Setup Fixed Dialling


If tbnhap.Text = "On." Then
tbnhap.Text = "Off."
Exit Sub
End If

If tbnhap.Text = "Off." Then


tbnhap.Text = "Edit Entry"
Exit Sub
End If

If tbnhap.Text = " Add Entry" Then


tbnhap.Text = "Erase Entry"
Exit Sub
End If

If tbnhap.Text = "Edit Entry" Then


tbnhap.Text = " Add Entry"
Exit Sub
End If

If tbnhap.Text = "Erase Entry" Then


tbnhap.Text = "On."
Exit Sub
End If

'phan xu ly cua menu Call Related features


If tbnhap.Text = "Call Barring" Then
tbnhap.Text = "Key Answer Only"
Exit Sub
End If

If tbnhap.Text = "Call Waiting" Then


tbnhap.Text = "Call Barring"
Exit Sub
End If

Trang 132
Laäp Trình Web Vôùi Visual Basic

If tbnhap.Text = "Talk and Fax" Then


tbnhap.Text = "Call Waiting"
Exit Sub
End If

If tbnhap.Text = "Call Diverting" Then


tbnhap.Text = "Talk and Fax"
Exit Sub
End If

If tbnhap.Text = "Restrict My Phone Number" Then


tbnhap.Text = "Call Diverting"
Exit Sub
End If

If tbnhap.Text = "Show Battery Meter" Then


tbnhap.Text = "Restrict My Phone Number"
Exit Sub
End If

If tbnhap.Text = "Key Answer Only" Then


tbnhap.Text = "Show Battery Meter"
Exit Sub
End If

'vao menu con cua muc Restrict My Phone Number


If tbnhap.Text = "Show ID On Next Call" Then
tbnhap.Text = "Restrict ID On Next Call"
Exit Sub
End If

If tbnhap.Text = "Restrict ID On Next Call" Then


tbnhap.Text = "Show ID On Next Call"
Exit Sub
End If

'vao menu con cua muc Call Diverting


If tbnhap.Text = "Cancel All Diverting" Then
tbnhap.Text = "Divert Voice Calls"
Exit Sub

Trang 133
End If

If tbnhap.Text = "Divert Data Calls" Then


tbnhap.Text = "Cancel All Diverting"
Exit Sub
End If

If tbnhap.Text = "Divert Fax Calls" Then


tbnhap.Text = "Divert Data Calls"
Exit Sub
End If

If tbnhap.Text = "Divert Voice Calls" Then


tbnhap.Text = "Divert Fax Calls"
Exit Sub
End If

'vao menu con cua muc Divert Voice Calls


If tbnhap.Text = "Detailed Diverting" Then
tbnhap.Text = "Divert When Unavailable"
Exit Sub
End If

If tbnhap.Text = "Divert All Voice Calls" Then


tbnhap.Text = "Detailed Diverting"
Exit Sub
End If

If tbnhap.Text = "Divert When Unavailable" Then


tbnhap.Text = "Divert All Voice Calls"
Exit Sub
End If

'vao menu con cua muc Detailed Diverting


If tbnhap.Text = "If Not Reachable" Then
tbnhap.Text = "If No Answer"
Exit Sub
End If

If tbnhap.Text = "If Busy" Then


tbnhap.Text = "If Not Reachable"

Trang 134
Laäp Trình Web Vôùi Visual Basic

Exit Sub
End If

If tbnhap.Text = "If No Answer" Then


tbnhap.Text = "If Busy"
Exit Sub
End If

'vao menu con cua muc Call Barring


If tbnhap.Text = "Bar Incoming Calls" Then
tbnhap.Text = "Cancel All Barring"
Exit Sub
End If

If tbnhap.Text = "Bar Outgoing Calls" Then


tbnhap.Text = "Bar Incoming Calls"
Exit Sub
End If

If tbnhap.Text = "Cancel All Barring" Then


tbnhap.Text = "Change Bar Password"
Exit Sub
End If

If tbnhap.Text = "Change Bar Password" Then


tbnhap.Text = "Bar Outgoing Calls"
Exit Sub
End If

'vao menu con cua muc Bar Outgoing Calls


If tbnhap.Text = "All Calls" Then
tbnhap.Text = "Off?"
Exit Sub
End If

If tbnhap.Text = "Int'l Calls Expect Home" Then


tbnhap.Text = "All Calls"
Exit Sub
End If

If tbnhap.Text = "Int'l Calls" Then

Trang 135
tbnhap.Text = "Int'l Calls Expect Home"
Exit Sub
End If

If tbnhap.Text = "Off?" Then


tbnhap.Text = "Int'l Calls"
Exit Sub
End If

'vao menu con cua muc Bar Incoming Call


If tbnhap.Text = " All Calls" Then
tbnhap.Text = "Off? "
Exit Sub
End If

If tbnhap.Text = "When Roaming" Then


tbnhap.Text = " All Calls"
Exit Sub
End If

If tbnhap.Text = "Off? " Then


tbnhap.Text = "When Roaming"
Exit Sub
End If

'phan xu ly cua menu Message


If tbnhap.Text = "Call Voicemail" Then
tbnhap.Text = "Outgoing Messages"
Exit Sub
End If

If tbnhap.Text = "Outgoing Messages" Then


tbnhap.Text = "Message Editor"
Exit Sub
End If

If tbnhap.Text = "Message Editor" Then


tbnhap.Text = "Cell Broadcast"
Exit Sub
End If

Trang 136
Laäp Trình Web Vôùi Visual Basic

If tbnhap.Text = "Cell Broadcast" Then


tbnhap.Text = "Message Settings"
Exit Sub
End If

If tbnhap.Text = "Message Settings" Then


tbnhap.Text = "Call Voicemail"
Exit Sub
End If

'vao menu con cua muc Outgoing Message


If tbnhap.Text = "Send Message" Then
tbnhap.Text = "Edit Message"
Exit Sub
End If

If tbnhap.Text = "Edit Message" Then


tbnhap.Text = "Delete Message"
Exit Sub
End If

If tbnhap.Text = "Delete Message" Then


tbnhap.Text = "Go to Next Message"
Exit Sub
End If

If tbnhap.Text = "Go to Next Message" Then


tbnhap.Text = "Send Message"
Exit Sub
End If

'vao menu con cua muc Edit Message


If tbnhap.Text = " Send Message" Then
tbnhap.Text = "Store Message"
Exit Sub
End If

If tbnhap.Text = "Store Message" Then


tbnhap.Text = " Send Message"
Exit Sub
End If

Trang 137
'vao menu con cua muc Send Message
If tbnhap.Text = " Enter Number" Then
tbnhap.Text = " Find Entry by Name"
Exit Sub
End If

If tbnhap.Text = " Find Entry by Name" Then


tbnhap.Text = " Find Entry by Location"
Exit Sub
End If

If tbnhap.Text = " Find Entry by Location" Then


tbnhap.Text = " Enter Number"
Exit Sub
End If

'vao menu con cua muc Message Setting


If tbnhap.Text = "Voicemail Number" Then
tbnhap.Text = "Service Centre"
Exit Sub
End If

If tbnhap.Text = "Service Centre" Then


tbnhap.Text = "Expiry Period"
Exit Sub
End If

If tbnhap.Text = "Expiry Period" Then


tbnhap.Text = "Outgoing Message Type"
Exit Sub
End If

If tbnhap.Text = "Outgoing Message Type" Then


tbnhap.Text = "Voicemail Number"
Exit Sub
End If

'vao menu con cua muc Outgoing Message Type


If tbnhap.Text = "Text" Then
tbnhap.Text = "Fax"

Trang 138
Laäp Trình Web Vôùi Visual Basic

Exit Sub
End If

If tbnhap.Text = "Fax" Then


tbnhap.Text = "X400"
Exit Sub
End If

If tbnhap.Text = "X400" Then


tbnhap.Text = "Paging"
Exit Sub
End If

If tbnhap.Text = "Paging" Then


tbnhap.Text = "Email"
Exit Sub
End If

If tbnhap.Text = "Email" Then


tbnhap.Text = "ERMES"
Exit Sub
End If

If tbnhap.Text = "ERMES" Then


tbnhap.Text = "Voice"
Exit Sub
End If

If tbnhap.Text = "Voice" Then


tbnhap.Text = "Text"
Exit Sub
End If

'khi dung phim menu de di chuyen giua cac tin nhan


If messagelist = True Then
Open filename4 For Random As #1 Len = Len(message)
banghi = LOF(1) \ Len(message)
If messagenumber = banghi Then
Get #1, 1, message
tbnhap.Text = Trim(message.tin)
messagenumber = 1

Trang 139
Else
messagenumber = messagenumber + 1
Get #1, messagenumber, message
tbnhap.Text = Trim(message.tin)
End If
Close #1
Exit Sub
End If

'nhung muc con cua Phone Setup


If tbnhap.Text = "Select Phone Line" Then
tbnhap.Text = "Adjust Ring Volume"
Exit Sub
End If

If tbnhap.Text = "Adjust Ring Volume" Then


tbnhap.Text = "Ring or Vibrate"
Exit Sub
End If

If tbnhap.Text = "Ring or Vibrate" Then


tbnhap.Text = "Set Ringer Tone"
Exit Sub
End If

If line2 = True Then


If tbnhap.Text = "Set Ringer Tone" Then
tbnhap.Text = "Set Ringer Tone 2"
Exit Sub
End If
Else
If tbnhap.Text = "Set Ringer Tone" Then
tbnhap.Text = "Phone Lock"
Exit Sub
End If
End If

If tbnhap.Text = "Set Ringer Tone 2" Then


tbnhap.Text = "Phone Lock"
Exit Sub
End If

Trang 140
Laäp Trình Web Vôùi Visual Basic

If tbnhap.Text = "Phone Lock" Then


tbnhap.Text = "Change SIM PIN2 Code"
Exit Sub
End If

If tbnhap.Text = "Change SIM PIN2 Code" Then


tbnhap.Text = "New Security Code"
Exit Sub
End If

If tbnhap.Text = "New Security Code" Then


tbnhap.Text = "Extended Menus"
Exit Sub
End If

'nhung menu mo rong khi extended menus o trang thai on


If extend = True Then
If tbnhap.Text = "Extended Menus" Then
tbnhap.Text = "Show Time and Date"
Exit Sub
End If

If tbnhap.Text = "Show Time and Date" Then


tbnhap.Text = "Set Time and Date"
Exit Sub
End If

If tbnhap.Text = "Set Time and Date" Then


tbnhap.Text = "Set Time Format"
Exit Sub
End If

If tbnhap.Text = "Set Time Format" Then


tbnhap.Text = "Battery Saving Mode"
Exit Sub
End If

If tbnhap.Text = "Battery Saving Mode" Then


tbnhap.Text = "Select Keypad Tones"
Exit Sub

Trang 141
End If

If tbnhap.Text = "Select Keypad Tones" Then


tbnhap.Text = "Select Phone Line"
Exit Sub
End If
Else
If tbnhap.Text = "Extended Menus" Then
tbnhap.Text = "Select Phone Line"
Exit Sub
End If
End If

'vao menu con cua muc Select phone line


If tbnhap.Text = "Line 1" Then
tbnhap.Text = "Line 2"
Exit Sub
End If

If tbnhap.Text = "Line 2" Then


tbnhap.Text = "Line 1"
Exit Sub
End If

'vao menu con cua muc Ring or vibrate


If tbnhap.Text = "Ring Only" Then
tbnhap.Text = "Vibrate Only"
Exit Sub
End If

If tbnhap.Text = "Vibrate Only" Then


tbnhap.Text = "Vibrate Then Ring"
Exit Sub
End If

If tbnhap.Text = "Vibrate Then Ring" Then


tbnhap.Text = "No Ring or Vibrate"
Exit Sub
End If

If tbnhap.Text = "No Ring or Vibrate" Then

Trang 142
Laäp Trình Web Vôùi Visual Basic

tbnhap.Text = "Ring Only"


Exit Sub
End If

'vao menu con cua muc Set Ringer Tone


If tbnhap.Text = "Standard Tone" Then
tbnhap.Text = "Music Tone"
Exit Sub
End If

If tbnhap.Text = "Music Tone" Then


tbnhap.Text = "Standard Tone"
Exit Sub
End If

'vao menu con cua muc Phone Lock


If tbnhap.Text = "Automatic Lock" Then
tbnhap.Text = "Lock Now"
Exit Sub
End If

If tbnhap.Text = "Lock Now" Then


tbnhap.Text = " Change Unlock Code"
Exit Sub
End If

If tbnhap.Text = " Change Unlock Code" Then


tbnhap.Text = "Automatic Lock"
Exit Sub
End If

'vao menu con cua muc Extended menus


If tbnhap.Text = " On" Then
tbnhap.Text = " Off"
Exit Sub
End If

If tbnhap.Text = " Off" Then


tbnhap.Text = " On"
Exit Sub
End If

Trang 143
If tbnhap.Text = " On " Then
tbnhap.Text = " Off "
Exit Sub
End If

If tbnhap.Text = " Off " Then


tbnhap.Text = " On "
Exit Sub
End If

'vao menu con cua muc Require SIM card pin


If tbnhap.Text = " On." Then
tbnhap.Text = " Off."
Exit Sub
End If

If tbnhap.Text = " Off." Then


tbnhap.Text = "Change SIM PIN Code"
Exit Sub
End If

If tbnhap.Text = "Change SIM PIN Code" Then


tbnhap.Text = " On."
Exit Sub
End If

'vao menu con cua muc Set time format


If tbnhap.Text = "12-hour?" Then
tbnhap.Text = "24-hour?"
Exit Sub
End If

If tbnhap.Text = "24-hour?" Then


tbnhap.Text = "12-hour?"
Exit Sub
End If

'vao menu cua muc Select Keypad tone


If tbnhap.Text = "Normal Tones" Then

Trang 144
Laäp Trình Web Vôùi Visual Basic

tbnhap.Text = "Single Tone"


Exit Sub
End If

If tbnhap.Text = "Single Tone" Then


tbnhap.Text = "No Tones"
Exit Sub
End If

If tbnhap.Text = "No Tones" Then


tbnhap.Text = "Normal Tones"
Exit Sub
End If

'vao menu con cua muc Phone Status


If tbnhap.Text = "Status Review" Then
tbnhap.Text = "Master Reset"
Exit Sub
End If

If tbnhap.Text = "Master Reset" Then


tbnhap.Text = "Master Clear"
Exit Sub
End If

If tbnhap.Text = "Master Clear" Then


tbnhap.Text = "Status Review"
Exit Sub
End If

'phan xu ly cua menu Network Selection


If tbnhap.Text = " Change Band" Then
tbnhap.Text = "Available Networks"
Exit Sub
End If

If tbnhap.Text = "Available Networks" Then


tbnhap.Text = "Network Search"
Exit Sub
End If

Trang 145
If tbnhap.Text = "Network Search" Then
tbnhap.Text = "Preferred Networks"
Exit Sub
End If

If tbnhap.Text = "Preferred Networks" Then


tbnhap.Text = "Find New Network"
Exit Sub
End If

If tbnhap.Text = "Find New Network" Then


tbnhap.Text = " Change Band"
Exit Sub
End If

'vao menu con cua Change Band


If tbnhap.Text = "Change to 900" Then
tbnhap.Text = "Change to 1800"
Exit Sub
End If

If tbnhap.Text = "Change to 900/1800" Then


tbnhap.Text = "Change to 900"
Exit Sub
End If

If tbnhap.Text = "Change to 1800" Then


tbnhap.Text = "Change to 900/1800"
Exit Sub
End If

'vao menu con cua muc Available Networks


If tbnhap.Text = "Register Now" Then
tbnhap.Text = "Make Preferred"
Exit Sub
End If

If tbnhap.Text = "Make Preferred" Then


tbnhap.Text = "Register Now"
Exit Sub
End If

Trang 146
Laäp Trình Web Vôùi Visual Basic

'vao menu con cua muc Network Search


If tbnhap.Text = "Registration Preferences" Then
tbnhap.Text = "Frequency of Search"
Exit Sub
End If

If tbnhap.Text = "Frequency of Search" Then


tbnhap.Text = "Registration Preferences"
Exit Sub
End If

'vao menu con cua muc "Registration Preferences


If tbnhap.Text = "Manual Search Mode" Then
tbnhap.Text = "Automatic Search Mode"
Exit Sub
End If

If tbnhap.Text = "Automatic Search Mode" Then


tbnhap.Text = "Manual Search Mode"
Exit Sub
End If

'vao menu con cua muc Frequency


If tbnhap.Text = "Fast Search" Then
tbnhap.Text = "Continuous Search"
Exit Sub
End If

If tbnhap.Text = "Medium Search" Then


tbnhap.Text = "Fast Search"
Exit Sub
End If

If tbnhap.Text = "Slow Search" Then


tbnhap.Text = "Medium Search"
Exit Sub
End If

If tbnhap.Text = "Continuous Search" Then


tbnhap.Text = "Slow Search"

Trang 147
Exit Sub
End If

'vao menu con cua muc Preferred networks


If tbnhap.Text = "Add Network to List" Then
tbnhap.Text = "Show List of Networks"
Exit Sub
End If

If tbnhap.Text = "Show List of Networks" Then


tbnhap.Text = "Add Network to List"
Exit Sub
End If

If tbnhap.Text = "Choose From Available" Then


tbnhap.Text = "Choose From Known"
Exit Sub
End If

If tbnhap.Text = "Choose From Known" Then


tbnhap.Text = "Choose From Available"
Exit Sub
End If

If tbnhap.Text = "Move to New Location" Then


tbnhap.Text = "Delete Network"
Exit Sub
End If

If tbnhap.Text = "Delete Network" Then


tbnhap.Text = "Move to New Location"
Exit Sub
End If
'phan xu ly cua menu Accessory setup
If tbnhap.Text = "Mute Car Radio" Then
tbnhap.Text = "Automatic Answer"
Exit Sub
End If

If tbnhap.Text = "Automatic Answer" Then


tbnhap.Text = "Automatic Handsfree"

Trang 148
Laäp Trình Web Vôùi Visual Basic

Exit Sub
End If

If tbnhap.Text = "Automatic Handsfree" Then


tbnhap.Text = "Safety Timer"
Exit Sub
End If

If tbnhap.Text = "Safety Timer" Then


tbnhap.Text = "Auxiliary Alert"
Exit Sub
End If

If tbnhap.Text = "Auxiliary Alert" Then


tbnhap.Text = "Mute Car Radio"
Exit Sub
End If

If tbnhap.Text = "On" Then


tbnhap.Text = "Off"
Exit Sub
End If

If tbnhap.Text = "Off" Then


tbnhap.Text = "On"
Exit Sub
End If

'phan xu ly khi vao menu truy cap nhanh


If quickaccess = True Then
Open filename3 For Random As #1 Len = Len(menuaccess)
orderinquick = orderinquick + 1
Get #1, orderinquick, menuaccess
tbnhap.Text = Trim(menuaccess.feature)
luumuc = menuaccess.thutu
If orderinquick > 9 Then 'Else
orderinquick = 1
Get #1, 1, menuaccess
tbnhap.Text = Trim(menuaccess.feature)
luumuc = menuaccess.thutu
Close #1

Trang 149
Exit Sub
End If
Close #1
End If

'menu Quick Access


If tbnhap.Text = "Find by Name" Then
quickaccess = False
tbnhap.Text = "Find by Location"
st = "Find Location?"
luumuc = 2
Exit Sub
End If

If tbnhap.Text = "Find by Location" Then


tbnhap.Text = "Add Entry to Phone"
st = "Add to Phone?"
luumuc = 3
Exit Sub
End If

If tbnhap.Text = "Add Entry to Phone" Then


tbnhap.Text = "Add Entry to SIM"
st = "Add to SIM?"
luumuc = 4
Exit Sub
End If

If tbnhap.Text = "Add Entry to SIM" Then


tbnhap.Text = "Call VoiceMail"
st = "Call Voicemail?"
luumuc = 12
Exit Sub
End If

If tbnhap.Text = "Call VoiceMail" Then


tbnhap.Text = "Battery Meter"
st = "Battery Meter?"
luumuc = 11
Exit Sub
End If

Trang 150
Laäp Trình Web Vôùi Visual Basic

If tbnhap.Text = "Battery Meter" Then


tbnhap.Text = "Phone Lock Now"
st = "Lock Now?"
luumuc = 5
Exit Sub
End If

If tbnhap.Text = "Phone Lock Now" Then


tbnhap.Text = "Ring Volume"
st = "Adjust Ring?"
luumuc = 6
Exit Sub
End If

If tbnhap.Text = "Ring Volume" Then


tbnhap.Text = "VibraCall On or Off"
st = "Vibrate On/Off?"
luumuc = 9
Exit Sub
End If

If tbnhap.Text = "VibraCall On or Off" Then


tbnhap.Text = " Outgoing Messages"
st = "Outgoing SMS?"
luumuc = 14
Exit Sub
End If

If tbnhap.Text = " Outgoing Messages" Then


tbnhap.Text = " Message Editor"
st = "Message Editor?"
luumuc = 15
Exit Sub
End If

If tbnhap.Text = " Message Editor" Then


tbnhap.Text = "Switch Line 1/2"
st = "Switch Line 1/2?"
luumuc = 7
Exit Sub

Trang 151
End If

If tbnhap.Text = "Switch Line 1/2" Then


tbnhap.Text = "Change Band"
st = "Change Band?"
luumuc = 10
Exit Sub
End If

If tbnhap.Text = "Change Band" Then


tbnhap.Text = " Show Time and Date"
st = "Show Time/Date?"
luumuc = 8
Exit Sub
End If

If tbnhap.Text = " Show Time and Date" Then


tbnhap.Text = "Find by Name"
st = "Find Name?"
luumuc = 1
Exit Sub
End If

'xu ly khi bam phim menu de di chuyen giua nhung entry


If found = True Then
Call menu_downswitchentry
End If

'khi dung phim menu de di chuyen giua nhung muc trong Fixed Dial
If listdial = True Then
Call menu_downlistdial
End If

'xu ly khi dung phim menu de di chuyen giua cac mang


If availablenetwork = True Or addnetwork = True Then
tam1 = tam1 + 1
Open filename5 For Random As #1 Len = Len(networks)
banghi = LOF(1) \ Len(networks)
If tam1 <= banghi Then
Get #1, tam1, networks
tbnhap.Text = networks.mang

Trang 152
Laäp Trình Web Vôùi Visual Basic

st = networks.mang
Close #1
Else
tam1 = 1
Get #1, 1, networks
tbnhap.Text = networks.mang
st = networks.mang
Close #1
End If
Exit Sub
End If

'khi dung phim menu de di chuyen trong danh sach preferred network
If showlist = True Then
Open filename6 For Random As #1 Len = Len(networks)
banghi = LOF(1) \ Len(networks)
tam1 = tam1 + 1
If tam1 <= banghi Then
Get #1, tam1, networks
tbnhap.Text = networks.mang
st = networks.mang
Else
tam1 = 1
Get #1, 1, networks
tbnhap.Text = networks.mang
st = networks.mang
End If
Close #1
Exit Sub
End If

'************ Day la phim OK *************


Case 13
'***** Personal Number *********
If tbnhap.Text = "Phone Book" Then
tbnhap.Text = "Personal Number"
phonebook = True
Exit Sub
End If

'*****Find Entry by Name******

Trang 153
If tbnhap.Text = "Personal Number" Then
tbnhap.Text = "Find Entry by Name"
Exit Sub
End If

If tbnhap.Text = "Find Entry by Name" Or tbnhap.Text = " Find Entry by Name"


Or (luumuc = 1 And quickaccess = True) Then 'longpress = False) Then
If tbnhap.Text = " Find Entry by Name" Then
send = True 'phonebook = False
End If
quickaccess = False
tbnhap.Text = "Name" & vbCrLf
cancle = False
danhso = False
changecase = True
luumuc = 0
phonebook = False
Exit Sub
End If

'***** Tim theo ten ********


If Left(tbnhap.Text, 4) = "Name" Then
k = InStr(tbnhap.Text, vbLf)
st = Mid(tbnhap.Text, k + 1)
Call find_name(st)
If send = True Then 'phonebook = False Then
sending = True
send = False
End If
cancle = True
danhso = False
changecase = False
Exit Sub
End If

'*******Tim theo vi tri *******


If tbnhap.Text = "Find Entry by Location" Or tbnhap.Text = " Find Entry by
Location" Or (luumuc = 2 And quickaccess = True) Then 'longpress = False) Then
If tbnhap.Text = " Find Entry by Location" Then
send = True 'phonebook = False
End If

Trang 154
Laäp Trình Web Vôùi Visual Basic

quickaccess = False
tbnhap.Text = " Enter Location" & vbCrLf
cancle = True 'False
danhso = True 'False
luumuc = 0
phonebook = False
Exit Sub
End If

If Left(tbnhap.Text, Len(" Enter Location")) = " Enter Location" Then


k = InStr(tbnhap.Text, vbLf)
If Mid(tbnhap.Text, k + 1) = "" Then
lo = 0
Else
lo = Val(Mid(tbnhap.Text, k + 1))
If lo < 1 Or lo > 255 Then
tbnhap.Text = " Range 1-255"
danhso = False
Exit Sub
End If
End If
Call find_location(lo)
If send = True Then 'phonebook = False Then
sending = True
send = False
End If
cancle = True
danhso = False
Exit Sub
End If

'********* vao menu con cua Find ********


If (flag = True Or menucon = True) Then 'And phonebook = True Then
k = InStr(tbnhap.Text, vbLf)
st = Trim(Mid(tbnhap.Text, k + 1))
flag = False
menucon = False
found = False
tbnhap.Text = "Call Number"
cancle = True
danhso = False

Trang 155
phonebook = True 'False
Exit Sub
End If

'******** Xu ly cua muc Call Number **************


If tbnhap.Text = "Call Number" Or tbnhap.Text = " Call Number" Or tbnhap.Text
= "Call Number?" Then
If callbarring = True Then
tbnhap.Text = " Restricted"
Exit Sub
End If
If setupfixed = True Then
Open filefixed For Random As #1 Len = Len(news)
banghi = LOF(1) \ Len(news)
For j = 1 To banghi
Get #1, j, news
chuoitam = Trim(news.number)
If Trim(Mid(st, 1, Len(chuoitam))) = chuoitam Then
timthay = True
Exit For
End If
Next j
Close #1
If timthay = True Then
Image2.Visible = True
tbnhap.Text = "Calling"
danhso = False
cancle = True
Timer1.Interval = 3000
callnumber = False
phonebook = False
timthay = False
Else
tbnhap.Text = " Restricted"
Exit Sub
End If
Else
Image2.Visible = True
tbnhap.Text = "Calling"
danhso = False
cancle = True

Trang 156
Laäp Trình Web Vôùi Visual Basic

Timer1.Interval = 3000
callnumber = False
phonebook = False
End If
End If

If tbnhap.Text = "End Call?" Then


tbnhap.Text = "Menu"
danhso = True
Image2.Visible = False
Exit Sub
End If

If tbnhap.Text = " Restricted" Then


tbnhap.Text = "Phone Book"
Exit Sub
End If

'******** Xu ly cua muc Modify Name ************


If tbnhap.Text = "Modify Name or Number" Then
phonebook = False
tbnhap.Text = "Change Name" & vbCrLf
'longpress = True
cancle = False
danhso = False
changecase = True
found = False
flag = False
menucon = False
Close #1
Exit Sub
End If

If Left(tbnhap.Text, 11) = "Change Name" Then


k = InStr(tbnhap.Text, vbLf)
st = Trim(Mid(tbnhap.Text, k + 1))
tbnhap.Text = "Number Change" & vbCrLf
cancle = True 'False
danhso = True 'False
changecase = False
Exit Sub

Trang 157
End If

If Left(tbnhap.Text, Len("Number Change")) = "Number Change" Then


k = InStr(tbnhap.Text, vbLf)
nu = Mid(tbnhap.Text, k + 1)
If editentrylist = True Then
Call modify(st, nu, vitri)
Else
If prevent = 2 Or prevent = 3 Then
Open filename For Random As #1 Len = Len(news)
banghi = LOF(1) \ Len(news)
For j = 1 To banghi
Get #1, j, news
If st1 = news.name Then
vitri = j
Exit For
End If
Next j
Close #1
End If
Call modify(st, nu, vitri)
Call sapthutu
Call prevent_access(prevent)
End If
tbnhap.Text = "Completed"
Exit Sub
End If

'******* Xu ly cua phan Erase Name *************


If tbnhap.Text = "Erase Name and Number" Then
phonebook = False
found = False
flag = False
menucon = False
Call erased(vitri)
Call prevent_access(prevent)
End If

'******* Add Entry *********


If tbnhap.Text = "Add Entry" Then
flag = False

Trang 158
Laäp Trình Web Vôùi Visual Basic

found = False
menucon = False
tbnhap.Text = "Add To Phone Memory"
Exit Sub
End If

If tbnhap.Text = "Add To Phone Memory" Or (luumuc = 3 And quickaccess =


True) Then 'longpress = False) Then
quickaccess = False
luumuc = 0
phonebook = False
tbnhap.Text = "Enter Name?" & vbCrLf
swit = True
cancle = False
danhso = False
changecase = True
Exit Sub
End If

If tbnhap.Text = "Add To SIM Card Memory" Or (luumuc = 4 And quickaccess =


True) Then 'longpress = False) Then
quickaccess = False
luumuc = 0
phonebook = False
tbnhap.Text = "Enter Name?" & vbCrLf
swit = False
cancle = False
danhso = False
changecase = True
Exit Sub
End If

'******* Them vao bo nho may **********


If Left(Trim(tbnhap.Text), 11) = "Enter Name?" Then
k = InStr(tbnhap.Text, vbLf)
st = Mid(tbnhap.Text, k + 1)
If st = "" Then
Beep
tbnhap.Text = "Enter Name?" & vbCrLf
Else
tbnhap.Text = "Enter Number" & vbCrLf

Trang 159
cancle = True
danhso = True
changecase = False
Exit Sub
End If
End If

If Left(tbnhap.Text, Len("Enter Number")) = "Enter Number" Then


k = InStr(tbnhap.Text, vbLf)
nu = Mid(tbnhap.Text, k + 1)
If nu = "" Then
Beep
tbnhap.Text = "Enter Number" & vbCrLf
Else
menucon = False
flag = False
found = False
tbnhap.Text = "Enter Location!" & vbCrLf
danhso = True
Exit Sub
End If
End If

If Left(tbnhap.Text, 15) = "Enter Location!" Then


k = InStr(tbnhap.Text, vbLf)
ch = Mid(tbnhap.Text, k + 1) 'flag = False
If ch = "" Then
lo = add_lo(swit)
If addentrylist = True Then
Call add_entry(st, nu, lo, swit)
Else
Call add_entry(st, nu, lo, swit)
Call sapthutu
Call prevent_access(prevent)
End If
Exit Sub
Else
lo = Val(ch)
If addentrylist = True Then
If lo = 0 Or lo > 40 Then
tbnhap.Text = "Range 1-40"

Trang 160
Laäp Trình Web Vôùi Visual Basic

danhso = False
Exit Sub
End If
'ghi vao trong Fixed Dial List
Call add_entry(st, nu, lo, swit)
Else
If swit = False Then
'ghi vao trong SIM
If lo < 100 Or lo > 255 Then
tbnhap.Text = "Range 101-255"
danhso = False
Exit Sub
End If
Call add_entry(st, nu, lo, swit)
Call sapthutu
Call prevent_access(prevent)
Exit Sub
Else
'ghi vao trong bo nho
If lo = 0 Or lo > 100 Then
tbnhap.Text = "Range 1-100"
danhso = False
Exit Sub
End If
Call add_entry(st, nu, lo, swit)
Call sapthutu
Call prevent_access(prevent)
Exit Sub
End If
End If
End If
End If

If tbnhap.Text = "Overwritten?" Then


Call OVERWRITE(st, nu, lo)
Call sapthutu
Call prevent_access(prevent)
Exit Sub
End If

'***** Kiem tra suc chua cua phone****

Trang 161
If tbnhap.Text = "Check Capacity" Then
tbnhap.Text = "Check Phone Capacity"
Exit Sub
End If

If tbnhap.Text = "Check Phone Capacity" Then


Call check(0)
Exit Sub
End If

If tbnhap.Text = "Check SIM Capacity" Then


Call check(1)
Exit Sub
End If

'Xu ly cua phan Prevent Access


If tbnhap.Text = "Prevent Access" Then
tbnhap.Text = "No Memory Restrictions"
Exit Sub
End If

If tbnhap.Text = "No Memory Restrictions" Then


phonebook = False
prevent = 1
tbnhap.Text = "Enter Security Code" & vbCrLf
danhso = True
Exit Sub
End If

If tbnhap.Text = "To SIM Card Memory" Then


phonebook = False
'tam = 2
prevent = 2
tbnhap.Text = "Enter Security Code" & vbCrLf
danhso = True
Exit Sub
End If

If tbnhap.Text = "To Phone Memory" Then


phonebook = False
'tam = 3

Trang 162
Laäp Trình Web Vôùi Visual Basic

prevent = 3
tbnhap.Text = "Enter Security Code" & vbCrLf
danhso = True
Exit Sub
End If

If tbnhap.Text = "To Phone & SIM Memory" Then


phonebook = False
'tam = 4
prevent = 4
tbnhap.Text = "Enter Security Code" & vbCrLf
danhso = True
Exit Sub
End If

If Left(tbnhap.Text, 19) = "Enter Security Code" Then


k = InStr(tbnhap.Text, vbLf)
If Mid(tbnhap.Text, k + 1) <> securitycode Then
tbnhap.Text = " Failed"
danhso = False
Exit Sub
Else
Call prevent_access(prevent)
tbnhap.Text = "Restricted"
End If
Exit Sub
End If

If tbnhap.Text = "Menu" Then


Beep
tbnhap.Text = "Menu"
Exit Sub
End If

If tbnhap.Text = "No Name Stored" Or tbnhap.Text = "No Numbers Stored" Then


tbnhap.Text = "Menu"
Exit Sub
End If

'xu ly cua muc Fixed Dialling


If tbnhap.Text = "Fixed Dialling" Then

Trang 163
tbnhap.Text = "View Fixed Dial List"
danhso = False
cancle = True
Exit Sub
End If

If tbnhap.Text = "Setup Fixed Dialling" Then


listdial = False
tbnhap.Text = "Enter PIN2 Code" & vbCrLf
phonebook = False
danhso = True
cancle = True
Exit Sub
End If

'xu ly cua muc View Fixed Dial List


If tbnhap.Text = "View Fixed Dial List" Then
Call fixeddiallist
callnumberfixed = True
listdial = True
cancle = True
danhso = False
Exit Sub
End If

If callnumberfixed = True Then


k = InStr(tbnhap.Text, vbLf)
st = Trim(Mid(tbnhap.Text, k + 1))
tbnhap.Text = "Call Number?"
danhso = False
listdial = False
cancle = True
callnumberfixed = False
Exit Sub
End If

'xu ly khi vao trong muc Setup Fixed Dialling


If Left(tbnhap.Text, 10) = "Enter PIN2" Then
callnumberfixed = False
k = InStr(tbnhap.Text, vbLf)
st = Mid(tbnhap.Text, k + 1)

Trang 164
Laäp Trình Web Vôùi Visual Basic

If st = pin2code Then
tbnhap.Text = "On."
phonebook = True 'False
danhso = False
cancle = True
Else
tbnhap.Text = "Not Match."
danhso = False
End If
Exit Sub
End If

If tbnhap.Text = "On." Then


setupfixed = True
tbnhap.Text = "Completed"
phonebook = False
Exit Sub
End If

If tbnhap.Text = "Off." Then


setupfixed = False
tbnhap.Text = "Completed"
phonebook = False
Exit Sub
End If

If tbnhap.Text = "Edit Entry" Then


Call fixeddiallist
editentrylist = True
cancle = False
Exit Sub
End If

If editentrylist = True Then


tbnhap.Text = "Change Name" & vbCrLf
cancle = False
danhso = False
changecase = True
listdial = False
phonebook = False
Exit Sub

Trang 165
End If

If tbnhap.Text = " Add Entry" Then


tbnhap.Text = "Enter Name?" & vbCrLf
cancle = False
danhso = False
addentrylist = True
swit = True
phonebook = False
Exit Sub
End If

If tbnhap.Text = "Erase Entry" Then


Call fixeddiallist
eraseentrylist = True
Exit Sub
End If

If eraseentrylist = True Then


Call erased(vitri)
listdial = False
phonebook = False
Exit Sub
End If

'xu ly cua muc One-Touch Dial Setting


If tbnhap.Text = "One-Touch Dial Setting" Then
tbnhap.Text = " To Phone Memory"
Exit Sub
End If

If tbnhap.Text = " To Phone Memory" Then


tbnhap.Text = "Completed"
onetouchphone = True
onetouchof = 1
Exit Sub
End If

If tbnhap.Text = " To SIM Memory" Then


tbnhap.Text = "Completed"
onetouchof = 2

Trang 166
Laäp Trình Web Vôùi Visual Basic

onetouchphone = True
Exit Sub
End If

If tbnhap.Text = " To Fixed Dial List" Then


tbnhap.Text = "Completed"
onetouchphone = True
onetouchof = 3
Exit Sub
End If

'xu ly cua menu Call Related Features


If tbnhap.Text = "Call Related Features" Then
tbnhap.Text = "Show Battery Meter"
features = True
Exit Sub
End If

If tbnhap.Text = "Restrict My Phone Number" Then


tbnhap.Text = "Show ID On Next Call"
Exit Sub
End If

If tbnhap.Text = "Call Diverting" Then


tbnhap.Text = "Divert Voice Calls"
Exit Sub
End If

If tbnhap.Text = "Divert Voice Calls" Then


tbnhap.Text = "Divert When Unavailable"
Exit Sub
End If

If tbnhap.Text = "Divert When Unavailable" Then


tbnhap.Text = "On"
Exit Sub
End If

If tbnhap.Text = "Divert All Voice Calls" Then


tbnhap.Text = "On"
Exit Sub

Trang 167
End If

If tbnhap.Text = "Detailed Diverting" Then


tbnhap.Text = "If Busy"
Exit Sub
End If

If tbnhap.Text = "If Busy" Or tbnhap.Text = "If Not Reachable" Or tbnhap.Text =


"If No Answer" Then
tbnhap.Text = "On"
Exit Sub
End If

If tbnhap.Text = "Divert Fax Calls" Or tbnhap.Text = "Divert Data Calls" Then


tbnhap.Text = "On"
Exit Sub
End If

If tbnhap.Text = "Talk and Fax" Or tbnhap.Text = "Call Waiting" Or tbnhap.Text


= "Key Answer Only" Then
tbnhap.Text = "On"
Exit Sub
End If

If tbnhap.Text = "Call Barring" Then


tbnhap.Text = "Enter Barring Password" & vbCrLf
danhso = True
cancle = True
features = False
Exit Sub
End If

If Left(tbnhap.Text, 13) = "Enter Barring" Then


k = InStr(tbnhap.Text, vbLf)
st = Mid(tbnhap.Text, k + 1)
If st = barpassword Then
tbnhap.Text = "Bar Outgoing Calls"
features = True
danhso = False
cancle = True
Else

Trang 168
Laäp Trình Web Vôùi Visual Basic

tbnhap.Text = " Not Match."


danhso = False
End If
Exit Sub
End If

If tbnhap.Text = "Bar Outgoing Calls" Then


tbnhap.Text = "Int'l Calls"
Exit Sub
End If

If tbnhap.Text = "Bar Incoming Calls" Then


tbnhap.Text = "When Roaming"
Exit Sub
End If

'xu ly cua phan change bar password


If tbnhap.Text = "Change Bar Password" Then
tbnhap.Text = " Current Password" & vbCrLf
features = False
danhso = True
setup = False
Exit Sub
End If

If Left(tbnhap.Text, 17) = " Current Password" Then


k = InStr(tbnhap.Text, vbLf)
If Mid(tbnhap.Text, k + 1) = barpassword Then
tbnhap.Text = "New Barring Password" & vbCrLf
danhso = True
cancle = True
Else
tbnhap.Text = "Invalid Password"
danhso = False
cancle = True
End If
Exit Sub
End If

If Left(tbnhap.Text, 20) = "New Barring Password" Then

Trang 169
k = InStr(tbnhap.Text, vbLf)
If Len(Mid(tbnhap.Text, k + 1)) <> 4 Then
tbnhap.Text = " Enter 4 Digit"
danhso = False
Else
barpassword = Mid(tbnhap.Text, k + 1)
tbnhap.Text = "Completed"
End If
Exit Sub
End If

'vao menu con cua muc Show Battery Meter


If volume.Visible = True Then
volume.Visible = False
tbnhap.Visible = True
Frame1.Height = 500
Frame1.Width = 1800
tbnhap.Text = "Menu"
Exit Sub
End If

If tbnhap.Text = "Show Battery Meter" Or (luumuc = 11 And quickaccess = True


And longpress = False) Then
volume.Visible = True
tbnhap.Visible = False
Frame1.Height = 240
Frame1.Width = 1800
volume.Picture = battery.Picture
cancle = True
danhso = False
quickaccess = False
features = False
luumuc = 0
Exit Sub
End If

'phan xu ly cua menu restrict my phone number


If tbnhap.Text = "Show ID On Next Call" Or tbnhap.Text = "Restrict ID On Next
Call" Or tbnhap.Text = "Cancle All Diverting" Then
tbnhap.Text = "Completed"
features = False

Trang 170
Laäp Trình Web Vôùi Visual Basic

Exit Sub
End If

'xu ly cua phan call barring


If tbnhap.Text = "Int'l Calls" Or tbnhap.Text = "Int'l Calls Except Home" Then
tbnhap.Text = "Completed"
features = False
Exit Sub
End If

If tbnhap.Text = "All Calls" Then


callbarring = True
tbnhap.Text = "Completed"
features = False
Exit Sub
End If

If tbnhap.Text = "Off?" Then


callbarring = False
tbnhap.Text = "Completed"
features = False
Exit Sub
End If

'xu ly cua phan Bar Incoming Calls


If tbnhap.Text = "When Roaming" Or tbnhap.Text = " All Calls" Or tbnhap.Text =
"Off? " Then
tbnhap.Text = "Completed"
features = False
Exit Sub
End If

If tbnhap.Text = "Cancel All Barring" Then


callbarring = False
tbnhap.Text = "Completed"
features = False
Exit Sub
End If

'vao phan xu ly cua menu Messages


If tbnhap.Text = "Messages" Then

Trang 171
tbnhap.Text = "Call Voicemail"
message1 = True
Exit Sub
End If

'phan xu ly trong muc Message Editor


If tbnhap.Text = "Message Editor" Or (luumuc = 15 And quickaccess = True) Then
taomoi = False
quickaccess = False
luumuc = 0
Open filename4 For Random As #1 Len = Len(message)
banghi = LOF(1) \ Len(message)
If banghi = 0 Then
tbnhap.Text = ""
editor = True
danhso = False
cancle = False
message1 = False
Else
Get #1, banghi, message
tbnhap.Text = Trim(message.tin)
messagenumber = banghi
editor = True
danhso = False
cancle = False
message1 = False
End If
Close #1

Exit Sub
End If

If editor = True Then


If tbnhap.Text = "" Then
Exit Sub
Else
st = tbnhap.Text
tbnhap.Text = " Send Message"
editor = False
cancle = True
danhso = False

Trang 172
Laäp Trình Web Vôùi Visual Basic

End If
Exit Sub
End If

If tbnhap.Text = "Cell Broadcast" Then


tbnhap.Text = "On"
Exit Sub
End If

If tbnhap.Text = "Message Settings" Then


tbnhap.Text = "Voicemail Number"
Exit Sub
End If

If tbnhap.Text = "Outgoing Message Type" Then


tbnhap.Text = "Text"
Exit Sub
End If

'phan xu ly cua menu Outgoing Message


If tbnhap.Text = "Outgoing Messages" Or tbnhap.Text = "Outgoing SMS?" Then
'(luumuc = 14 And quickaccess = True) Then
messagelist = True
quickaccess = False
thu = False
luumuc = 0
cancle = False
Open filename4 For Random As #1 Len = Len(message)
banghi = LOF(1) \ Len(message)
If banghi = 0 Then
tbnhap.Text = "No Message Stored"
messagelist = False
Else
Get #1, 1, message
tbnhap.Text = Trim(message.tin)
messagenumber = 1
'cancle = True
danhso = False
End If
Close #1
Exit Sub

Trang 173
End If

If messagelist = True Then


tbnhap.Text = "Send Message"
messagelist = False
Exit Sub
End If

If tbnhap.Text = "Send Message" Or tbnhap.Text = " Send Message" Then


tbnhap.Text = " Enter Number"
danhso = False
cancle = True
message1 = True
Exit Sub
End If

If tbnhap.Text = " Enter Number" Then


tbnhap.Text = ""
message1 = False
danhso = True
cancle = True
send = True
Exit Sub
End If

If sending = True Then


If tbnhap.Text = "" Then
sending = False
Exit Sub
End If
messagelist = False
sending = False
tbnhap.Text = "Sending"
message1 = False
flag = False
menucon = False
Exit Sub
End If

'phan xu ly cua muc Edit Message


If tbnhap.Text = "Edit Message" Then

Trang 174
Laäp Trình Web Vôùi Visual Basic

taomoi = False
Open filename4 For Random As #1 Len = Len(message)
banghi = LOF(1) \ Len(message)
Get #1, messagenumber, message
tbnhap.Text = Trim(message.tin)
danhso = False
cancle = False
editor = True
message1 = False
Close #1
Exit Sub
End If

'phan xu ly cua muc Store Message


If tbnhap.Text = "Store Message" Then
Call store_message
message1 = False
Exit Sub
End If

'phan xu ly cua muc delete message trong Outgoing Message


If tbnhap.Text = "Delete Message" Then
Call delete_message
message1 = False
danhso = False
cancle = True
Exit Sub
End If

'xu ly cua muc Go to next Message trong Outgoing Message


If tbnhap.Text = "Go to Next Message" Then
Open filename4 For Random As #1 Len = Len(message)
banghi = LOF(1) \ Len(message)
If banghi <= messagenumber Then
Get #1, 1, message
tbnhap.Text = Trim(message.tin)
Else
messagenumber = messagenumber + 1
Get #1, messagenumber, message
tbnhap.Text = Trim(message.tin)
End If

Trang 175
messagelist = True
Close #1
Exit Sub
End If

'xu ly khi gap truong hop No Msg Stored


If tbnhap.Text = "No Message Stored" Then
message1 = False
tbnhap.Text = "Menu"
danhso = True
cancle = True
Exit Sub
End If

'vao trong muc voicemail number cua message setting


If tbnhap.Text = "Voicemail Number" Then
tbnhap.Text = voicemailnumber
danhso = True
cancle = True
setting = True
message1 = False
voice = True
Exit Sub
End If

If voice = True Then


If tbnhap.Text = "" Then
Exit Sub
Else
voicemailnumber = tbnhap.Text
voice = False
tbnhap.Text = "Completed"
danhso = False
cancle = True
setting = False
Exit Sub
End If
End If

'vao trong muc Service Centre cua message setting


If tbnhap.Text = "Service Centre" Then

Trang 176
Laäp Trình Web Vôùi Visual Basic

tbnhap.Text = servicecentre
danhso = True
cancle = True
setting = True
service = True
message1 = False
Exit Sub
End If

If service = True Then


If tbnhap.Text = "" Then
Exit Sub
Else
servicecentre = tbnhap.Text
service = False
tbnhap.Text = "Completed"
danhso = False
setting = False
Exit Sub
End If
End If

'vao trong muc Expiry Period cua message setting


If tbnhap.Text = "Expiry Period" Then
tbnhap.Text = expiryperiod
danhso = True
cancle = True
setting = True
message1 = False
expiry = True
Exit Sub
End If

If expiry = True Then


If tbnhap.Text = "" Then
Exit Sub
Else
expiryperiod = tbnhap.Text
expiry = False
tbnhap.Text = "Completed"
danhso = False

Trang 177
setting = False
Exit Sub
End If
End If

'xu ly cua phan Call Voicemail


If tbnhap.Text = "Call Voicemail" Or (luumuc = 12 And quickaccess = True)
Then
If longpress = True Then
Exit Sub
End If
tbnhap.Text = "Calling"
danhso = False
cancle = True
Image2.Visible = True
message1 = False
quickaccess = False
luumuc = 0
Exit Sub
End If

'******** vao menu con cua muc Phone Setup ********


If tbnhap.Text = "Phone Setup" Then
tbnhap.Text = "Select Phone Line"
setup = True
Exit Sub
End If

'vao menu con cua muc Select phone line


If tbnhap.Text = "Select Phone Line" Or (luumuc = 7 And quickaccess = True)
Then 'longpress = False) Then
quickaccess = False
luumuc = 0
tbnhap.Text = "Line 1"
danhso = False
cancle = True
Exit Sub
End If

If tbnhap.Text = "Line 1" Then


tbnhap.Text = "Completed"

Trang 178
Laäp Trình Web Vôùi Visual Basic

line2 = False
setup = False
Exit Sub
End If
If tbnhap.Text = "Line 2" Then
tbnhap.Text = "Completed"
quickaccess = False
line2 = True
setup = False
Exit Sub
End If

'vao menu con cua muc Adjust Ring Volume


If volume.Visible = True Then 'And so(14).Value = False And so(15).Value =
False Then
volume.Visible = False
tbnhap.Visible = True
Frame1.Height = 500
Frame1.Width = 1800
tbnhap.Text = "Menu"
advolume = False
setup = False
Exit Sub
End If

If (tbnhap.Text = "Adjust Ring Volume" And setup = True) Or (luumuc = 6 And


quickaccess = True) Then 'longpress = False) Then
volume.Visible = True
tbnhap.Visible = False
Frame1.Height = 240
Frame1.Width = 1790
volume.Picture = volume1(vol).Picture
advolume = True
setup = False
cancle = True
danhso = False
quickaccess = False
luumuc = 0
Exit Sub
End If

Trang 179
'vao menu con cua muc Ring or vibrate
If tbnhap.Text = "Ring or Vibrate" Then
tbnhap.Text = "Ring Only"
Exit Sub
End If
If luumuc = 9 And quickaccess = True Then
If longpress = True Then
Exit Sub
End If
quickaccess = False
luumuc = 0
If Image7.Visible = False Then
Image7.Visible = True
Else
Image7.Visible = False
End If
danhso = False
cancle = True
tbnhap.Text = "Completed"
Exit Sub
End If

If tbnhap.Text = "Ring Only" Or tbnhap.Text = "Vibrate Then Ring" Or


tbnhap.Text = "Vibrate Only" Or tbnhap.Text = "No Ring or Vibrate" Then
If tbnhap.Text = "Vibrate Only" Or tbnhap.Text = "No Ring or Vibrate" Then
Image7.Visible = False
Else
Image7.Visible = True
End If
tbnhap.Text = "Completed"
setup = False
Exit Sub
End If

'vao menu con cua muc Set ringer tone


If tbnhap.Text = "Set Ringer Tone" Then
tbnhap.Text = "Standard Tone"
Exit Sub
End If

If tbnhap.Text = "Standard Tone" Or tbnhap.Text = "Music Tone" Then

Trang 180
Laäp Trình Web Vôùi Visual Basic

tbnhap.Text = "Completed"
setup = False
Exit Sub
End If

'vao menu con cua muc Set ringer tone 2


If tbnhap.Text = "Set Ringer Tone 2" Then
tbnhap.Text = "Standard Tone"
Exit Sub
End If

'vao menu cua muc Phone Lock


If tbnhap.Text = "Phone Lock" Then
tbnhap.Text = "Automatic Lock"
Exit Sub
End If

If tbnhap.Text = "Automatic Lock" Then


tbnhap.Text = " On "
Exit Sub
End If

If Left(tbnhap.Text, 5) = " On " Then


autolocked = True
tbnhap.Text = "Completed"
setup = False
Exit Sub
End If

If tbnhap.Text = " Off " Then


tbnhap.Text = "Completed"
setup = False
autolocked = False
Exit Sub
End If

If tbnhap.Text = "Lock Now" Or (luumuc = 5 And quickaccess = True) Then


tbnhap.Text = "Locked"
locked = True
setup = False
quickaccess = False

Trang 181
luumuc = 0
Exit Sub
End If

If Left(tbnhap.Text, Len("Unlock Code")) = "Unlock Code" Then


k = InStr(tbnhap.Text, vbLf)
If Mid(tbnhap.Text, k + 1) = unlocked Then
locked = False
tbnhap.Text = "Menu"
setup = False
Else
tbnhap.Text = "Not Match"
danhso = False
End If
Exit Sub
End If

If tbnhap.Text = " Change Unlock Code" Then


tbnhap.Text = "Old Code" & vbCrLf
danhso = True
setup = False
Exit Sub
End If

If Left(tbnhap.Text, 8) = "Old Code" Then


k = InStr(tbnhap.Text, vbLf)
If Mid(tbnhap.Text, k + 1) = unlocked Then
tbnhap.Text = "New Code" & vbCrLf
Else
tbnhap.Text = " Not Match"
danhso = False
End If
Exit Sub
End If

If Left(tbnhap.Text, 8) = "New Code" Then


k = InStr(tbnhap.Text, vbLf)
If Len(Mid(tbnhap.Text, k + 1)) <> 4 Then
tbnhap.Text = "Enter 4 Digit"
danhso = False
Exit Sub

Trang 182
Laäp Trình Web Vôùi Visual Basic

Else
unlocked = Mid(tbnhap.Text, k + 1)
tbnhap.Text = "Completed"
danhso = False
setup = False
Exit Sub
End If
End If

If tbnhap.Text = "Require SIM Card PIN" Then


tbnhap.Text = " On."
Exit Sub
End If

'xu ly cua muc Change SIM Pin2 code


If tbnhap.Text = "Change SIM PIN2 Code" Then
tbnhap.Text = "Current PIN2 Code" & vbCrLf
danhso = True
setup = False
Exit Sub
End If

If Left(tbnhap.Text, 17) = "Current PIN2 Code" Then


k = InStr(tbnhap.Text, vbLf)
If Mid(tbnhap.Text, k + 1) = pin2code Then
tbnhap.Text = "New PIN2 Code" & vbCrLf
Else
tbnhap.Text = " Invalid Code"
danhso = False
End If
Exit Sub
End If

If Left(tbnhap.Text, 13) = "New PIN2 Code" Then


k = InStr(tbnhap.Text, vbLf)
If Len(Mid(tbnhap.Text, k + 1)) < 4 Or Len(Mid(tbnhap.Text, k + 1)) > 8 Then
tbnhap.Text = "Enter 4-8 Digit"
danhso = False
Else
pin2code = Mid(tbnhap.Text, k + 1)
tbnhap.Text = "Completed"

Trang 183
setup = False
End If
Exit Sub
End If
'xu ly cua phan New Security Code
If tbnhap.Text = "New Security Code" Then
tbnhap.Text = "Current Code" & vbCrLf
danhso = True
setup = False
Exit Sub
End If

If Left(tbnhap.Text, 12) = "Current Code" Then


k = InStr(tbnhap.Text, vbLf)
If Mid(tbnhap.Text, k + 1) = securitycode Then
tbnhap.Text = "New Security Code" & vbCrLf
Else
tbnhap.Text = "Invalid Code"
danhso = False
End If
Exit Sub
End If

If Left(tbnhap.Text, 17) = "New Security Code" Then


k = InStr(tbnhap.Text, vbLf)
If Len(Mid(tbnhap.Text, k + 1)) <> 6 Then
tbnhap.Text = "Enter 6 Digit"
danhso = False
Else
securitycode = Mid(tbnhap.Text, k + 1)
tbnhap.Text = "Completed"
danhso = False
setup = False
End If
Exit Sub
End If

'xu ly cua phan Extended Menus


If tbnhap.Text = "Extended Menus" Then
tbnhap.Text = " On"
Exit Sub

Trang 184
Laäp Trình Web Vôùi Visual Basic

End If

If tbnhap.Text = " On" Then


extend = True
tbnhap.Text = "Completed"
setup = False
Exit Sub
End If

If tbnhap.Text = " Off" Then


extend = False
tbnhap.Text = "Completed"
setup = False
Exit Sub
End If

If tbnhap.Text = "Show Time and Date" Or (luumuc = 8 And quickaccess = True)


Then
tbnhap.Text = Format(Now, "Medium Date") & vbCrLf & Format(Now, "Short
Time")
If longpress = True Then
showtime = False 'True
Else
showtime = True
End If

setup = False
quickaccess = False
luumuc = 0
Exit Sub
End If

If tbnhap.Text = "Set Time and Date" Then


tbnhap.Text = "Enter Time" & vbCrLf
setup = False
cancle = False
Exit Sub
End If

If Left(tbnhap.Text, 10) = "Enter Time" Then


j = InStr(tbnhap.Text, vbLf)

Trang 185
If Not IsDate(Mid(tbnhap.Text, j + 1)) Then 'k < 1 Or k > 24 Then
tbnhap.Text = "Invalid Time"
cancle = True
danhso = False
Exit Sub
Else
newtime = Mid(tbnhap.Text, j + 1)
tbnhap.Text = "Enter Date" & vbCrLf
End If
Exit Sub
End If

If Left(tbnhap.Text, 10) = "Enter Date" Then


j = InStr(tbnhap.Text, vbLf)
If Not IsDate(Mid(tbnhap.Text, j + 1)) Then
tbnhap.Text = "Invalid Date"
cancle = True
danhso = False
Exit Sub
Else
newdate = Mid(tbnhap.Text, j + 1)
End If
Time = newtime
Date = newdate
tbnhap.Text = "Completed"
cancle = True
Exit Sub
End If

If tbnhap.Text = "Set Time Format" Then


tbnhap.Text = "12-hour?"
Exit Sub
End If

If tbnhap.Text = "12-hour?" Then


formattime = False
tbnhap.Text = "Completed"
setup = False
Exit Sub
End If

Trang 186
Laäp Trình Web Vôùi Visual Basic

If tbnhap.Text = "24-hour?" Then


formattime = True
tbnhap.Text = "Completed"
setup = False
Exit Sub
End If

If tbnhap.Text = "Battery Saving Mode" Then


tbnhap.Text = "On"
setup = False
Exit Sub
End If

If tbnhap.Text = "On" Then


tbnhap.Text = "Completed"
features = False
network = False
accessory = False
message1 = False
Exit Sub
End If

If tbnhap.Text = "Off" Then


tbnhap.Text = "Completed"
features = False
network = False
accessory = False
message1 = False
Exit Sub
End If

If tbnhap.Text = "Select Keypad Tones" Then


tbnhap.Text = "Normal Tones"
Exit Sub
End If

If tbnhap.Text = "Normal Tones" Or tbnhap.Text = "Single Tone" Or tbnhap.Text


= "No Tones" Then
tbnhap.Text = "Completed"
setup = False
Exit Sub

Trang 187
End If

If tbnhap.Text = "Phone Status" Then


tbnhap.Text = "Status Review"
Exit Sub
End If

'phan xu ly cua menu Network Selection


If tbnhap.Text = "Network Selection" Then
tbnhap.Text = " Change Band"
network = True
Exit Sub
End If

If tbnhap.Text = " Change Band" Or (luumuc = 10 And quickaccess = True) Then


'longpress = False) Then
tbnhap.Text = "Change to 900/1800"
danhso = False
cancle = True
quickaccess = False
luumuc = 0
Exit Sub
End If

If tbnhap.Text = "Available Networks" Then


tbnhap.Text = "Wait.."
addnetwork = False
availablenetwork = True
Exit Sub
End If

If tbnhap.Text = "Choose From Available" Or tbnhap.Text = "Choose From


Known" Then
addnetwork = True
availablenetwork = False
tbnhap.Text = "Wait.."
Exit Sub
End If

If tbnhap.Text = "Network Search" Then


tbnhap.Text = "Registration Preferences"

Trang 188
Laäp Trình Web Vôùi Visual Basic

Exit Sub
End If

If tbnhap.Text = "Registration Preferences" Then


tbnhap.Text = "Automatic Search Mode"
Exit Sub
End If

If tbnhap.Text = "Automatic Search Mode" Or manualsearch = True Then


tbnhap.Text = "Registerring"
cancle = True 'False
danhso = False 'True
manualsearch = False
network = False
Exit Sub
End If

If tbnhap.Text = "Manual Search Mode" Then


Open filename5 For Random As #1 Len = Len(networks)
Get #1, 1, networks
tbnhap.Text = networks.mang
tam1 = 1
availablenetwork = True
manualsearch = True
Close #1
Exit Sub
End If

If tbnhap.Text = "Frequency of Search" Then


tbnhap.Text = "Slow Search"
Exit Sub
End If

'xu ly cua phan Preferred Networks


If tbnhap.Text = "Preferred Networks" Then
tbnhap.Text = "Add Network to List"
Exit Sub
End If

If tbnhap.Text = "Add Network to List" Then


tbnhap.Text = "Choose From Available"

Trang 189
Exit Sub
End If

If tbnhap.Text = "Show List of Networks" Then


Open filename6 For Random As #1 Len = Len(networks)
banghi = LOF(1) \ Len(networks)
If banghi = 0 Then
tbnhap.Text = "No Network in List"
Close #1
Exit Sub
End If
Get #1, 1, networks
tbnhap.Text = networks.mang
st = networks.mang
tam1 = 1
showlist = True
Close #1
Exit Sub
End If

If tbnhap.Text = "No Network in List" Then


tbnhap.Text = "Network Selection"
Exit Sub
End If

'xu ly cua muc Move to New Location


If showlist = True Then
tbnhap.Text = "Move to New Location"
showlist = False
Exit Sub
End If

If tbnhap.Text = "Move to New Location" Then


tbnhap.Text = "New Location?" & vbCrLf
danhso = True
cancle = True
network = False
Exit Sub
End If

If Left(tbnhap.Text, 4) = "New " Then

Trang 190
Laäp Trình Web Vôùi Visual Basic

k = InStr(tbnhap.Text, vbLf)
lo = Val(Mid(tbnhap.Text, k + 1))
If lo = 0 Then
tbnhap.Text = "New Location?" & vbCrLf
Exit Sub
End If
Call movenew(tam1, lo)
network = False
showlist = False
End If

'xu ly cua muc Delete Network


If tbnhap.Text = "Delete Network" Then
tbnhap.Text = "Are you sure?"
Exit Sub
End If

If tbnhap.Text = "Are you sure?" Then


Call xoa(tam1)
network = False
showlist = False
Exit Sub
End If

'xu ly cua phan Find New Network


If tbnhap.Text = "Find New Network" Then
tbnhap.Text = "Finding"
network = False
Exit Sub
End If

'phan xu ly cua muc Change Band


If tbnhap.Text = "Change to 900/1800" Or tbnhap.Text = "Change to 900" Or
tbnhap.Text = "Change to 1800" Then
tbnhap.Text = "Completed"
quickaccess = False
danhso = False
cancle = True
network = False
Exit Sub
End If

Trang 191
If addnetwork = True Then
availablenetwork = False
tbnhap.Text = " Location?" & vbCrLf
danhso = True
cancle = True
addnetwork = False
network = False
Exit Sub
End If

'xu ly cua muc available network


If availablenetwork = True Then
tbnhap.Text = "Register Now"
availablenetwork = False
Exit Sub
End If

If tbnhap.Text = "Register Now" Then


tbnhap.Text = "Register"
network = False
Exit Sub
End If

If tbnhap.Text = "Make Preferred" Then


tbnhap.Text = " Location?" & vbCrLf
danhso = True
cancle = True
network = False
Exit Sub
End If

If Left(tbnhap.Text, 10) = " Location?" Then


k = InStr(tbnhap.Text, vbLf)
lo = Val(Mid(tbnhap.Text, k + 1))
If lo = 0 Then
tbnhap.Text = " Location?" & vbCrLf
Exit Sub
End If
Call preferredlist(lo, st)
tbnhap.Text = "Completed"

Trang 192
Laäp Trình Web Vôùi Visual Basic

network = False
danhso = False
Exit Sub
End If

'phan xu ly cua muc Frequency of search


If tbnhap.Text = "Slow Search" Or tbnhap.Text = "Medium Search" Or
tbnhap.Text = "Fast Search" Or tbnhap.Text = "Continuous Search" Then
tbnhap.Text = "Completed"
network = False
danhso = False
Exit Sub
End If

'phan xu ly cua menu Accessory Setup


If tbnhap.Text = "Accessory Setup" Then
tbnhap.Text = "Mute Car Radio"
accessory = True
Exit Sub
End If

'vao menu con cua cac muc trong Accessory setup


If tbnhap.Text = "Mute Car Radio" Then
tbnhap.Text = "On"
Exit Sub
End If

If tbnhap.Text = "Automatic Answer" Then


tbnhap.Text = "On"
Exit Sub
End If

If tbnhap.Text = "Automatic Handsfree" Then


tbnhap.Text = "On"
Exit Sub
End If

If tbnhap.Text = "Safety Timer" Then


tbnhap.Text = "On"
Exit Sub
End If

Trang 193
If tbnhap.Text = "Auxiliary Alert" Then
tbnhap.Text = "On"
Exit Sub
End If

'phan xu ly cua muc Quick Access Menu


If longpress = True Then 'And st <> "" Then
Open filename3 For Random As #1 Len = Len(menuaccess)
Get #1, orderinquick, menuaccess
menuaccess.feature = st
menuaccess.thutu = luumuc
Put #1, orderinquick, menuaccess
Close #1
longpress = False
tbnhap.Text = "Completed"
thu = False
quickaccess = False
Exit Sub
End If

'truong hop user nhap vao mot so de lam mot cuoc goi
If IsNumeric(tbnhap.Text) = True And sending = False Then
st = tbnhap.Text
If Len(tbnhap.Text) < 7 Then
If tbnhap.Text = "1080" Or tbnhap.Text = "113" Or tbnhap.Text = "114" Or
tbnhap.Text = "115" Then
cancall = False
Else
cancall = True
End If
If send = True Then
sending = True
send = False
End If
End If
danhso = False
cancle = True
tbnhap.Text = "Calling" '" Call Number"
Image2.Visible = True
callnumber = True

Trang 194
Laäp Trình Web Vôùi Visual Basic

End If

'truong hop user nhap vao so dien thoai co format khong phu hop
If tbnhap.Text = "Connecting Failed" Then
tbnhap.Text = "Menu"
Exit Sub
End If

'********* phim left *********


Case 14
'menu con cua muc Personal Number
If quickaccess = True Then
Exit Sub
End If
'xu ly cua muc Adjust Ring Volume
If advolume = True Then
i=i+1
If vol > 0 Then
Select Case i
Case 3, 6, 9, 12, 15, 18, 21
vol = vol - 1
volume.Picture = volume1(vol).Picture
End Select
Else
Beep
End If
Exit Sub
End If

'********** phim phai **********


Case 15
If quickaccess = True Then 'longpress = True Then
Exit Sub
End If
If cancle = False Then
Select Case i
Case 0
tbnhap.Text = tbnhap.Text & Right(tbnhap.Text, 1)
i=i+1
Case 1
tbnhap.Text = tbnhap.Text & " "

Trang 195
End Select
Else
'xu ly cua phan Adjust Ring Volume
If advolume = True Then
i=i+1
If vol < 7 Then
Select Case i
Case 3, 6, 9, 12, 15, 18, 21
vol = vol + 1
volume.Picture = volume1(vol).Picture
End Select
Else
Beep
End If
Exit Sub
End If
End If

'****** day la phan xu ly cua phim OnOff *******


Case 16
phonebook = False
quickaccess = False
message1 = False
setup = False
network = False
listdial = False
editentrylist = False
addentrylist = False
eraseentrylist = False
changecase = False
messagelist = False
taomoi = False
editor = False
availablenetwork = False
addnetwork = False
Image2.Visible = False
Select Case onoff
Case 0
screen.Visible = True
Frame1.Visible = False
tbnhap.Visible = False

Trang 196
Laäp Trình Web Vôùi Visual Basic

If volume.Visible = True Then


volume.Visible = False
Frame1.Height = 500
Frame1.Width = 1800
End If
onoff = 1
Exit Sub
Case 1
screen.Visible = False
Frame1.Visible = True
tbnhap.Visible = True
If autolocked = True Or locked = True Then
tbnhap.Text = "Locked"
Else
tbnhap.Text = "Menu"
End If
onoff = 0
Exit Sub
End Select

'phan xu ly cua menu quick access


Case 17
If locked = True Then
Exit Sub
End If
If volume.Visible = True Then 'And so(14).Value = False And so(15).Value =
False Then
volume.Visible = False
tbnhap.Visible = True
Frame1.Height = 500
Frame1.Width = 1800
End If
Image2.Visible = False
network = False
phonebook = False
setup = False
listdial = False
editentrylist = False
addentrylist = False
eraseentrylist = False
changecase = False

Trang 197
messagelist = False
taomoi = False
editor = False
availablenetwork = False
addnetwork = False
Open filename3 For Random As #1 Len = Len(menuaccess)
Get #1, 1, menuaccess
tbnhap.Text = Trim(menuaccess.feature)
orderinquick = 1
luumuc = menuaccess.thutu
quickaccess = True
phonebook = False
thu = True
danhso = False
cancle = False
Close #1
Exit Sub
End Select
End Sub

'****** CHUONG TRINH CON THEM SO DT MOI *****


Private Sub add_entry(st As String, nu As String, lo As Integer, flag As Boolean)
Dim news As entry
Dim banghi As Byte
Dim j As Byte
If addentrylist = True Then
Open filefixed For Random As #1 Len = Len(news)
Else
Open filename For Random As #1 Len = Len(news)
End If
banghi = LOF(1) \ Len(news)
For j = 1 To banghi
Get #1, j, news
If news.location = lo Then
tbnhap.Text = "Overwritten?"
Close #1
Exit Sub
End If
Next j
news.name = st
news.number = nu

Trang 198
Laäp Trình Web Vôùi Visual Basic

news.location = lo
banghi = banghi + 1
If addentrylist = True Then
Put #1, banghi, news
Else
If flag = True Then
Put #1, banghi, news
Else
Put #1, banghi, news
End If
End If
addentrylist = False
listdial = False
tbnhap.Text = "Stored" & Str(lo)
Close #1
End Sub

'**** THU TUC TIM VI TRI SE GHI MOT MUC KHI USER KHONG NHAP VAO
LOCATION ****
Private Function add_lo(co As Boolean) As Integer
Dim news As entry
Dim banghi As Byte
Dim j As Integer
Dim i As Integer
Dim timthay As Boolean

If co = True Then
i=1
If addentrylist = True Then
Open filefixed For Random As #1 Len = Len(news)
Else
Open filename For Random As #1 Len = Len(news)
End If
banghi = LOF(1) \ Len(news)
If banghi = 0 Then
add_lo = 1
timthay = False
Close #1
Else
timthay = True
End If

Trang 199
Do While timthay = True
For j = 1 To banghi
Get #1, j, news
If i = news.location Then
i=i+1
timthay = True
Exit For
Else
If j = banghi Then
add_lo = i
timthay = False
Close #1
Exit Do
End If
End If
Next j
Loop
Else
i = 101
Open filename For Random As #1 Len = Len(news)
banghi = LOF(1) \ Len(news)
If banghi = 0 Then
add_lo = 101
timthay = False
Else
timthay = True
End If
Do While timthay = True
For j = 1 To banghi
Get #1, j, news
If i = news.location Then
i=i+1
timthay = True
Exit For
Else
If j = banghi Then
add_lo = i
timthay = False
Close #1
Exit Do
End If

Trang 200
Laäp Trình Web Vôùi Visual Basic

End If
Next j
Loop
Close #1
End If
End Function

'***** CHUONG TRINH CON TIM SO DT THEO TEN ******


Private Sub find_name(ten As String)
Dim news As entry
Dim i As Integer
Dim j As Integer
Dim banghi As Integer

Select Case prevent


Case 1
Open filename For Random As #1 Len = Len(news)
banghi = LOF(1) \ Len(news)
Case 2, 3
Open filename2 For Random As #1 Len = Len(news)
banghi = LOF(1) \ Len(news)
Case 4
found = False
tbnhap.Text = "No Name Stored"
Exit Sub
End Select

'**** Truong hop khong co ten nao da duoc luu ****


If banghi = 0 Then
found = False
tbnhap.Text = "No Name Stored"
Close #1
Exit Sub
End If

'**** truong hop user khong nhap ten de tim ********


If ten = "" And banghi <> 0 Then
Get #1, 1, news
found = True
vitri = 1
st1 = news.name

Trang 201
st = news.name
nu = news.number
tbnhap.Text = st & vbCrLf & nu
Close #1
flag = True
Exit Sub

'truong hop ten nhap vao trung voi ten da luu


Else
For i = 1 To banghi
Get #1, i, news
If StrComp(Left(news.name, Len(ten)), ten) = 0 Then
found = True
vitri = i
st = news.name
nu = news.number
st1 = news.name
tbnhap.Text = st & vbCrLf & nu
flag = True
Close #1
Exit Sub
End If
Next i
End If

'truong hop ten nhap vao khong trung voi ten da luu
For i = 1 To banghi
Get #1, i, news
If StrComp(Left(news.name, 1), Left(ten, 1)) = 0 Then
found = True
vitri = i
st = news.name
nu = news.number
st1 = news.name
tbnhap.Text = st & vbCrLf & nu
flag = True
Close #1
Exit Sub
End If
Next i

Trang 202
Laäp Trình Web Vôùi Visual Basic

'truong hop ten nhap vao khong tin thay, lay entry dau tien
Get #1, 1, news
st1 = news.name
st = news.name
nu = news.number
tbnhap.Text = st & vbCrLf & nu
found = True
flag = True
vitri = 1
Close #1
End Sub

'***** THU TUC GHI DE KHI TRUNG VI TRI *****


Private Sub OVERWRITE(st As String, nu As String, lo As Integer)
Dim j As Integer
Dim news As entry
Dim banghi As Byte
If addentrylist = True Then
Open filefixed For Random As #1 Len = Len(news)
addentrylist = False
Else
Open filename For Random As #1 Len = Len(news)
End If
banghi = LOF(1) \ Len(news)
For j = 1 To banghi
Get #1, j, news
If news.location = lo Then
news.location = lo
news.number = nu
news.name = st
Put #1, j, news
tbnhap.Text = "Stored" & Str(lo)
Exit For
End If
Next j
Close #1
End Sub

'****** THU TUC TIM MOT MUC THEO VI TRI *****


Private Sub find_location(so As Integer)
Dim news As entry

Trang 203
Dim news1 As entry
Dim j As Integer
Dim banghi As Byte
Dim i As Integer
'found = True
Select Case prevent
Case 1
Open filename For Random As #1 Len = Len(news)
Case 2, 3
Open filename2 For Random As #1 Len = Len(news)
Case 4
tbnhap.Text = "No Number Stored"
Exit Sub
End Select
banghi = LOF(1) \ Len(news)
If banghi = 0 Then
tbnhap.Text = "No Numbers Stored"
Close #1
Exit Sub
End If

If so = 0 Then
Get #1, 1, news
i = news.location
For j = 2 To banghi
Get #1, j, news1
If i > news1.location Then
i = news1.location
vitri = j
Else
vitri = i
End If
Next j
found = True
flag = True
Get #1, vitri, news
st1 = news.name
tbnhap.Text = news.name & vbCrLf & news.number
Close #1
Exit Sub
Else

Trang 204
Laäp Trình Web Vôùi Visual Basic

For j = 1 To banghi
Get #1, j, news
If so = news.location Then
found = True
vitri = j
Exit For
Else
found = False
End If
Next j
If found = True Then
st1 = news.name
tbnhap.Text = news.name & vbCrLf & news.number
Else
tbnhap.Text = "Location Empty"
End If
End If
flag = True
Close #1
End Sub

'****** THU TUC SUA DOI MOT MUC ***********


Private Sub modify(ten As String, so As String, cho As Integer)
Dim news As entry
Dim banghi As Byte
Dim j As Integer
If editentrylist = True Then
Open filefixed For Random As #1 Len = Len(news)
Else
Open filename For Random As #1 Len = Len(news)
End If
Get #1, cho, news
If ten <> "" Then
If so <> "" Then
news.name = ten
news.number = so
Put #1, cho, news
Close #1
Else
news.name = ten
Put #1, cho, news

Trang 205
Close #1
End If
Else
If so <> "" Then
news.number = so
Put #1, cho, news
Close #1
Else
Close #1
End If
End If
If editentrylist = True Then
editentrylist = False
listdial = False
End If
End Sub

'****** THU TUC XOA MOT MUC ************


Private Sub erased(cho As Integer)
Dim news As entry
Dim news1 As entry
Dim banghi As Byte
Dim j As Byte
Dim i As Integer
If eraseentrylist = True Then
Open filefixed For Random As #1 Len = Len(news)
Else
Open filename For Random As #1 Len = Len(news)
End If
Open filename1 For Random As #2 Len = Len(news1)
banghi = LOF(1) \ Len(news)
For j = 1 To banghi
If j <> cho Then
Get #1, j, news
Put #2, j, news
Else
i = news.location
Exit For
End If
Next j
Do While j < banghi

Trang 206
Laäp Trình Web Vôùi Visual Basic

Get #1, j + 1, news


Put #2, j, news
j=j+1
Loop
tbnhap.Text = "Erased"
Close #1
Close #2
If eraseentrylist = True Then
Kill filefixed
Name filename1 As filefixed
eraseentrylist = False
listdial = False
Else
Kill filename
Name filename1 As filename
End If
End Sub
'***** THU TUC XU LY CUA PHAN PREVENT ACCESS *******
Private Sub prevent_access(k As Integer)
Dim news As entry
Dim news1 As entry
Dim banghi As Byte
Dim j As Integer
Dim i As Integer

Open filename For Random As #1 Len = Len(news)


Open filename2 For Random As #2 Len = Len(news)
banghi = LOF(1) \ Len(news)
i=0
Select Case k
Case 1, 4
Close #1
Close #2
Exit Sub
Case 2
For j = 1 To banghi
Get #1, j, news
If news.location < 100 Then
i=i+1
Put #2, i, news
End If

Trang 207
Next j
Close #1
Open filename1 For Random As #3 Len = Len(news)
For j = 1 To i
Get #2, j, news
Put #3, j, news
Next j
Close #2
Close #3
Kill filename2
Name filename1 As filename2
Case 3
For j = 1 To banghi
Get #1, j, news
If news.location > 100 Then
i=i+1
Put #2, i, news
End If
Next j
Close #1
Open filename1 For Random As #3 Len = Len(news)
For j = 1 To i
Get #2, j, news
Put #3, j, news
Next j
Close #2
Close #3
Kill filename2
Name filename1 As filename2
End Select
End Sub

'***** THU TUC KHI PHIM BI MAT TIEU DIEM***


Private Sub so_LostFocus(Index As Integer)
i=0
End Sub

'QUAY SO CHI VOI MOT PHIM


Private Sub onetouch(vitri As Integer)
Dim news As entry
Dim j As Byte

Trang 208
Laäp Trình Web Vôùi Visual Basic

Dim banghi As Byte


Select Case onetouchof
Case 1, 2
Open filename For Random As #1 Len = Len(news)
Case 3
Open filefixed For Random As #1 Len = Len(news)
End Select
If onetouchof = 2 Then
vitri = vitri + 100
End If
banghi = LOF(1) \ Len(news)
For j = 1 To banghi
Get #1, j, news
If news.location = vitri Then
tbnhap.Text = news.number
Exit For
End If
Next j
Close #1
End Sub

'DANH SACH SO CO DINH


Private Sub fixeddiallist()
Dim news As entry
Dim banghi As Byte
Dim i As Integer
Dim j As Integer
Open filefixed For Random As #1 Len = Len(news)
found = False
banghi = LOF(1) \ Len(news)
If banghi = 0 Then
tbnhap.Text = "List Empty"
Else
If banghi = 1 Then
Get #1, 1, news
vitri = 1
Else
Get #1, 1, news
i = news.location
For j = 2 To banghi
Get #1, j, news

Trang 209
If i > news.location Then
i = news.location
vitri = j
Else
vitri = i
End If
Next j
End If
listdial = True
Get #1, vitri, news
st1 = news.name
tbnhap.Text = news.name & vbCrLf & news.number
End If
Close #1
End Sub

'XU LY CUA BO DEM THOI GIAN


Private Sub Timer1_Timer()
Dim j As Integer
Dim i As Integer
Dim ch As String
Dim networks As netselect

If formattime = False Then


Label2.Caption = Format(Now, "medium time")
Else
Label2.Caption = Format(Now, "short time")
End If

If Left(tbnhap.Text, 11) = "Range 1-100" Or Left(tbnhap.Text, 13) = "Range 101-


255" Or Left(tbnhap.Text, 10) = "Range 1-40" Then
danhso = True
tbnhap.Text = "Enter Location!" & vbCrLf
Exit Sub
End If

If Left(tbnhap.Text, 6) = " Range" Then


danhso = True
tbnhap.Text = " Enter Location" & vbCrLf
Exit Sub
End If

Trang 210
Laäp Trình Web Vôùi Visual Basic

If tbnhap.Text = "Location Empty" Then


'cancle = True
danhso = False
tbnhap.Text = "Personal Number"
Exit Sub
End If

If Right(tbnhap.Text, Len("Unused Locations")) = "Unused Locations" Then


tbnhap.Text = "Menu"
Exit Sub
End If

If tbnhap.Text = "Restricted" Then


tbnhap.Text = "Menu"
Exit Sub
End If

If tbnhap.Text = "Completed" Then


tbnhap.Text = "Menu"
danhso = True
Exit Sub
End If

If tbnhap.Text = "Calling" Then


Timer1.Interval = 3000
If cancall = True Then
tbnhap.Text = "Connecting Failed"
Image2.Visible = False
cancall = False
Exit Sub
End If
tbnhap.Text = "Connected"
Exit Sub
End If

If tbnhap.Text = "Connected" Then


tbnhap.Text = "End Call?"
found = False
Exit Sub
End If

Trang 211
If Left(tbnhap.Text, 6) = "Erased" Then
tbnhap.Text = "Menu"
Exit Sub
End If

If Left(tbnhap.Text, 6) = "Stored" Then


tbnhap.Text = "Menu"
Exit Sub
End If

If tbnhap.Text = "Range 1-24" Then


cancle = False
danhso = True
tbnhap.Text = "Enter Time" & vbCrLf
Exit Sub
End If

If tbnhap.Text = "Invalid Format" Then


cancle = False
danhso = True
tbnhap.Text = "Enter Date" & vbCrLf
Exit Sub
End If

If tbnhap.Text = "Not Match" Then


danhso = True
tbnhap.Text = "Unlock Code" & vbCrLf
Exit Sub
End If

If tbnhap.Text = " Not Match" Then


danhso = True
tbnhap.Text = "Old Code" & vbCrLf
Exit Sub
End If

If tbnhap.Text = "Not Match." Then


danhso = True
tbnhap.Text = "Enter PIN2 Code" & vbCrLf
Exit Sub

Trang 212
Laäp Trình Web Vôùi Visual Basic

End If

If tbnhap.Text = " Not Match." Then


danhso = True
tbnhap.Text = "Enter Barring Password" & vbCrLf
Exit Sub
End If

If tbnhap.Text = "Finding" Then


tbnhap.Text = "Failed"
Exit Sub
End If

If tbnhap.Text = "Failed" Then


tbnhap.Text = "Network Selection"
Exit Sub
End If

If tbnhap.Text = "Enter 4 Digit" Then


tbnhap.Text = "New Code" & vbCrLf
danhso = True
Exit Sub
End If

If tbnhap.Text = "Invalid Code" Then


tbnhap.Text = "Current Code" & vbCrLf
danhso = True
Exit Sub
End If

If tbnhap.Text = " Invalid Code" Then


tbnhap.Text = "Current PIN2 Code" & vbCrLf
danhso = True
End If

If tbnhap.Text = "Invalid Password" Then


tbnhap.Text = " Current Password" & vbCrLf
danhso = True
Exit Sub
End If

Trang 213
If tbnhap.Text = " Enter 4 Digit" Then
tbnhap.Text = "New Barring Password" & vbCrLf
danhso = True
Exit Sub
End If

If tbnhap.Text = "Enter 4-8 Digit" Then


tbnhap.Text = "New PIN2 Code" & vbCrLf
danhso = True
End If

If tbnhap.Text = "Enter 6 Digit" Then


tbnhap.Text = "New Security Code" & vbCrLf
danhso = True
Exit Sub
End If

If tbnhap.Text = " Failed" Then


tbnhap.Text = "Enter Security Code" & vbCrLf
danhso = True
Exit Sub
End If

If tbnhap.Text = "Invalid Time" Then


tbnhap.Text = "Enter Time" & vbCrLf
danhso = False
cancle = False
Exit Sub
End If

If tbnhap.Text = "Invalid Date" Then


tbnhap.Text = "Enter Date" & vbCrLf
cancle = False
danhso = False
Exit Sub
End If

If tbnhap.Text = "Sending" Then


If cancall = True Then
tbnhap.Text = "Connecting Failed"
Image2.Visible = False

Trang 214
Laäp Trình Web Vôùi Visual Basic

cancall = False
Else
tbnhap.Text = " Connected"
End If
Exit Sub
End If

If tbnhap.Text = " Connected" Then


Image2.Visible = False
tbnhap.Text = "Completed"
Exit Sub
End If

If tbnhap.Text = "Deleted" Then


tbnhap.Text = "Messages"
cancle = True
danhso = False
Exit Sub
End If

If tbnhap.Text = "Invalid Msg Number" Then


tbnhap.Text = "Messages"
cancle = True
danhso = False
Exit Sub
End If

'xu ly khi lam trong muc available network


If tbnhap.Text = "Wait.." Then
tbnhap.Text = "Scanning"
Exit Sub
End If

If tbnhap.Text = "Scanning" Then


Open filename5 For Random As #1 Len = Len(networks)
Get #1, 1, networks
tam1 = 1
tbnhap.Text = networks.mang
st = tbnhap.Text
Close #1
Exit Sub

Trang 215
End If

If tbnhap.Text = "Register" Then


tbnhap.Text = "Completed"
Exit Sub
End If

If tbnhap.Text = "Registerring" Then


tbnhap.Text = "Failed"
Exit Sub
End If
End Sub

'THU TUC SAP THU TU


Private Sub sapthutu()
Dim news As entry
Dim news1 As entry
Dim j As Integer
Dim k As Integer
Dim banghi As Byte
Dim ch As String
Dim ch1 As String
Dim so As String
Dim vitri As Integer

Open filename For Random As #1 Len = Len(news)


Open filename For Random As #2 Len = Len(news1)
banghi = LOF(1) \ Len(news)
For j = 2 To banghi
Get #1, j, news
ch = news.name
so = news.number
vitri = news.location
For k = j - 1 To 1 Step -1
Get #2, k, news1
ch1 = news1.name
If StrComp(ch, ch1) = 1 Or StrComp(ch, ch1) = 0 Then
Exit For
End If
news.name = news1.name
news.number = news1.number

Trang 216
Laäp Trình Web Vôùi Visual Basic

news.location = news1.location
Put #1, k + 1, news
Next k
news.name = ch
news.number = so
news.location = vitri
Put #1, k + 1, news
Next j
Close #1
Close #2
End Sub

'CHUYEN MOT MUC


Private Sub menu_downswitchentry()
Dim news As entry
Dim banghi As Byte
Select Case prevent
Case 1
Open filename For Random As #1 Len = Len(news)
Case 2, 3
Open filename2 For Random As #1 Len = Len(news)
End Select
banghi = LOF(1) \ Len(news)
menucon = True
vitri = vitri + 1
If vitri <= banghi Then
Get #1, vitri, news
st1 = news.name
st = news.name
nu = news.number
tbnhap.Text = st & vbCrLf & nu
Close #1
Exit Sub
Else
vitri = 1
Get #1, vitri, news
st = news.name
st1 = news.name
nu = news.number
tbnhap.Text = st & vbCrLf & nu
Close #1

Trang 217
End If
End Sub

'CHUYEN MOT MUC


Private Sub menu_upswitchentry()
Dim news As entry
Dim banghi As Byte

Select Case prevent


Case 1
Open filename For Random As #1 Len = Len(news)
Case 2, 3
Open filename2 For Random As #1 Len = Len(news)
End Select
banghi = LOF(1) \ Len(news)
menucon = True
vitri = vitri - 1
cancle = True
danhso = False
If vitri >= 1 Then
Get #1, vitri, news
st1 = news.name
st = news.name
nu = news.number
tbnhap.Text = st & vbCrLf & nu
Close #1
Exit Sub
Else
vitri = banghi 'vitri + 1
Get #1, vitri, news
st1 = news.name
st = news.name
nu = news.number
tbnhap.Text = st & vbCrLf & nu
Close #1
End If
End Sub

'DI CHUYEN GIUA CAC MUC TRONG DANH SACH SO CO DINH


Private Sub menu_downlistdial()
Dim news As entry

Trang 218
Laäp Trình Web Vôùi Visual Basic

Dim banghi As Byte

Open filefixed For Random As #1 Len = Len(news)


banghi = LOF(1) \ Len(news)
If banghi = 0 Then
listdial = False
Close #1
Exit Sub
End If
vitri = vitri + 1
If vitri <= banghi Then
Get #1, vitri, news
tbnhap.Text = news.name & vbCrLf & news.number
Else
vitri = 1
Get #1, vitri, news
tbnhap.Text = news.name & vbCrLf & news.number
End If
Close #1
End Sub

'DI CHUYEN GIUA CAC MUC TRONG DANH SACH SO CO DINH


Private Sub menu_uplistdial()
Dim news As entry
Dim banghi As Byte

Open filefixed For Random As #1 Len = Len(news)


banghi = LOF(1) \ Len(news)
If banghi = 0 Then
listdial = False
Close #1
Exit Sub
End If
vitri = vitri - 1
If vitri >= 1 Then
Get #1, vitri, news
tbnhap.Text = news.name & vbCrLf & news.number
Else
vitri = banghi
Get #1, vitri, news
tbnhap.Text = news.name & vbCrLf & news.number

Trang 219
End If
Close #1
End Sub

'THU TUC KIEM TRA BO NHO


Private Sub check(so As Boolean)
Dim news As entry
Dim banghi As Byte
Dim j As Integer
Dim max As Integer
Dim max1 As Integer

Open filename For Random As #1 Len = Len(news)


banghi = LOF(1) \ Len(news)
For j = 1 To banghi
Get #1, j, news
If news.location < 100 Then
max = max + 1
Else
max1 = max1 + 1
End If
Next j
If so = 0 Then
tbnhap.Text = (100 - max) & " Unused Locations"
Else
tbnhap.Text = (155 - max1) & " Unused Locations"
End If
Close #1
End Sub

'DI CHYEN GIUA DANH SACH CAC MANG UU TIEN


Private Sub preferredlist(so As Integer, chuoi As String)
Dim networks As netselect
Dim banghi As Byte
Dim j As Integer

Open filename6 For Random As #1 Len = Len(networks)


Open filetam For Random As #2 Len = Len(networks)
banghi = LOF(1) \ Len(networks)
If banghi = 0 Then
networks.mang = chuoi

Trang 220
Laäp Trình Web Vôùi Visual Basic

Put #2, 1, networks


Else
For j = 1 To banghi
If so <> j Then
Get #1, j, networks
Put #2, j, networks
Else
networks.mang = chuoi
Put #2, j, networks
Exit For
End If
Next j
Do While j <= banghi
Get #1, j, networks.mang
Put #2, j + 1, networks.mang
j=j+1
Loop
End If
If lo > banghi Then
networks.mang = st
Put #2, banghi + 1, networks
End If
Close #1
Close #2
Kill filename6
Name filetam As filename6
End Sub

'THU TUC DI CHUYEN MOT MANG UU TIEN DEN VI TRI MOI


Private Sub movenew(oldlo As Integer, newlo As Integer)
Dim networks As netselect
Dim i As Integer
Dim banghi As Integer
Dim chuoi As String

Open filename6 For Random As #1 Len = Len(networks)


Open filetam For Random As #2 Len = Len(networks)
banghi = LOF(1) \ Len(networks)

If oldlo = newlo Then


Close #1

Trang 221
Close #2
tbnhap.Text = "Completed"
Exit Sub
End If

If newlo >= banghi Then


For i = 1 To oldlo - 1
Get #1, i, networks
Put #2, i, networks
Next i
Get #1, oldlo, networks
chuoi = networks.mang
For i = oldlo + 1 To banghi
Get #1, i, networks
Put #2, i - 1, networks
Next i
networks.mang = chuoi
Put #2, banghi, networks.mang
End If

If oldlo < newlo And newlo < banghi Then


For i = 1 To oldlo - 1
Get #1, i, networks
Put #2, i, networks
Next i
Get #1, oldlo, networks
chuoi = networks.mang
For i = oldlo + 1 To newlo
Get #1, i, networks
Put #2, i - 1, networks
Next i
networks.mang = chuoi
Put #2, newlo, networks.mang
i = newlo + 1
Do While i <= banghi
Get #1, i, networks
Put #2, i, networks
i=i+1
Loop
End If

Trang 222
Laäp Trình Web Vôùi Visual Basic

If oldlo > newlo Then


For i = 1 To newlo - 1
Get #1, i, networks
Put #2, i, networks
Next i
Get #1, oldlo, networks
Put #2, newlo, networks
For i = newlo To oldlo - 1
Get #1, i, networks
Put #2, i + 1, networks
Next i
i = oldlo + 1
Do While i <= banghi
Get #1, i, networks
Put #2, i, networks
i=i+1
Loop
End If
Close #1
Close #2
Kill filename6
Name filetam As filename6
tbnhap.Text = "Completed"
End Sub

'THU TUC XOA MOT MANG UU TIEN


Private Sub xoa(loca As Integer)
Dim networks As netselect
Dim j As Integer
Dim i As Integer
Dim banghi As Byte

Open filename6 For Random As #1 Len = Len(networks)


Open filetam For Random As #2 Len = Len(networks)
banghi = LOF(1) \ Len(networks)
For j = 1 To banghi
If j <> loca Then
Get #1, j, networks
Put #2, j, networks
Else
Exit For

Trang 223
End If
Next j
Do While j < banghi
Get #1, j + 1, networks
Put #2, j, networks
j=j+1
Loop
Close #1
Close #2
Kill filename6
Name filetam As filename6
tbnhap.Text = "Completed"

End Sub
'**** Ham dung phim so trong menu Quick Access *****
Private Function clickquickaccess(so As Integer) As Integer
Dim menuaccess As access
Open filename3 For Random As #1 Len = Len(menuaccess)
Get #1, so, menuaccess
tbnhap.Text = Trim(menuaccess.feature)
clickquickaccess = menuaccess.thutu
'orderinquick = 1
Close #1
End Function
'**** Thu tuc dung phim trong menu Message list
Private Sub clickmessage(so As Integer)
Dim message As messages
Dim banghi As Byte
Open filename4 For Random As #1 Len = Len(message)
banghi = LOF(1) \ Len(message)
If banghi < so Then
tbnhap.Text = "Invalid Msg Number"
messagelist = False
Else
Get #1, so, message
tbnhap.Text = Trim(message.tin)
messagenumber = 2
End If
Close #1
End Sub
Private Sub store_message()

Trang 224
Laäp Trình Web Vôùi Visual Basic

Dim message As messages


Dim banghi As Byte
Open filename4 For Random As #1 Len = Len(message)
banghi = LOF(1) \ Len(message)
If taomoi = True Then
banghi = banghi + 1
message.tin = st
message.sothutu = banghi 'messagenumber
Put #1, banghi, message 'messagenumber
Else
Get #1, messagenumber, message
message.tin = st
Put #1, messagenumber, message
End If
tbnhap.Text = "Stored"
'message1 = False
Close #1

End Sub
Private Sub delete_message()
Dim message As messages
Dim banghi As Byte
Dim j As Integer
Open filename4 For Random As #1 Len = Len(message)
banghi = LOF(1) \ Len(message)
Open filetam For Random As #2 Len = Len(message)
For j = 1 To banghi
If j <> messagenumber Then
Get #1, j, message
Put #2, j, message
Else
Exit For
End If
Next j
Do While j < banghi
Get #1, j + 1, message
Put #2, j, message
j=j+1
Loop
tbnhap.Text = "Deleted"
Close #1

Trang 225
Kill filename4
Close #2
Name filetam As filename4
End Sub

'KHOI TAO CONTROL


Private Sub UserControl_Initialize()
Dim news As entry
Dim banghi As Integer
Dim menuaccess As access
Dim k As Integer
Dim message As messages
Dim networks As netselect

Label2.Caption = Left(Time, 5)
tbnhap.Text = "Menu"
unlocked = "1234"
securitycode = "000000"
voicemailnumber = "4321"
servicecentre = "130"
pin2code = "13579"
expiryperiod = "24"
barpassword = "6789"
volume.Picture = volume1(2).Picture
vol = 3
prevent = 1
Open filename3 For Random As #1 Len = Len(menuaccess)
menuaccess.feature = "Find Name?"
menuaccess.thutu = 1
Put #1, 1, menuaccess

menuaccess.feature = "Add to SIM?"


menuaccess.thutu = 4
Put #1, 2, menuaccess

menuaccess.feature = "Call Voicemail?"


menuaccess.thutu = 12
Put #1, 3, menuaccess

menuaccess.feature = "Battery Meter?"


menuaccess.thutu = 11

Trang 226
Laäp Trình Web Vôùi Visual Basic

Put #1, 4, menuaccess

menuaccess.feature = "Show Time/Date?"


menuaccess.thutu = 8
Put #1, 5, menuaccess

menuaccess.feature = "Adjust Ring?"


menuaccess.thutu = 6
Put #1, 6, menuaccess

menuaccess.feature = "Switch Line 1/2?"


menuaccess.thutu = 7
Put #1, 7, menuaccess

menuaccess.feature = "Vibrate On/Off?"


menuaccess.thutu = 9
Put #1, 8, menuaccess

menuaccess.feature = "Change Band?"


menuaccess.thutu = 10
Put #1, 9, menuaccess
Close #1

Open filename For Random As #1 Len = Len(news)


news.name = "NHA"
news.number = "8402631"
news.location = 1
Put #1, 1, news

news.name = "HUNG"
news.number = "8570726"
news.location = 101
Put #1, 2, news
Close #1

Open filename4 For Random As #2 Len = Len(message)


message.tin = "HELLO"
message.sothutu = 1
Put #2, 1, message
Close #2

Trang 227
Open filename5 For Random As #1 Len = Len(networks)
networks.mang = "FPT"
Put #1, 1, networks

networks.mang = "Phuong Nam"


Put #1, 2, networks

networks.mang = "SaigonNet"
Put #1, 3, networks

networks.mang = "VNN"
Put #1, 4, networks
Close #1

Open filefixed For Random As #1 Len = Len(news)


banghi = LOF(1) \ Len(news)
If banghi = 0 Then
news.name = "NHA"
news.number = "8402631"
news.location = 1
Put #1, 1, news
End If
Close #1

Open filename6 For Random As #1 Len = Len(networks)


banghi = LOF(1) \ Len(networks)
If banghi = 0 Then
networks.mang = "FPT"
Put #1, 1, networks
End If
Close #1
End Sub

'KHI CONTROL KET THUC


Private Sub UserControl_Terminate()

Kill filename
Kill filename3
Kill filename4
Kill filename5
Kill filename6

Trang 228
Laäp Trình Web Vôùi Visual Basic

Kill filefixed
End Sub

Trang 229
PHAÀN IV:
KEÁT LUAÄN

Vôùi nhöõng kieán thöùc laõnh hoäi ñöôïc ôû tröôøng vaø söï giuùp ñôõ cuûa caùc Thaày, Coâ trong
khoa coâng ngheä thoâng tin tröôøng Ñaïi Hoïc Kyõ Thuaät Thaønh Phoá Hoà Chí Minh. Vaø söï
höôùng daãn giuùp ñôõ taän tình cuûa thaày Nguyeãn Cao Trí, ñeán ñaây chuùng em xin hoaøn
thaønh luaän vaên cuûa mình.
Tuy luaän vaên hoaøn thaønh chöa ñöôïc lôùn lao gì, nhöng em cuõng hy voïng luaän vaên
naøy cuõng laø moät phaàn taøi lieäu tham khaûo nho nhoû giuùp cho nhöõng ngöôøi hoïc vaø laäp
trình Web vôùi Visual Basic.

Trang 230
Laäp Trình Web Vôùi Visual Basic

PHAÀN V :
TAØI LIEÄU THAM KHAÛO
 Kyõ naêng laäp trình Visual Basic 6.0.
 Microsoft Developer Network.

Trang 231

You might also like