. , , ,

,,,

, (2.0) — ,

:

1

1. .

2. () , :

TAB numeric

FIO character

POL character

DATA date

OBR logical

LANG numeric - . , - .

STAG numeric

DETI numeric

SRZAR numeric

COMP logical

TAB, FIO, DATA, OBR , 10 .

3.


.


:

2


1. FoxPro.

2. () , :


TAB numeric

FIO character

POL character

DATA date

OBR logical

LANG numeric - . , - .

STAG numeric

DETI numeric

SRZAR numeric

COMP logical


, 250 .

3.


.


:

3


1. . ( ).

2. () , :


TAB numeric

FIO character

POL character

DATA date

OBR logical

LANG numeric - . , - .

STAG numeric

DETI numeric

SRZAR numeric

COMP logical


, 1954 .

3.


.


:

4


1. . BROWSE. .

2. () , :


TAB numeric

FIO character

POL character

DATA date

OBR logical

LANG numeric - . , - .

STAG numeric

DETI numeric

SRZAR numeric

COMP logical


(), .


3.


.


:

5


1. (DISPL, LIST, ).

2. () , :


TAB numeric

FIO character

POL character

DATA date

OBR logical

LANG numeric - . , - .

STAG numeric

DETI numeric

SRZAR numeric

COMP logical


(), .


3.


.


:

6


1. (EDIT, CHANGE APPEND).

2. () , :


TAB numeric

FIO character

POL character

DATA date

OBR logical

LANG numeric - . , - .

STAG numeric

DETI numeric

SRZAR numeric

COMP logical


(), 3- .


3.


.


:

7


1. . .

2. () , :


TAB numeric

FIO character

POL character

DATA date

OBR logical

LANG numeric - . , - .

STAG numeric

DETI numeric

SRZAR numeric

COMP logical


.


3.


.


:

8


1. (LOCATE, CONTINUE).

2. () , :


TAB numeric

FIO character

POL character

DATA date

OBR logical

LANG numeric - . , - .

STAG numeric

DETI numeric

SRZAR numeric

COMP logical

BROWSE- 10 . -.


3.


.


:

9


1. (MODI COMM, DO).

2. () , :


TAB numeric

FIO character

POL character

DATA date

OBR logical

LANG numeric - . , - .

STAG numeric

DETI numeric

SRZAR numeric

COMP logical


.


3.


.


:

10


1. FoxPro. STORE. .

2. () , :


TAB numeric

FIO character

POL character

DATA date

OBR logical

LANG numeric - . , - .

STAG numeric

DETI numeric

SRZAR numeric

COMP logical


FIO, DATA, SRZAR, COMP .

3.


.


:


11


1. FoxPro. IF CASE.

2. () , :


TAB numeric

FIO character

POL character

DATA date

OBR logical

LANG numeric - . , - .

STAG numeric

DETI numeric

SRZAR numeric

COMP logical


BROWSE- . -.


3.


.


:


12


1. FoxPro. DO WHILE, LOOP, EXIT.

2. () , :


TAB numeric

FIO character

POL character

DATA date

OBR logical

LANG numeric - . , - .

STAG numeric

DETI numeric

SRZAR numeric

COMP logical


, , : , , , .


3.


.


:


13


1. FoxPro. . (LEN(), AT(), ALLTRIM(), SPACE() ).

2. () , :


TAB numeric

FIO character

POL character

DATA date

OBR logical

LANG numeric - . , - .

STAG numeric

DETI numeric

SRZAR numeric

COMP logical


( ) , 1966 .


3.


.


:


31


1. FoxPro. (FILE ( ), EOF ( ), FOUND ( ), RECNO ( ), RECCOUNT ( ) ) .

2. () , :


TAB numeric

FIO character

POL character

DATA date

OBR logical

LANG numeric - . , - .

STAG numeric

DETI numeric

SRZAR numeric

COMP logical

BROWSE- , . -.


3.


.


:


14


1. FoxPro.

2. () , :


TAB numeric

FIO character

POL character

DATA date

OBR logical

LANG numeric - . , - .

STAG numeric

DETI numeric

SRZAR numeric

COMP logical

BROWSE- , . -, FIO 15 .


3.


.


:

15


1. . (GO TOP/BOTTOM, SKIP) , .

2. () , :


TAB numeric

FIO character

POL character

DATA date

OBR logical

LANG numeric - . , - .

STAG numeric

DETI numeric

SRZAR numeric

COMP logical


, .


3.


.


:


16


1. ( ).

2. () , :


TAB numeric

FIO character

POL character

DATA date

OBR logical

LANG numeric - . , - .

STAG numeric

DETI numeric

SRZAR numeric

COMP logical


, .


3.


.


:

17


1. (LIGHTBAR ).

2. () , :


TAB numeric

FIO character

POL character

DATA date

OBR logical

LANG numeric - . , - .

STAG numeric

DETI numeric

SRZAR numeric

COMP logical


( ) , .


3.


.


:

19


1. , .

2. () , :


TAB numeric

FIO character

POL character

DATA date

OBR logical

LANG numeric - . , - .

STAG numeric

DETI numeric

SRZAR numeric

COMP logical


, () .


3.


.


:

20


1. /, INPUT, ACCEPT, WAIT, ?.

2. () , :


TAB numeric

FIO character

POL character

DATA date

OBR logical

LANG numeric - . , - .

STAG numeric

DETI numeric

SRZAR numeric

COMP logical


, 500 .


3.


.


:

21


1. /. @SAYGET. .

2. () , :


TAB numeric

FIO character

POL character

DATA date

OBR logical

LANG numeric - . , - .

STAG numeric

DETI numeric

SRZAR numeric

COMP logical


.


3.


.


:

22


1. SET. (DATE, TALK, MESSAGE, FILTER, PROCEDURE).

2. () , :


TAB numeric

FIO character

POL character

DATA date

OBR logical

LANG numeric - . , - .

STAG numeric

