|
|
|
Помогите!! Ошибка в VBA
|
|||
|---|---|---|---|
|
#18+
здраствуйте уважаемые форумчане.....надо тут помочь......) в MS Excel при закрытии хочу сделать сортировку листов по возрастанию. Все листы в Книге имеют такие названия "0 ч." "1 ч." ......... "23 ч." Пытаюсь это сделать вот таким макросом If Sheets.Count > 1 Then For i = 0 To Sheets.Count - 1 S = Str(i) + " " + "ч." Sheets(S).Select 'тут код который осуществляет перестановку..... Next i End If Но выходит такая ошибка 'Runtime error 9' Subscript out of range Что делать??? Помогите плиз...... ... |
|||
|
:
Нравится:
Не нравится:
|
|||
| 06.12.2007, 12:07:59 |
|
||
|
Помогите!! Ошибка в VBA
|
|||
|---|---|---|---|
|
#18+
Код: plaintext 1. 2. 3. 4. 5. 6. Код: plaintext ... |
|||
|
:
Нравится:
Не нравится:
|
|||
| 06.12.2007, 12:11:24 |
|
||
|
Помогите!! Ошибка в VBA
|
|||
|---|---|---|---|
|
#18+
Читайте хелп. :) When numbers are converted to strings, a leading space is always reserved for the sign of number. If number is positive, the returned string contains a leading space and the plus sign is implied. Use the Format function to convert numeric values you want formatted as dates, times, or currency or in other user-defined formats. Unlike Str, the Format function doesn't include a leading space for the sign of number. То бишь, у вас S после Код: plaintext Код: plaintext Код: plaintext ... |
|||
|
:
Нравится:
Не нравится:
|
|||
| 06.12.2007, 12:28:12 |
|
||
|
|

start [/forum/search_topic.php?author=%D0%90%D0%BB%D0%B5%D0%BA%D1%81%D0%B0%D0%BD%D0%B4%D1%80_&author_mode=last_posts&do_search=1]: |
0ms |
get settings: |
4ms |
get forum list: |
11ms |
get settings: |
5ms |
get forum list: |
13ms |
get settings: |
4ms |
get forum list: |
13ms |
get settings: |
4ms |
get forum list: |
8ms |
get settings: |
6ms |
get forum list: |
10ms |
get settings: |
8ms |
get forum list: |
14ms |
get settings: |
7ms |
get forum list: |
20ms |
get settings: |
9ms |
get forum list: |
14ms |
check forum access: |
3ms |
check topic access: |
3ms |
track hit: |
57ms |
get topic data: |
9ms |
get forum data: |
2ms |
get page messages: |
38ms |
get tp. blocked users: |
1ms |
| others: | 6681ms |
| total: | 6944ms |

| 0 / 0 |
