다음을 통해 공유


Organizing my pictures

Finally, finally, finally I have started to organize my pictures. I planned on doing this months ago but I guess something came in between.

So here’s how I do it. I copy the script from our Belgian System Center MVP, Kim Oppalfens from his blog: https://blogcastrepository.com/blogs/kim_oppalfenss_systems_management_ideas/archive/2007/12/02/organize-your-digital-photos-into-folders-using-powershell-and-exif-data.aspx

I save the file locally in a file with extension ‘.ps1’.

In my browser, I get some funky characters:

image

If you just copy paste, you will need to fix the script to:

$arMonth = [Char]$date[5],[Char]$date[6]
$arDay = [Char]$date[8],[Char]$date[9]

Then you are ready to go.

Thank you for sharing Kim!!!

Then there are some steps I need to take to execute the script:

Step 1: Installing PowerShell

I install it on my Vista-which-will-be-switched-to-Windows-7-tomorrow machine from this location:

https://www.microsoft.com/windowsserver2003/technologies/management/powershell/download.mspx

(On my Windows 7 Beta 1 machine, PowerShell V2 is installed by default)

Step 2: Understanding how to run PowerShell scripts

I find out about how to run PowerShell scripts from this article: https://www.microsoft.com/technet/scriptcenter/topics/winpsh/manual/run.mspx

 

Step 3: Running the script

I run Powershell in Administrator mode and change its execution policy to remotesigned.

I change the path in PowerShell by typing: cd ‘C:\Data\Afbeeldingen’ where I keep all my pictures.

I make sure I have the script saved in a file with extension ‘.ps1’. I save in location ‘c:\Temp’ for now.

I change the target directory in the script from ‘c:\organizedfotos\’ to ‘d:\data\afbeeldingen\’.

I run the script by typing in Powershell the following command: c:\temp\organizeimages.ps1

As Kim says, this script then gives you a folder structure like this: folder per year and then folder per date.

- 2005
   - 27-11-2005
        - sinterklaas.jpg
- 2006
   -…and so on

For me this is great.

It allows me to copy all my pictures to DVD’s per year and also this maps quite nicely to the way I browse images in Windows Live Photo Gallery which you can get here: https://get.live.com

image

(of course I could easily fix the script to also add the months to the folder structure).

Cheers,

 

Hans

Comments