DETI numeric

SRZAR numeric

COMP logical


.


3.


.


:

23


1. FoxPro. . , , .

2. () , :


TAB numeric

FIO character

POL character

DATA date

OBR logical

LANG numeric - . , - .

STAG numeric

DETI numeric

SRZAR numeric

COMP logical


.


3.


.


:

24


1. . .

2. () , :


TAB numeric

FIO character

POL character

DATA date

OBR logical

LANG numeric - . , - .

STAG numeric

DETI numeric

SRZAR numeric

COMP logical

BROWSE- (). -.


3.


.


:

25


1. . . .

2. () , :


TAB numeric

FIO character

POL character

DATA date

OBR logical

LANG numeric - . , - .

STAG numeric

DETI numeric

SRZAR numeric

COMP logical


.


3.


.



:

26


1. . . . .

2. x y, case. :




3.


.


:

27


1. . .

2. x y, case. :




3.


.


:

28


1. ( ).

2. x y, case. :




3.


.


:

29


1. .

2. () , :


TAB numeric

FIO character

POL character

DATA date

OBR logical

LANG numeric - . , - .

STAG numeric

DETI numeric

SRZAR numeric

COMP logical


, .


3.


.


:

30


1. 1:1 1:N FoxPro.

2. x y, case. :



3.


.




:

18


1. (POPUP ).


2. x y, case. :



3.


.





2
. x y, case. :


2. x y, case. :




2. x y, case. :




2. x y, case. :




2. x y, case. :




2. x y, case. :




2. x y, case. :





2. x y, case. :





2. x y, case. :




2. x y, case. :




2. x y, case. :




2
. x y, case. :




2. x y, case. :



1

3. BROWSE- , [350;700). -. -nadbavka: 4% . , .



2

3. BROWSE- (). -. , . .



3

3. BROWSE- (). -. , .



4

3. BROWSE- , 3- . -. -nadbavka: 3% ( ).



5

3. BROWSE- , ‘’. -. , 10 --10% .



6

3. BROWSE- , 10 . -. -, , , 100-10 % .



7

3. BROWSE- . -, - -10% .



8

3. BROWSE- , , . -. 15 , 10 % . .



9

3. BROWSE- (), . -. . .



10

3. BROWSE- (), . -. , . .



11

3. BROWSE- , . -. , . ̻ ƻ.



12

3. BROWSE- 10 , . -. , . .



13

3. BROWSE- , . NADBAVKA, 15% 30% , 2 . -.



14

3. BROWSE- , . NADBAVKA, : 25 20% . -.



15

3. BROWSE- , . SUBSIDIA, 15% , 3 . -.



16


3. FIO, DATA, SRZAR, POL ,



17

3. ( ) , 40 . .



18


3. ( ) (), .



19


3. BROWSE- 10 , . -. BROWSE- , , 50 .



20

3. BROWSE- , . -. BROWSE- . , .


21


3. BROWSE- . -. BROWSE- , ().


22

3. BROWSE- (), . -. BROWSE- . , . .


23


3. BROWSE- , . -. BROWSE- . , . .


24


3. BROWSE- , 3- . -. BROWSE- . -: 2 % . .


25


3. BROWSE- , 3- . -. BROWSE- . -: 15 % , 150. . .


26


3. BROWSE- , 3- . -. BROWSE- . : 3% ()


27

3. . . , .



28


3. 2 . .

, .


29


3. 2 . . .

, .



30


3. 2 . . . , .



31


3. 2 . . . , .



32


3. 2 . , 10 . , 10, . , .



33


3. , KADR1 KADR2 TAB



34


3. , BRIG1 BRIG2 KOD



35


3. SUPPLY. _ _.



36


3. .





. , FoxPro, . FoxPro .


, .

. (relation). .

. , . . , . .

:

  1. (relations);

  2. (relation closure).

, , .

:

  1. . . . , , . . , , , , , ..;

  2. ;

  3. ( );

  4. ;

  5. ;

  6. .

: (entity integrity rule) (referential integrity rule).

, , .. . , , . , , .

, . . , , .. null. , , , .

:

R {A,A,,A}. A D, A, 1<=i<=n. A dom(A). . . D=DDD.

r R {t,t,,t} R D; tr : t(A) D, 1<=i<=n. .

FoxPro, Fox Software . FoxPro2.6 (), Windows.


Visual FoxPro 6.0


Character

1 byte per character to 254

Currency

Monetary amounts (- )

8 bytes - 922337203685477.5807 to 922337203685477.5807

Date

, , , 8 bytes

When using strict date formats, {^0001-01-01}, January 1st, 1 A.D to {^9999-12-31}, December 31st, 9999 A.D.

DateTime

, , , ,

8 bytes

When using strict date formats, {^0001-01-01}, January 1st, 1 A.D to {^9999-12-31}, December 31st, 9999 A.D., plus 00:00:00 a.m. to 11:59:59 p.m.

Logical

Boolean true false

1 byte True (.T.) or False (.F.)

Numeric

Integers or fractions( ())

8 bytes in memory;
1 to 20 bytes in table

- .9999999999E+19 to .9999999999E+20

Variant

A variant can contain any of the Visual FoxPro data types and the null value. Once a value is stored to a variant, the variant asosumes the data type of the data it contains. Variants are designated with an e prefix in language syntax ( FoxPro () ).

See data types above. . .

See data types above. . .


FoxPro ( 60, ):

.dbf - ;

.fpt - memo- ;

.idx - ;

.cdx - ;

.prg - , ;

.mem - ;

.fxp - prg- ;

.pjx - .


1. FOXPRO: -


FoxPro :

- ;

- - ;

  • .


. . , . , . , , , xBase, . , .

- .

FoxPro , . - . , .


F10

Enter

Esc


F1-F10 , .

(, CTRL+F2 - , CTRL+D - )

:

FoxPro 2.6

SYSTEM FILE EDIT DATABASE RECORD PROGRAM WINDOW

