> Sorry, I know nothing about accesschk and what it does.
>
>
> "Altria" <urbantec92[ at ]msn.com> wrote in message
> news:elOQhndRJHA.1148[ at ]TK2MSFTNGP05.phx.gbl...
>> Thank you Pegasus!
>> Actually another question then would be do you think that the accesschk
>> is the best way of capturing and automating this information. Is there a
>> better way and simpler way via vbscript, perl,python etc.?
>>
>> Thanks again,
>> Altria
>> "Pegasus (MVP)" <I.can[ at ]fly.com.oz> wrote in message
>> news:e5HcXrbRJHA.4504[ at ]TK2MSFTNGP02.phx.gbl...
>>> Building on Tom's code:
>>> fc file1.txt file2.txt > nul
>>> if not errorlevel 1 (
>>> echo Files are identical
>>> ) else (
>>> blat /.. /..
>>> )
>>>
>>> blat.exe is a Command Line mailer that you can download from a number of
>>> sites. You could also use a VB Script mailer but since you're running a
>>> batch file there seems to be little point in moving to a hybrid
>>> solution.
>>>
>>>
>>> "Altria" <urbantec92[ at ]msn.com> wrote in message
>>> news:%23Gx94laRJHA.1164[ at ]TK2MSFTNGP03.phx.gbl...
>>>> Tom thanks for your fast reply!
>>>> That is exactly what I needed.
>>>>
>>>> For the second question would it be more complicated to have the file
>>>> compare utility do a condition process whereby if changes between files
>>>> are found it would send an email?
>>>> Or would I need something much more involeved to get that kind of
>>>> automation?
>>>>
>>>> Thanks again,
>>>> Altria
>>>> "Tom Lavedas" <tglbatch[ at ]cox.net> wrote in message
>>>> news:2f5dbee6-66ca-4493-ae95-b8ef45694b7d[ at ]e38g2000prn.googlegroups.com...
>>>> On Nov 13, 9:44 am, "Altria" <urbante...[ at ]msn.com> wrote:
>>>>> Hello All,
>>>>> I would like to automate a daily report of accesschk againsts a file
>>>>> server
>>>>> but would like to include a datestamp, for example;
>>>>>
>>>>> accesschk -rws "group" "folder target" > %datestamp%.txt
>>>>>
>>>>> I would like afterwards to run a diff command (what is the equivalent
>>>>> of
>>>>> this in windows?) against the files and see if any access permissions
>>>>> have
>>>>> changed
>>>>>
>>>>> Any help would be greatly appreciated!
>>>>>
>>>>> Thanks,
>>>>> Altria
>>>>
>>>> Try something like this to get a datestamp ...
>>>>
>>>> for %%a in (%date%) do set datestamp=%%a
>>>> set datestamp=%datestamp:/=%
>>>> accesschk -rws "group" "folder target" > %datestamp%.txt
>>>>
>>>> It creates a date stamp in a form of ddmmyyyy in the US or mm-dd-yyyy
>>>> elsewere. A more 'sortable' date stamp requires significantly more
>>>> code. Handling dates, in general, is locale dependent, which can
>>>> complicate explaining how to get one in batch. It's a bit easier in
>>>> WinScript, but that seems to be off topic.
>>>>
>>>> The other question about comparing file contents can be done with the
>>>> FC (file compare) utility. For example (in XP), ...
>>>>
>>>> fc file1.txt file2.txt > nul
>>>> if not errorlevel 1 (
>>>> echo Files are identical
>>>> ) else (
>>>> echo Files are different
>>>> )
>>>>
>>>> Tom Lavedas
>>>> ***********
>>>>
http://there.is.no.more/tglbatch/>>>>
>>>
>>>
>>
>>
>
>