Rev 20 | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed
Rev 20 | Rev 16321 | ||
---|---|---|---|
Line 1... | Line 1... | ||
1 | !set |
1 | !set methtit=Mostrar un objetivo por separado (cuando hay varios) |
2 | !set methparmtype=choice |
2 | !set methparmtype=choice |
3 | !set |
3 | !set methhelp=Cuando hay varios objetivos para demostrar, puede usar\ |
4 |
|
4 | este método para aislar uno en un caso separado. |
5 | 5 | ||
6 | !if $wims_read_parm iswordof form check |
6 | !if $wims_read_parm iswordof form check |
7 | !goto $wims_read_parm |
7 | !goto $wims_read_parm |
8 | !endif |
8 | !endif |
9 | 9 | ||
10 | !if fixedgoal iswordof $m_options |
10 | !if fixedgoal iswordof $m_options |
11 | !set error1=fixedgoal |
11 | !set error1=fixedgoal |
12 | !exit |
12 | !exit |
13 | !endif |
13 | !endif |
14 | 14 | ||
15 | !set n=!linecnt $m_goal |
15 | !set n=!linecnt $m_goal |
16 | !if $n<1 |
16 | !if $n<1 |
17 | !set error1=no_object |
17 | !set error1=no_object |
18 | !exit |
18 | !exit |
19 | !endif |
19 | !endif |
20 | !if $n<2 |
20 | !if $n<2 |
21 |
|
21 | !set error1=Este método solo se puede utilizar cuando hay varios\ |
22 |
|
22 | objetivos que demostrar. |
23 | !exit |
23 | !exit |
24 | !endif |
24 | !endif |
25 | 25 | ||
26 | !exit |
26 | !exit |
27 | :form |
27 | :form |
28 |
|
28 | Establecer el objetivo |
29 |
|
29 | !set gl=!replace internal , by , in $m_goal |
30 |
|
30 | !set gl=!lines2items $gl |
31 |
|
31 | !set n=!itemcnt $gl |
32 |
|
32 | !formselect methparm1 from 0 to $n prompt $ch_choose,$gl |
33 |
|
33 | $ como caso aparte por demostrar. |
34 | !exit |
34 | !exit |
35 | :check |
35 | :check |
36 |
|
36 | n=!linecnt $m_goal |
37 |
|
37 | !bound methparm1 between integer 0 and $n default 0 |
38 |
|
38 | !if $methparm1=0 |
39 | error=empty_data |
39 | error=empty_data |
40 | !exit |
40 | !exit |
41 |
|
41 | !endif |
42 |
|
42 | l=!line $methparm1 of $m_goal |
43 |
|
43 | goal1=$l |
44 |
|
44 | goal2=!replace line number $methparm1 by $ in $m_goal |
45 |
|
45 | goal2=!nonempty lines $goal2 |
46 |
|
46 | goal2=!line 1 of $goal2 |
47 |
|
47 | !if $n>2 |
48 | goal2=$goal2 ... |
48 | goal2=$goal2 ... |
49 |
|
49 | !endif |
50 |
|
50 | casesplit=$goal1\ |
51 | $goal2 |
51 | $goal2 |
52 |
|
52 | !reset splitobject1,splitobject2 |
53 |
|
53 | n=!linecnt $objects |
54 |
|
54 | lt=< |
55 |
|
55 | !for i=1 to $n |
56 | l=!line $i of $objects |
56 | l=!line $i of $objects |
57 | w=!word 1 of $l |
57 | w=!word 1 of $l |
58 | !if $w!=$lt |
58 | !if $w!=$lt |
59 | splitobject1=!append line $l to $splitobject1 |
59 | splitobject1=!append line $l to $splitobject1 |
60 | splitobject2=!append line $l to $splitobject2 |
- | |
61 | !else |
- | |
62 | !if $l notsametext $lt $goal1 |
- | |
63 | splitobject2=!append line $l to $splitobject2 |
60 | splitobject2=!append line $l to $splitobject2 |
- | 61 | !else |
|
- | 62 | !if $l notsametext $lt $goal1 |
|
- | 63 | splitobject2=!append line $l to $splitobject2 |
|
64 | !endif |
64 | !endif |
65 | !endif |
65 | !endif |
66 |
|
66 | !next i |
67 |
|
67 | splitobject1=!append line < $goal1 to $splitobject1 |
68 |
|
68 | objects=$splitobject1 |
69 |
|
69 | goalsplit=yes |
70 |
|
70 | methexp=Separar el objetivo $goal1 |
71 | !exit |
71 | !exit |
72 | - |