- , . , - Tab. "", . , . Ok ( ). Cancel ( ). Save () . .

.

System- FoxPro,

:

About FoxPro - .

Help - .

.

- Enter.

.

- F1.

Macros - F1 - F10.

Filer - -

.

- Tab. -

().

- , ,

. - .

Calculator - .

Calendar-Diary - .

( ), (PgUp, PgDn),

(Shift +PgUp, Shift+PgDn), - .

- ( - Tab, -Shift Tab).

Special Characters - .

ASCII Chart - ASCII-.

Capture - .

Puzzle -

File-:

New -

Open -

Close -

Save -

Save as -

Revert -

Printer Setup -

Print -

Quit -

(New) : , , , , . () .

Edit .


Undo - ,

Redo - ,

Cut - ,

o - ,

Paste - ,

Clear - ,

Select All - ,

Goto Line - ,

Find - ,

Find Again - ,

Replace and Find Again - ,

Replace All - ,

Preference - .


Database ,

Setup - , , ,

Browse - ,

Append From - ,

Copy - ,

Sort - ,

Total - ,

Average - ,

Count - ,

Sum - ,

Calculate - ,

Report - ,

Pack - ,

Reindex - .


Record-

Append - ,
Change - ,
Goto - ,
Locate - ,
Continue - ,
Seek - ,
Replace - () ,

Delete - ,

Recall - .


Program

Do - ,

Cancel - ,

Resume - ,

Compile - ,

Generate - ,

FoxDoc - ,

FoxGraph - .


Window-

Hide - ,

Clear - ,

Move - ,

Size, Zoom - ,

Cycle - ,

Color - ,

Command - ,

Debug - ,

Trace - ,

View - View

- (Help - F1).


, , , , View- Record- :

- , ;

- , ;

- ;

- ;

- ;

- ,

:

<> - ,

-

- ,

-

- :

- :

- ;

- ;

- ;

- , ;

-

;

- , ;

-


Record- . : Browse- :

^ N - , ^ - , ^W- .

Database- :

- Window/View;

- , .

-

.

Help-.

, , ( Command-) ( prg-).


2. FOXPRO

FoxPro, Command- . . .

FOXPRO:


_ [<>] [< ]

[ FR<>] [WHILE< >]


< > - :

ALL - ;

REST - ;

NEXT - N ;

RECORD - N;

FR<> - ,

;

WHILE< > - ,

.

:

LIST ALL FIELDS num, name FOR name = 'A'


- ";".

FOXPRO , . - , .

:

SET < > ON|OFF

SET < 1 > TO < 2 >

ON|OFF , , .. ,

.

:

SET TALK OFF

;

SET PROCEDURE TO a:\proc1 .

2.

.


.

R<_> - .

TAB numeric

FIO character

POL character

DATA date

OBR logical

LANG numeric - . , - .

STAG numeric

DETI numeric

SRZAR numeric

COMP logical


MODIFY STRUCTURE - .


, - .


APPEND [BLANK] -

([BLANK] - ).

INSERT [BLANK] [BEFORE] - [BEFORE]

.

CHANGE [< >] [FIELDS< >] [WHILE <>]

[ FOR < >] - .

DELETE [ ] [WHILE <>][FR<>]

.

BROWSE... - .

. BROWSE .


.

DISPLAY LIST

DISPLAY [< >][<>]FOR[<>]WHILE[<>]

[OFF] [TO PRINT / TO FILE<>]

LIST - , DISPLAY- .

:

DISPLAY REST FOF fio= ’’

LIST '', fio FOR dolg = ""


ERASE <> - ;

ZAP - ;

DELETE [< >] [WHILE< >] [FOR< >] - ;

PACK - , ;

RECALL [< >] [WHILE< >] [FOR< >] - ;

. , ,

SET DELETE ON.

PACK ,

.


SET FILTER [<>] - FOR- ( ).

SET FILTER TO - .

:

REPLACE [<>] [WHILE<>] [FR<>] <1>

WITH<>[,<2> WITH<> ] [ADDITIVE]

- .


: REPLACE zarp with zarp* 1.25 for dolg=””


LOCATE FR<> [<>] [WHILE<>] -

FOR- ,

.

CONTINUE -


:

USE KADR

LOCATE FOR stag > 12

DO WHILE ! EOF() &&

? FIO

CONTINUE

ENDDO


Command-. , , .

3.


.prg. FoxPro ,

MODIFY COMMAND < >

MODI COMM ( ) prg- . . ^W .

MODI <>.

DO < >

. .

. , , , 200.

SET TALK OFF

SET DATE BRITISH

USE KADR

LOCATE FOR Zarp < 200

DO WHILE !EOF() &&

DISPL

CONTINUE

ENDDO


4. BROWSE

BROWSE . 20 . .

.

BROWSE

[FIELDS] [FR<1>]

[FORMAT] [FREEZE<>]

[,< 1 >[,<2>]] [LAST]

[LEDIT / REDIT] [LOCK]

[LPARTITION] [NOAPPEND]

[NOCLEAR] [NODELETE]

[NOEDIT/NOMODIFY] [NOLGROD / NORGRIG]

[NOLINK] [NOMENU]

[NOOPTIMIZE] [NORMAL]

[NOWAIT] [PARTITION]

[REST] [PREFERENCE]

[TIMEOUT] [ITL<2>]

[NOOPTIMIZE] [WHEN< yc3>]

[window<>] [NOWAIT]

