modified-date

How to Display Modified Time and Modified By Fields Correctly with Powershell

大憨熊 提交于 2021-02-11 07:21:41
问题 I have a script that outputs to CSV all items/files from all Lists and Libraries. In addition, it displays the current and previous versions of an item/file. This also displays which user modified the file for each version and also displays the date/time the file was modified for every version: function Get-DocInventory([string]$siteUrl) { $web = Get-SPWeb "http://contoso.com/sites/Depts3/HBG" foreach ($list in $web.Lists) { foreach ($item in $list.Items) { foreach($version in $item.Versions)

How to Display Modified Time and Modified By Fields Correctly with Powershell

别说谁变了你拦得住时间么 提交于 2021-02-11 07:21:26
问题 I have a script that outputs to CSV all items/files from all Lists and Libraries. In addition, it displays the current and previous versions of an item/file. This also displays which user modified the file for each version and also displays the date/time the file was modified for every version: function Get-DocInventory([string]$siteUrl) { $web = Get-SPWeb "http://contoso.com/sites/Depts3/HBG" foreach ($list in $web.Lists) { foreach ($item in $list.Items) { foreach($version in $item.Versions)

Batch file check file get updated to today's date(System Date)

假如想象 提交于 2019-12-25 14:38:41
问题 I want to create a batch to check if the file have been modified to today's date, what i did was to "bring in a system's date and compare it with the modified date, if they match, then trigger something. My batch file works well and displays two right dates, but the IF statement saying the date mismatch. @ECHO OFF for /f "tokens=1,2,3,4 delims=. " %%i in ('date /t') do set date=%%k%%j echo %date% pause FOR %%a IN (D:\MyFile.txt) DO SET FileDate=%%~ta set DATEONLY=%FileDate:~0,10% echo

Finding modified date of a file/folder

流过昼夜 提交于 2019-12-17 18:34:10
问题 I am very new to PowerShell, and I was hoping I could get some help creating a script that tells me the modified date of a file. I wish I knew more about PowerShell, as I feel like I am asking a lot (all my free-time this week will be dedicated to learning PowerShell better). Pointing me in the direction of where to learn how to do this would be very helpful as well. Here is the complete rundown. I need to run a report daily that checks a list of computers at 90 different stores to make sure

Why is Java (Android?) setting my file's last modified date to tomorrow?

别来无恙 提交于 2019-12-07 09:56:56
问题 I'm creating files in my Android application using: FileOutputStream fos = context.openFileOutput(fileName, Context.MODE_PRIVATE); fos.write(data); fos.flush(); fos.close(); Then later I'm trying to do some cleanup, so I'm comparing the last modified date to some threshold value, but the comparison is showing that the file's last modified date is tomorrow sometime. Keep in mind, when I say tomorrow, that is relative to today (the file modification date)... whichever day this may be that you

Why is Java (Android?) setting my file's last modified date to tomorrow?

本秂侑毒 提交于 2019-12-05 14:38:51
I'm creating files in my Android application using: FileOutputStream fos = context.openFileOutput(fileName, Context.MODE_PRIVATE); fos.write(data); fos.flush(); fos.close(); Then later I'm trying to do some cleanup, so I'm comparing the last modified date to some threshold value, but the comparison is showing that the file's last modified date is tomorrow sometime. Keep in mind, when I say tomorrow, that is relative to today (the file modification date)... whichever day this may be that you're reading this. So basically, if I create the file today, and check the file's last modification date,

How can I get the assembly last modified date?

我的未来我决定 提交于 2019-11-28 21:07:00
I want to render (for internal debugging/info) the last modified date of an assembly, so I'll know when a certain website was deployed. Is it possible to get it through reflection? I get the version like this: Assembly.GetExecutingAssembly().GetName().Version.ToString(); I'm looking for something similar -- I don't want to open the physical file, get its properties, or something like that, as I'll be rendering it in the master page, and don't want that kind of overhead. Clyde I'll second pYrania's answer: System.Reflection.Assembly assembly = System.Reflection.Assembly.GetExecutingAssembly();

Finding modified date of a file/folder

空扰寡人 提交于 2019-11-28 08:08:18
I am very new to PowerShell, and I was hoping I could get some help creating a script that tells me the modified date of a file. I wish I knew more about PowerShell, as I feel like I am asking a lot (all my free-time this week will be dedicated to learning PowerShell better). Pointing me in the direction of where to learn how to do this would be very helpful as well. Here is the complete rundown. I need to run a report daily that checks a list of computers at 90 different stores to make sure their a certain backup was performed. The modified date should tell if the backup had been performed,

How can I get the assembly last modified date?

非 Y 不嫁゛ 提交于 2019-11-27 20:51:01
问题 I want to render (for internal debugging/info) the last modified date of an assembly, so I'll know when a certain website was deployed. Is it possible to get it through reflection? I get the version like this: Assembly.GetExecutingAssembly().GetName().Version.ToString(); I'm looking for something similar -- I don't want to open the physical file, get its properties, or something like that, as I'll be rendering it in the master page, and don't want that kind of overhead. 回答1: I'll second