Total Commander Forum Index Total Commander
Форум поддержки пользователей Total Commander
Сайты: Все о Total Commander | Totalcmd.net | Ghisler.com | RU.TCKB
 
 RulesRules   SearchSearch   FAQFAQ   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

Single Post  Topic: скрытые файлы 
Author Message
_92



PostPosted: Tue Dec 27, 2005 18:08    Post subject: Reply with quote

подкорректировал и добавил кое-что и получился законченный работоспособный скрипт (спасибо всем, кто помог):

Code:

Option Explicit
Dim TCS, ShowHidden, BarFile, Section, Key, Pressed, Depressed
BarFile="C:\program files\total commander xp\profiles\prof\1.bar"  ' Путь к *.bar файлу
Section="Buttonbar"
Key="button3"  ' Номер кнопки
Pressed="C:\program files\total commander xp\profiles\prof\homer h.ico"  ' Ссылка на иконку при показе скрытых файлов
Depressed="C:\program files\total commander xp\profiles\prof\homer.ico"  ' Ссылка на иконку при скрытии скрытых файлов

Set TCS = CreateObject("TCScript.Helper")
TCS.SendCommand(2011) ' Переключение
ShowHidden = TCS.INIRead ("C:\program files\total commander xp\profiles\prof\main.ini", "Configuration", "ShowHiddenSystem", 0)
'меняем иконку на правильную
If ShowHidden = 0 Then
 TCS.INIWrite Barfile,  Section,  Key,  Depressed
else
 TCS.INIWrite Barfile,  Section,  Key,  Pressed
End If
TCS.LockTC true
' Прячем, а затем показываем button bar - для его обновления
TCS.SendCommand(2901)
TCS.SendCommand(2901)
Set TCS = Nothing
Wscript.Quit
View user's profile Send private message ICQ Number


Powered by phpBB © 2001, 2005 phpBB Group