[VALID[F:] [ERROR]

[COLOR SCHEME / COLOR< >]


.

1.

FIELDS< > - ( - ).

:

:R - ;

:< N> - ;

:=< L1> - ;

:F - ;

:=<2> - ;

:=<2> - ;

:=<> - ;

:=<1>,<2>[:] - ;

:W= - .

, .

2.

FR < 1> - ;

, <1>;

REST - ;

<1>[,<2>] -

.

LOCK BROWSE - ,

( ^);

PARTITION - ,

LEDIT/REDIT -

();

LPARTITION - ;

NOLINK - ;

NOLGRID/NORGRID - .

4.

VALID<2>[ERROR] - ;

WHEN<3> - ;

NOAPPEND - Ctrl-N ;

NOEDIT/NOMODIFY - ;

NODELETE - ;

FREEZE<> - .

5. BROWSE-

LAST - ;

PREFERENCE FORMAT - ;

NOCLEAR - ;

NOMENU - ;

TIMEOUT - ;

TITLE - ;

WINDOW - .


:

Set talk off

set date British

use kadr.dbf

browse ;

title '^t- ^n- ^w-';

fields ;

fio :h='' :20, ;

dolg :h='', ;

zarp :h='' ,;

birth :h=' ' ,;

pol :h='' ,;

adress :h='' ,;

godzarp = zarp*12 :h='.' :p='#####,##'

pack

close all


5. -

/


? / ??


? / ?? [<1>] [< N>][,< 2>...]


? [<1>] [,] ,

?? - ; AT - .


TEXT

TEXT

< >

ENDTEXT

, , .


\ \\

\ < > - .

\\ < > - .


-

INPUT <> <>

ACCEPT <> < >

WAIT [<>] [< >]

[TIMEOUT] [WINDOW] [CLEAR]

HELP FoxPro.


/

@ ... SAY ... GET

:

@

[SAY

[PICTURE] [COLOR SCHEME /

COLOR< >]]

[GET

[PICTURE]

[DEFAULT<2>] [ENABLE / DISABLE]

[MESSAGE] [[OPEN] WINDOW ]

[RANGE [<3>][<4>]]

[SIZE,]

[VALID/[ERROR]]

[WHEN]

[COLOR SCHEME/COLOR< >]]


Y,X - , . @ Y X.


@ Y,X SAY - <>

( , .);

"+";

@ Y,X GET -

( );

DEFAULT <2> - ;

;

ENABLE/DISABLE - / get-;

MESSAGE <> -

;

RANGE<3><4> - ;

SIZE - ,

;

VALID... - ;

WHEN -

;

[OPEN] WINDOW - memo-;

COLOR SCHEME /COLOR< >-

-.


SAY GET . GET . GET READ. GET - .


:

1) 10 , 15 ' - ', ( [100.00,1778.00] ).

X = 100.00

@ 10,15 SAY ' - ' GET X RANGE 100.00,1778.00

READ

2) 10

@ 10,15 SAY ' - ' GET X VALID MOD(X/10) = 0

READ

PICTURE :

- ;

L - T / F;

N - ;

- ;

Y - Y/N;

9 - , "+","-" -

;

# - , "+","-";

! - ;

* - ;

. - .


:

@ 10,8 SAY ' - ' PICTURE ###.##'


3) CADR.FMT, CADR.DBF. :


CARD.FMT

@ 4, 30 SAY ' '

@ 5, 9 11, 70 DOUBLE

@ 5, 41 SAY ‘ '+D(D( )) + ' '

@ 6, 18 SAY ', : ' GET fio

@ 7, 18 SAY ‘ : ' GET tab

@ 7, 40 SAY : ' GET Dolg

@ 10, 12 SAY ' - ^End, - Esc'

SET FORMAT < >.

:

SET FORMAT TO CARD.FMT

CHANGE

SET FORMAT TO


6.


. FoxPro , , , .

FoxPro , ( ). .

:

<> = <>

STORE <> < :.

:

a = b^2 + 2*c 3*a

STORE 0 a,b,c a,b,c


.

:

DECLARE / DIMENSION < >([,]) .


:

DIMENSION (3,4), b(4)

3600. :


IF : DO CASE:

IF <> DO CASE

<> CASE <1>

[ELSE <>

<>] CASE <2>

ENDIF <>

[OTHERWIZE

<>]

ENDCASE


IIF ( ) (. )


:

1. .

CLEAR

INPUT “ X” TO X

INPUT “ Y” TO Y

IF X > Y

max = X

ELSE

max = Y

ENDIF

? “ : ”, max

WAIT

2
. Y.


CLEAR

INPUT “ X” TO X

DO CASE

CASE X < 0

Y = -2*X^2 +5*X

CASE X>=0 AND X < 5

Y = 15 2*X^2

CASE X>=5

Y = ABS(12*X SIN(12))

ENDCASE

? "Y = " ,Y

CLOSE ALL



DO WHILE <> - EXIT

<> - LOOP

ENDDO


DO WHILE .T. <> ENDDO .


FOR <> = [STEP ]

<> ENDFOR


SCAN [<>] [FOR<>] [WHILE<>] <> ENDSCAN -

, .


:

Kadr

''.

1) USE Kadr 2) USE Kadr

LOCATE FOR fio = '' SCAN FOR fio= ''

DO WHILE ! EOF( ) <>

<> ENDSCAN

CONTINUE

ENDDO



FoxPro , -. PROCEDURE <> RETURN. prg- SET PROCEDURE TO < >.

:

DO < > [WITH < >] [IN FILE <>], < > - . .


PARAMETERS<>.

- FUNCTION < >, . -

RETURN <> , .



FoxPro , - . PROCEDURE <> RETURN. prg- SET PROCEDURE TO < >. :


DO < > [WITH < >] [IN FILE <>]


PARAMETERS<>.

- FUNCTION< >, . RETURN<>, .

,

.



1. 1, :

21 - ( STATE)

22 -

31 - ( SOTR)

32 -

4 - ()

info - ( ).


1.


*********** Kadr ***********

PROCEDURE p21

SELECT a

CLEAR

= 0

@ 5, 10 SAY ' : ' GET PICTURE '###'

READ

@ 6, 2 SAY ' '

LOCATE ALL FOR tab = c

DO WHILE ! EOF( )

? ' - ', dolg, ' - ', zarp

CONTINUE

ENDDO

WAIT ' Enter ' WINDOW

