.


:




:

































 

 

 

 


: If-Then-Else




07-09-If-Then-Else.docm - . 7.11.

VBA - . If - Then - Else.

(. 7.4.)

7.4.

=
<>
>
<
>=
<=
Like
Is

( 7.13.), . 18 - " 18 ", 18 - " 18 ".

a = InputBox(" ") If a < 18 Then MsgBox (" 18") If a >= 18 Then MsgBox (" 18 ")

7.13. If - Then

- . , ? End If ( 7.14.)

a = InputBox(" ") If a < 18 Then MsgBox (" 18") MsgBox (" ") End If If a >= 18 Then MsgBox (" ")

7.14. End If

, 18 .

If - Then - Else ( 7.15). If - Then 7.13. .

a = InputBox(" ") If a < 18 Then MsgBox (" 18") _ Else MsgBox (" 18")

7.15. Else

Else . , - 7.16.

a = InputBox(" ") If a < 18 Then MsgBox (" 18") MsgBox (" ") Else MsgBox (" 18") MsgBox (" ") End If

7.16.

If . , . , , , - , . , , , . And, "". And - 7.17.

UserName = InputBox(" ") UserPass = InputBox(" ") If UserName = "" And UserPass = "12345" Then MsgBox (" ") Else MsgBox (" ") End If

7.17. And

: " 12345".

Or ( "") , . , , , , , - - . 7.18.

UserName = InputBox(" ") If UserName = "" Or UserName = "" Or _ UserName = "" Then MsgBox (" , " & UserName) Else MsgBox (" !") End If

7.18. Or

And Or . Not () . , "".

If - Then - Else.

Text ә
Font қ
properties қ
An object
Method ә
An object
Treatment өң

 

 

.

  1. ?
  2. , ?
  3. ?
  4. ?
  5. ?
  6. ?


1. ____ :

  1. HTTP
  2. HTML
  3. Download
  4. IP

 

2. ?

  1. <S>
  2. <TR>
  3. <BR>
  4. <P>

 

3. HTML?

  1. , <table>
  2. , <draw table>
  3. , HTML
  4. , MS Word

 

4. <H1 Align=center> ?

 

5. VBA, Office?

  1. Office
  2. ,
  3. VBA C
  4. VBA

 

  1. 6. VBA shorthand PRINT? $$ (?)
  2. P
  3. (!)

 

7. , :

  1. Single
  2. Long
  3. Integer
  4. Double

 

8. MySalary(IF Revenue>=1000000 THEN MySalary=500000 ELSE MySalary=Poor me! END IF), :

  1. Variant
  2. Currency
  3. Single
  4. Double

: VBA (5-6 )

.

1. . . , ., , 2008.

2 Internet : http://www.intuit.ru/studies/courses/3735/977/info

 

 

3 19-20 , . 4-, 3 5,7 2018-2019 .

Selection

Selection, Range. , .

, Application.Selection , , . , - .

Selection . , . , .

, .

, . , ( , ..) . , , , .

Selection .

Selection.Text = ""

Selection , . , , , , . , , .

Selection.

Selection





:


: 2018-10-17; !; : 166 |


:

:

, ,
==> ...

1662 - | 1648 -


© 2015-2024 lektsii.org - -

: 0.011 .