CLEAR

RETURN


2.


********* **************

PROCEDURE info

CLEAR

@ 8, 15 20, 60 DOUBLE &&

@ 9, 25 SAY ' ' &&

@ 12, 20 SAY ' '

WAIT ' Enter ' WINDOW &&

CLEAR

RETURN


7.

. FoxPro . , - - .

- , , . , , DO CASE, DO WHILE .. . , .

LIGHTBAR - :

@ Y, X PROMPT <> [MESSAGE] -

Y,X ,

MESSAGE,

SET MESSAGE .

MENU TO <> - , .


PULLDOWN - ( )

MENU BAR <>, -

BAR-,

< >,

, N- .

MENU <1>, <>, <2> -

(POPUP-)

READ MENU BAR TO <1>, <2> - .



1) ********** LIGHTBAR *******

SET TALK OFF

SET DATE BRITISH

USE KADR.DBF

DO WHILE .T.

CLEAR

P=1

@5,20 PROMPT “ ”

@7,20 PROMPT “ ”

@9,20 PROMPT “ ”

@11,20 PROMPT “ ”

MENU TO P

DO CASE

CASE P=1

BROWSE

CASE P=2

CLEAR

F=SPACE(20)

@ 10,15 SAY “ “ GET F

READ

LOCATE FOR FIO = F

IF !FOUND( )

@ 12,15 SAY “ e ”

WAIT

EXIT

ELSE

DISPL

ENDIF

CASE P=3

CALCULATE SUM(SRZAR) TO SUMM

SUMM = SUMM/RECCOUNT( )

@ 12,15 SAY STR(SUMM)

WAIT

CASE P=4

EXIT

ENDDO

CLOSE ALL

2) ********** PULLDOWN *******


SET MESSAGE 15

DIMENSION a(5, 3) && ,

(1, 1) = '' &&

(2, 1) = ' '

(3, 1) = ' '

(4, 1) = ''

(5, 1) = ''

(1, 2) = ' ' &&

(2, 2) = ' '

(3, 2) = ' '

(4, 2) = ' ' (5, 2) = '3 '

DIMENSION b(2) &&

b(1) = ''

b(2) = ''

DIMENSION c(2)

(1) = ''

(2) = ''

** ** &&

MENU BAR a, 5

MENU 2, b, 2

MENU 3, c, 2

g = 1 &&

v = 1 &&

DO WHILE .T.

CLEAR

READ MENU BAR TO g, v &&

DO CASE &&

CASE g = 1

DO info

CASE g = 2 .AND. v = 1

DO p21

CASE g = 2 .AND. v = 2

DO p22

CASE g = 3 .AND. v = 1

DO p31

CASE g = 3 .AND. v = 2

DO p32

CASE g = 4

DO p4

CASE g = 5

CANCEL

ENDCASE

ENDDO

- . , . .

POPUP - .

DEFINE U <> - ,

ON SELECTION POPUP - ,

ACTIVATE POPUP - .


3) ********** POPUP - ****************

CLEAR

DEFINE POPUP mmenu MARGIN &&

DEFINE BAR 1 OF mmenu PROMPT '' &&

DEFINE BAR 2 OF mmenu PROMPT ' '

DEFINE BAR 3 OF mmenu PROMPT ' '

DEFINE BAR 4 OF mmenu PROMPT ''

DEFINE BAR 5 OF mmenu PROMPT ''

ON SELECTION BAR 5 OF mmenu DEACTIVATE POPUP &&

ON SELECTION BAR 1 OF mmenu DO info

ON SELECTION BAR 4 OF mmenu DO p4

ON BAR 2 OF mmenu ACTIVATE POPUP ww &&

ON BAR 3 OF mmenu ACTIVATE POPUP ss

DEFINE POPUP ww &&

DEFINE BAR 1 OF ww PROMPT ''

DEFINE BAR 2 OF ww PROMPT ''

ON SELECTION BAR 1 OF ww DO p21

ON SELECTION BAR 2 OF ww DO p22

ON SELECTION POPUP ww DO ww

DEFINE POPUP ss

DEFINE BAR 1 OF ss PROMPT ''

DEFINE BAR 2 OF ss PROMPT ''

ON SELECTION BAR 1 OF ss DO p21

ON SELECTION BAR 2 OF ss DO p22

ON SELECTION POPUP ss DO ss

ACTIVATE POPUP mmenu &&


1, , . POPUP- .


8.

1.

@ [DOUBLE / PANEL<>

COLOR < > / COLOR SCHEME

, (DOUBLE), (PANEL) .

2.

:

N

GR+

BG

GR

W

G

RB


SET COLOR TO [<>[,<>] [,<>] [,<>]]

- , ,

.

(, W/B R+/ GR).


SET COLOR OF SCHEME TO [< nap>]/[SCHEME]. : SET BLINK ON/OFF.

10.


FoxPro , , . , , , (), , - . . . , , ..

. _-- , . ( ) . SET RELATION. _-- ( SET RELATION SET SKIP TO).


FoxPro ( 25). DBF (, ) . :

SELECT < / >

1-10 A J. 11- 25- - W11 W25. 0, . , . .

, , , . ( ). : , :

< / > .< >

(, , ), . SELECT .

1 ( ), , , .

USE , . :

USE delivery IN b.

( SELECT).


, (Delivery) (Supply). 3. , .


CLEAR

SET TALK OFF

SET EXACT OFF

SELE A

USE Supply

KOD=0

@ 1,2 SAY ' ' GET KOD PICTURE'#####'

READ

LOCATE FOR indgoods = kod

IF !FOUND()

WAIT ' '

RETURN

ENDIF

ind = inddel

SELE B

USE Delivery

LOCATE FOR inddel=ind

IF !FOUND ()

WAIT ' '

RETURN

ENDIF

DISPL namedel, count, tel, A.namgoods, A.pricegds

CLOSE ALL


_--

SET RELATION TO <> INTO <> [,< > INTO < >] [ADDITIVE]


, INTO, (). , , .


SUPPLY.DBF DELIVERY.DBF INDDEL. .


SET TALK OFF

CLEAR

SELE A

IF FILE ('Inddelivery.ind')

USE Delivery INDEX Inddelivery

ELSE

USE delivery

INDEX ON inddel TO Inddelivery

ENDIF

SELE B

USE Supply

SET RELATION TO inddel INTO A

DO WHILE .T.

kod=0

CLEAR

@ 12,23 TO 14,50 DOUBLE

@ 13,25 SAY ' ' GET kod PICTURE '#####'

READ

LOCATE FOR indgoods = kod

IF !FOUND()

WAIT ' '

LOOP

ENDIF

name=namgoods

IF kod <>0

SET FILTER TO indgoods = kod

BROWSE ;

TITLE ' , ' + name ;

FIELDS ;

INDDEL :H = ' ' ,;

A.NAMEDEL :H = ' ' ,;

A.ADRDEL :H = ' ' ,;

A.TEL :H = ' '

SET FILTER TO

ENDIF

IF LASTKEY()=27

EXIT

ENDIF

ENDDO

PACK

CLOSE ALL


, inddel Supply.dbf ( ) A.namedel ( ), A.adrdel () A.TEL () Delivery.dbf ( A).

FoxPro . , , ( ..), SET RELATION ADDITIVE, , .

SET RELATION TO . <> - SET RELATION OF INTO <>.


_--

SET SKIP TO [< 1 > [,< 2 >] ]

_-- .

. , <>.

SET SKIP TO, _-- SET RELATION. _-- SET SKIP TO .


.

(Goods.dbf), Supply.dbf


SET TALK OFF

IF FILE ('Goods.dbf')

ERASE Goods.dbf

ENDIF

IF FILE ('Indnum.idx')

ERASE Indnum.idx

ENDIF

SELE A

USE Supply

IF FILE ('Indg.idx')

SET INDEX TO Indg.idx

ELSE

INDEX ON indgoods TO Indg UNIQUE

ENDIF

COPY TO Goods FIELDS indgoods, namgoods, measure

SELE C

USE Smdeliv

IF FILE ('Indexdel.idx')

SET INDEX TO Indexdel.idx

ELSE

INDEX ON indgoods TO Indexdel UNIQUE

ENDIF

SELECT SUPPLY

SET RELATION TO inddel INTO Delivery ADDITIVE

SELE B

USE Goods

INDEX ON namgoods TO Indnum

SET RELATION TO indgoods INTO Supply ADDITIVE

SET SKIP TO Supply

BROWSE TITLE "" ;

FIELDS ;

Goods.Namgoods :H = " " ,;

Delivery.Namdel :H = " " ,;

Delivery.Adrdel :H = " " ,;

Delivery.Count :H = "", ;

Goods.Measure :H = "." ,;

Supply.Pricegds :H = " " ,;

Supply.Quant :H = "- " ,;

Totalamount=Supply.Quant * Supply.Pricegds :H = " "

CLOSE ALL


11.

- .

DEFINE WINDOW < > FROM, TO , <2>

[FOOTER<>] [TITLE<>] [SYSTEM/DOUBLE/PANEL/NONE]

[CLOSE][FLOAT][GROW][SHADOW][ZOOM][FILL<>][MINIMIZE]


FOOTER, TITLE - ;

:

SYSTEM - ,

DOUBLE - ,

PANEL - ,

NONE - ,

CLOSE - ,

FLOAT - ^F7 ,

GROW - (^F8 ),

ZOOM /

MINIMIZE - ;

SHADOW - ,

FILL - .


ACTIVATE WINDOW [[<1>][,< 2>]] [,...]] ALL [BOTTOM / TOP]]

(ALL) . BOTTOM / TOP - / .

DEACTIVATE WINDOW <1>[,<2>][,...] /ALL

CLEAR WINDOW -

RELEASE WINDOW <> - .


RESTORE WINDOW


SAVE WINDOW <> /ALL TO <>


12.


12.1. FOXPRO



ABS() -

BETWEEN(<>,<1 >,<2>) - (..), <1>  <> 

 <2>, (.F.) ( ,

, )

CEILING() -

FLOOR() -

IN() -

(<>,<1>[,<2>...]) -

(, , )

MIN<>,<1>[,<2>...]) -

MOD(,) -

ROUND(,) -

RAND(]) - 0...1

SIGN() -


,

() -

LOG() -

LOG10() -

SQRT() -

SIN() -

COS() -

TAN() -

ASIN() - ( )

ATAN() -

PI ( ) - 

DTOR() -

RTOD() -


<1>$<2> - <1> <2>

( .. .F.)

AT / ATC(,[,<N>) -

<2>

<1>,

<2>

R(<1>,<2>[,) -

INLIST(,[,]) - <>

( .. .F.)

LEN() - <>

LIKE(,<2>) - <1> <2>

( .. .F.)

* ?

OCCURS(,<2>) - <1><2>

LEFT() -

.

RIGHT() -

SUBSTR(<>,<..>,[< >]) -

<1>

<..> <

>

LTRIM() -

TRIM / RTRM() -

ALLTRIM() -

REPLICATE(,) -

SPACE() -


S () - ASCII

CHR () -

STR (,[,[]]) -

<>

<.>

VAL (<>) -


-

ATLINE(,< >) -

< >

ATCLINE (,< >) -

RATLINE(,< >) - <>

< >

MLINE(< >,) -

< >

MEMLINES(< >) -


D() -

DATE( ) -

DAY() -

DMY() -

( )

DOW () -

DTOC () -

GOMONTH(,) - ,

MONTH() -

YEAR() -


BOF(<>,<1>,<2>) - <1>,

, <2> .


F([<>]) - (

.. .F.)

F[(<>]) - (

.. .F.)

DBF([<>]) -

DISCSPACE ( ) -

DELETED([<>]) -

( .. .F.)

FILE(<>) -

FIELD([,<>]) -

FOUND([<>]) -

( .. .F.)

FCOUNT([<>]) -

LOOKUP(<1>,<>,<2>) -

<2> <1>

LUPDATE([<>]) -

ORDER([<>]) -

RECNO([<>]) -

RECCOUNT([<>]) -

RECSIZE([<>]) -

HEADER([<>) -

SK(<>[,<>]) - <>

Y(<>) - (

.. .F.)

Y(<>) -


COL ( ) -

ROW ( ) -

L ( ) -

PROW ( ) -


12.2. SET -

, .., . FoxPro 100 . . HELP.

SET ALTERNATE ON/OFF -

SET BELL ON/OFF -

SET BLINK ON/OFF -

SET SENTURY ON/OFF -

SET CLOCK ON/OFF -

SET COLOR TO -

SET COLOR OF SCHEME -

SET CURRENCY TO -

SET DATE TO... -

SET DECIMALS TO -

SET DEFAULT TO... -

SET DELETED ON/OFF -

SET ECHO ON/OFF -

SET ESCAPE ON/OFF -

ESC

SET FILTER TO -

SET FUNCTION...TO... -

SET HELP ON/OFF -

SET INDEX TO -

SET KEY TO -

SET MESSAGE TO... -

SET ORDER TO... -

SET PATH TO -

SET PRINTER ON... -

SET PROCEDURE TO... -

SET RELATION TO - 1:1

SET RELATION OFF -

SET SHADOWS ON/OFF -

SET SKIP TO - 1:N

SET SPACE ON/OFF -

SET TALK ON/OFF -

SET WINDOW OF MEMO TO... -

-


12.3.


: DELIVERY.DBF

Field Field Name Type Width Dec Index

1 INDDEL Numeric 2

2 NUMDEL Character 10

3 ADRDEL Character 20

4 COUNT Character 8

5 TEL Numeric 6


: SUPLY.DBF

Field Field Name Type Width Dec Index

1 INDSUP Numeric 5

2 INDDEL Numeric 2

3 DATE Date 8

4 NAMGOODS Character 15

5 QUANT Numeric 5

6 PRICEGOODS Numeric 5 2

7 MEASURE Character 3

8 INDGOODS Numeric 5


*********************** *****

USE Suply

ERASE Goods.dbf

INDEX ON indgoods TO Indg UNIQUE

COPY TO Goods FIELDS indgoods;

,namgoods,measure

SELECT 2

USE Goods

BROWSE

CLOSE ALL

SET TALK OFF

DEFINE WINDOW vvod FROM 2, 2 TO 7, 35 DOUBLE FLOAT SHADOW

DEFINE WINDOW vivod FROM 8, 2 TO 20,70 SYSTEM ;

COLOR SCHEME 10

CLEAR

SELECT A

IF FILE ('Inddeliv.idx')

USE Delivery INDEX Inddeliv

ELSE

USE Delivery

INDEX ON inddel TO Inddeliv

ENDIF

SELECT B

USE Suply

SET RELATION TO inddel INTO Delivery

DO WHILE .T.

ACTIVATE WINDOW vvod

CLEAR

A=0

@ 2,5 SAY ' ' GET A PICTURE '#####'

READ

LOCATE FOR indgoods=A

IF !FOUND()

WAIT ' '

LOOP

ENDIF

name=namgoods

IF A<>0

SET FILTER TO indgoods=A

ACTIVATE WINDOW vivod

BROWSE ;

TITLE ' , '+name ;

FIELDS ;

A.inddel :H = ' ', ;

A.namdel :H = ' ', ;

A.adrdel :H = ' ', ;

A.tel :H = ' ', ;

A.count :H = ' '

DEACTIVATE WINDOW vivod

SET FILTER TO

ENDIF

DEACTIVATE WINDOW vvod

IF LASTKEY()=27

EXIT

ENDIF

ENDDO

PACK

CLOSE ALL


CLEAR

SET TALK OFF

SELECT B

USE Goods

SELECT A

USE Suply

INDEX ON indgoods TO Indg

SELECT C

USE Delivery

INDEX ON inddel TO Indexdel

SELECT Suply

SET RELATION TO inddel INTO Delivery

SELECT Goods

INDEX ON namgoods TO Indnum

SET RELATION TO indgoods INTO Suply


SET SKIP TO Suply

BROWSE TITLE '' ;

FIELDS ;

Goods.namgoods :H = ' ' ,;

Delivery.numdel :H = ' ',;

Delivery.adrdel :H = ' ',;

Delivery.count :H = '' ,;

Goods.measure :H = ' ' ,;

Suply.pricegoods :H = ' ' ,;

Suply.quant :H = ' ' ,;

Totalamount=Suply.quant * Suply.pricegoods ;

:H = ' '

CLOSE ALL


3.1.

********** ***********

CLEAR

SET TALK OFF

CLOSE ALL

USE state IN a && STATE

USE sotr IN b && b CADR


*********** state **************

SELECT a

BROWSE ;

TITLE ' ^ ^N - ^W coxp ' ;

FIELDS cod :H = ‘’ ,;

dolg :H = '' ,;

zarp :H = '' ,;

kol :H = ''


*********** STATE ***********

CLEAR

= 0

@ 5, 10 SAY ' :' GET PICTURE '###'

READ

@ 6, 2 SAY ' '

LOCATE ALL FOR cod = C

DO WHILE ! EOF ( )

? ' - ', dolg, ' - ', zarp

CONTINUE

ENDDO

WAIT ' ENTER ' WINDOW


******** sotr ****************

SELECT b

BROWSE ;

TITLE ' - ^ T- ^ N - ^W - ' ;

FIELDS cod : = '' ,;

fio :H = ' ..' ,;

tab :H = ' '


**** SOTR ****

CLEAR

= 0

@ 5, 10 SAY ' :' ;

GET PICTURE '###'

READ

@ 6, 2 SAY ' '

LIST ' - ', fio, ' - ', tab;

WHILE cod = c

WAIT ' ENTER ' WINDOW


**** ****

SET FORMAT TO cadr.fmt

CHANGE

SET FORMAT TO


******** ********************

SELECT b

SET ORDER TO cod

SELECT a

SET ORDER TO cod

SET RELATION TO cod INTO b

SET SKIP TO b

BROWSE ;

TITLE '' ;

FIELDS A.dolg :H = ‘' ,;

B.fio :H = '...' ,;

A.zarp :H = '' ,;

nal = A.zarp * 0.2 :H = ''

SET RELATION TO


********* **********


3.2 , ,

CLEAR ALL

SET TALK OFF

CLOSE ALL

SET SHADOWS ON

USE state IN a

USE cadr IN b


************** ****************

DEFINE POPUP mmenu

DEFINE BAR1 OF mmenu PROMPT ''

DEFINE BAR2 OF mmenu PROMPT ' '

DEFINE BAR3 OF mmenu PROMPT ' '

DEFINE BAR4 OF mmenu PROMPT ''

DEFINE BAR5 OF mmenu PROMPT ''

DEFINE BAR6 OF mmenu PROMPT ''

ON SELECTION BAR6 OF mmenu DEACTIVATE POPUP

ON SELECTION BAR1 OF mmenu DO about

ON SELECTION BAR4 OF mmenu DO p2table

ON SELECTION BAR5 OF mmenu DO pspr

ON BAR2 OF mmenu ACTIVATE POPUP wow

ON BAR3 OF mmenu ACTUVATE POPUP sos

DEFINE POPUP wow

DEFINE BAR1 OF wow PROMPT ‘'

DEFINE BAR2 OF wow PROMPT ''

ON SELECTION BAR1 OF wow DO pstate

ON SELECTION BAR2 OF wow DO psearch

ON SELECTION POPUP wow DO wow

DEFINE POPUP sos

DEFINE BAR1 OF sos PROMPT ''

DEFINE BAR2 OF sos PROMPT ''

ON SELECTION BAR1 OF sos DO pstate

ON SELECTION BAR2 OF sos DO psearch

ON SELECTION POPUP sos DO sos

ACTIVATE POPUP mmenu


************ state **************

PROCEDURE pstate

SELECT a

BROWSE ;

TITLE ' ^T - ^N - ^W - coxp' ;

FIELDS cod : = '' ,;

dolg :H = '' ,;

zarp :H = '' ,;

kol :H = ''

RETURN


******** STATE ************

PROCEDURE psearch

CLEAR

c = 0

@ 10, 15 SAY ' :' ;

GET PICTURE '###'

READ

@ 12, 10 SAY ' '

LOCATE ALL FOR cod = c

DO WHILE ! EOF ( )

? ' - ', dolg, ' - ', zarp

CONTINUE

ENDDO

WAIT ' ENTER ' WINDOW

CLEAR

RETURN


******** cadr ***************

PROCEDURE pcadr

SELECT b

BROWSE ;

TITLE ' ^T - ^N - ^W - ' ;

FIELDS cod :H = '' ,;

fio :H = ' ..' ,;

tab :H = ' '

RETURN


******** SOTR *******

PROCEDURE cadrsr

CLEAR

= 0

@ 5, 10 SAY ‘ :' ;

GET PICTURE '###'

READ

@ 6, 2 SAY ' '

LIST ' - ', fio, ' - ', tab;

WHILE cod = c

WAIT ' ENTER ' WINDOW

CLEAR

RETURN


******** ******************

PROCEDURE p2table

SELECT b

SET ORDER TO cod

SELECT a

SET ORDER TO cod

SET RELATION TO cod INTO b

SET SKIP TO b

BROWSE ;

TITLE '' ;

FIELDS A.dolg :H = '' ,;

B.fio :H = '...' ,;

A.zarp :H = '' ,;

nal = a.zarp*0.2 :H = ''

SET RELATION TO

RETURN


********* ************

PROCEDURE about

CLEAR

@ 8, 15 TO 20, 60 double

@ 9, 25 SAY ‘ '

@ 12, 20 SAY ' '

WAIT ' ENTER ' WINDOW

CLEAR

RETURN

********* ************

PROCEDURE pspr

CLEAR

DEFINE WINDOW spr FROM 10, 10 TO 18, 40 ;

TITLE '' SHADOW

ACTIVATE WINDOW spr

@ 1, 1 SAY ' '

@ 2, 1 SAY ' '

WAIT ' ENTER ' WINDIW

DEACTIVATE WINDOW spr

SELECT B

SET ORDER TO cod

SELECT A

SET ORDER TO cod

SET RELATION TO cod INTO b

SET SKIP TO B

SELECT A.dolg, A.kol, COUNT(B.fio) AS cnt, SUM(A.zarp) AS ssum ;

FROM state A, cadr B INTO CURSOR qq ;

WHERE B.cod = A.cod ;

GROUP by A.dolg

BROWSE TITLE ' ' ;

FIELDS dolg : = '' ,;

kol : = ' ' ,;

cnt : = '' ,;

ssum : = ' '

CLEAR

SET RELATION TO

RETURN

11. .

1. x y, case. :

2
. x y, case. :



3. x y, case. :

4
. x y, case. :



5. x y, case. :

6
. x y, case. :



7. x y, case. :




8. x y case. :






1. . . - .: -1980.- 463 .

2. . . - .: . - 1977.- 400 .

3. ., . .- .: . -1985.-344 .

4. . . - .: . -1987.-608 .

5. .., .. .- .: . -1982 .- 382 .

6. . -. - .: . - 1991. - 252 .

7. .. FoxPro2.0. - .: . - 1993. - 350 .

  1. . FoxPro 2.6 WINDOWS. - : - BHV.- 1995.-463 .


: 1 1.

 

 

 

! , , , .
. , :