Saturday, November 20, 2010

Synching

 

Again I am looking at syncing tools.  Windows live beta has now gone and been replaced by Windows Live Sync.

It comes as part of the 2011 Essentials pack, only installable on Windows 7 though, so that makes for a bummer on my main home Win XP laptop.  Will still use the web folder for live mesh there.  25 gig of free space is not something to be sniffed at.

This is being written on the blogger tool as part of the live essentials, which at first glance looks pretty cool  Im currently on my little d430 ‘work’ laptop, with Windows 7 on it.

Also trying out a few tools to help sync my Google documents, Synchplicity and the office plugin. not installled yet.

 

WIll update this in a bit, but want to see if the blogger tool works…

Monday, September 27, 2010

Sky+ remote codes

Our Sky+ remote went down this weekend, and whilst you can get basic functionality with the buttons on the front of the machine, it's a right pain and you can't really use Sky+ properly at all.

Luckily my dad had a spare new Sky+ HD remote, which I thought would work.

If you need to get a different type of remote to work with Sky, Sky+ or Sky HD. Here's how:

1 press the TV button
2 press and hold the Select and i buttons until the red light on the remote flashes twice
3 press the 1 button (0=Standard, 1=Sky+, 2=Sky HD)
4 press the Select button (the red light should flash twice, if it doesn't, your remote cannot control a Sky+ Digibox)
5 press the Sky button

There are also other 'reset' codes and TV codes, which are easily available on the web. But this was the one we needed to get our remote working with our Sky+.

Now for some soldering of the old remote...

Thursday, September 16, 2010

Restoring a Dell factory image file (.wim) to a new hard disk

A bit of googling I found this excellent article on tjb-ts.blogspot which gave me the quick indication that this COULD be done and how to do it.

Basically, I extracted the factory.wim file from the recovery partition of a failing hard drive, and also got the imagex.exe and it's config files from the tools folder in the recovery partition and stuck them all on my external usb.

Then, using a vista disk, I booted into the recovery options after installing a new hard drive.

Going into command line, I issue the following commands to get the new hard disk ready, active and formatted:

diskpart
select disk 0
clean
create partition primary
assign letter=c:
active
exit
format c: /q /y

once this was complete, I navigated to my USB drive (handy that vista boot disk repair has usb support - as does windows 7) and ran the imagex command to restore the factory.wim file:

Imagex /apply factory.wim 1 c:\

Once this was complete, and again, thanks to the tjb-ts blog, I needed to run the vista startup repair option, which sorted out the booting issue. If I didn't run this option, then vista wouldn't load.

All in all, a successful operation!

Friday, September 3, 2010

Searching in Windows for NOT those things!

I recently have began cataloguing and cleaning up my media library to enable the new media unit at home to more easily serve us the pics, music and video that I have amassed over the years...

After renaming many files with prefixes to allow for faster searching, and getting all the mp3 tags correct and orderly, I wanted to check through my directories for any files that were NOT meant to be in the respective folders. IE in my music directory, for any files that were NOT .mp3, and in my pictures, any files that were NOT .jpg, etc.

I found out you cant do this with Windows search. DOH!

I found out (on Eileen's Lounge - thanks Hans!) that a command line will do this. Yay!
For instance:

dir "C:\Documents and Settings\\My Documents\My Music" /s | find /v /i ".mp3" | C:\result.txt

will pipe a LOT of info into a text file, detailing any files not of the type .mp3 in the music directory. There is a lot of verbatim with this method to sift through though.

I think Google desktop search could probably do this with less verbatim, but I don't have this app (no major use for it) and didn't want to install it. I would rather write a nice little script...

I called it the NOT search. I have posted it for download with an .exe version on 'Eileen's Lounge (formerly Woodies Lounge)' here.

It basically prompts you for the directory to search on, then for the file types to exclude, ie NOT search on, and then offers folder recursion, ie search through all subfolders. Once complete a nice little report is presented to you in Notepad, detailing any found files and their paths. I found this very helpful indeed and was able to clean up and move any files to where they should be.

The code is below:

'// pmatz's file extension NOT search - sept 01 2010. v 1.1
'// script to search for all files with extension's NOT specified
'//---------------------------------------------------------------

Public strList

main

Sub main
strList = ""
Dim strFileExtensions()
strPath = InputBox ("Enter path to search on." & vbCr & _
"(For root drives please use driveletter" & vbCr & _
"followed by :\ )" ,"pmatz's file extension NOT search")
If IsEmpty(strPath) Then
closeMessage1
Exit Sub
End If
strGetFileExts = InputBox ("Enter filetype/s NOT to search for." & vbCr & _
"(seperate file extensions with commas and leave no spaces" & vbcr & _
"e.g. .mp3,.jpg,.gif,.tar,.iso)","pmatz's file extension NOT search")
bRecurse = (MsgBox("Recurse through all subfolders?",vbYesNo) = vbyes)
strTypes = strGetFileExts
iExtensions= 0
Do
ReDim Preserve strFileExtensions(iExtensions)
iComma = InStr(1,strGetFileExts,",")
If iComma > 0 Then
strFileExtensions(iExtensions) = Left(strGetFileExts,iComma-1)
strGetFileExts = Right(strGetFileExts,Len(strGetFileExts)-iComma)
iExtensions=iExtensions+1
End If
Loop Until iComma = 0
strFileExtensions(iExtensions) = strGetFileExts
search strPath, strFileExtensions, bRecurse
createOutput strPath,strTypes
End Sub

Sub search(searchFolder,excludeTypes,recurse)
On Error Resume Next 'this stops crash for issues with no access etc.
bFound = False
Set fso = CreateObject("Scripting.FileSystemObject")
If Not fso.FolderExists(searchfolder) Then
closeMessage1
Exit Sub
End If
Set fFolder = fso.GetFolder(searchFolder)
Set fSubfolders = fFolder.SubFolders
Set fFiles = fFolder.Files
For Each fFile in fFiles
For iExtension = 0 To UBound(excludeTypes)
For iStop = Len(fFile.Name)To 0 Step -1
If Mid(fFile.Name,iStop,1) = "." Then
iStop = Len(fFile.Name)-iStop + 1
Exit For
End If
Next
If UCase(Right(fFile.Name,iStop)) = UCase(excludeTypes(iExtension)) Then
bFound = True
End If
Next
If Not bFound Then
strList = strList & vbNewLine & fFile.Path
Else
bFound = False
End If
Next
If recurse Then
For Each fSubfolder In fSubfolders
search fSubfolder.Path,excludeTypes,True
Next
End If
Set FSO = Nothing
Set fFolder = Nothing
Set fSubfolders = Nothing
Set fFiles = Nothing
End Sub

Sub createOutput(strPath,StrTypes)
Set oShell = CreateObject("WScript.Shell")
strOut = oShell.SpecialFolders("Desktop")
Set fso = CreateObject("Scripting.FileSystemObject")
strOut = strOut & "\pmatzFileExtensionNOTsearch_" & getStamp & ".txt"
Set f = fso.CreateTextFile(strOut)
f.WriteLine "pmatzFileExtensionNOTsearch performed on " & Now()
f.WriteLine "Searched through " & strPath & ", excluding types " & strTypes
f.WriteLine "__________________________________________________"
f.WriteLine
f.Write strList
f.Close
oShell.Run("%systemroot%\notepad.exe " & strOut)
Set oShell=Nothing
Set fso = Nothing
Set f = Nothing
End Sub

Function getStamp
strStamp = FormatDateTime(Now(),2)
strStamp = Replace(strStamp,"/","-")
strStamp = strStamp & "_" & FormatDateTime(Now(),4)
strStamp = Replace(strStamp,":","-")
getStamp = strStamp
End function

Sub closeMessage1
MsgBox "Need to enter a legitimate path!",vbinformation,"pmatz's file extension NOT search"
End Sub

Wednesday, August 18, 2010

TreeSize - check your storage capacities

If you like me ever need to know at a glance how much storgae space you are using in a directory, then look no further than the excellent Tree Size application.
It comes in free version or a paid version with lots more features. But the free version is fine.
This will scan a directory or drive and breakup by folder how much space is used by files and folders.
You can print a 'report' which is helpful, and although the free version doesn't support an export to .csv feature, you can print to XPS for instance and do a little copy and pasting if necessary.

Wednesday, July 14, 2010

Google Sketchup

Quite simply, whether just for fun, doing some home DIY, woodwork, floor plans...

You gotta play with this, its excellent free software. I am completely immersed in the tutorials and am enjoying every minute.

Have a look and play. http://sketchup.google.com/

Tuesday, July 6, 2010

LDAP query

I needed to find out how to query the active directory database easily and so looked into how to script an LDAP query. Code below shows the basics of the simple query based on the LDAP://rootdse object and a recordset connection to perform the query.

Function LDAPsearch (strSearch,strQ)
'set variable to hold required amount of attributes
Dim aResults(4)

'set LDAP defaults to root domain
Set rootDSE = GetObject("LDAP://RootDSE")
DomainContainer = rootDSE.Get("defaultNamingContext")

'create recordset connection
Set conn = CreateObject("ADODB.Connection")
conn.Provider = "ADSDSOObject"
conn.Open "ADs Provider"

'set query, using strQ for searched FOR item and strSearch as search ON string
ldapStr = ";(" & strQ & "=" & strSearch & "*);adspath;Subtree"

'execute LDAP query
Set rs = conn.Execute(ldapStr)

'look for records that meet the query
While Not rs.EOF

'FoundObject is a successful find for query
Set FoundObject = GetObject (rs.Fields(0).Value)

'put results into array with tags
aResults(0) = FoundObject.employeeID
aResults(1) = FoundObject.displayName
aResults(2) = FoundObject.userPrincipalName
aResults(3) = FoundObject.sAMAccountName
aResults(4) = FoundObject.telephoneNumber

'goto next record
rs.MoveNext

'concatenate attributes to string
For i = 0 To 4
strResult = strResult & aResults(i)
Next

'count results (searches may produce multiple results)
iCount = iCount + 1

'add newline results string
strResult = strResult & vbnewline

'continue until no further records are found
Wend
End Function

PureSync

After a year or so of using Microsoft's Synctoy 2.0 for ensuring I always have an up to date synchronised copy of my important data, I finally decided to look for something a bit more flexible.
Synctoy didn't allow for easy changes to the directoris and files that you set up for synch.
To cut a long story short there was a clear contender, namely PureSync from Jumping Bytes.
This is a very powerful and flexible tool, with way more options to really specify how you want to back up / sync your files.
I have three main directories that I sync regularly to ensure minimal data loss in the event of a 'catastrophic failure' eg hard drive fail, theft etc. And so I am only scraping the surface in my use of what PureSync can do, even so, it is far more preferable than SyncToy.
If you are looking for a free sync tool that beats the competition, I would recommend PureSync as the solution.

Friday, July 2, 2010

Google Sync - Outlook 2010

I have found Google's Calendar Sync tool most useful to keep my work outlook calendar synced with my gmail calednar meaning that on my personal and work phones (also synced to google calendar) my scehdule is always up to date with my google calendar and my outlook at work. Google's sync works simply and effectively and helps keep my life organised!
Upon an upgrade at work to office 2010 (from XP) the calendar sync no longer worked. A bit of googling and it seemed to be a simple issue caused by the stamp of the 2010 tag on the app, and there were fixes involving hex editing the exe file which is where i thought .... oh no. Then i found this link: (thanks to james manning!)

Google Calendar Sync with Outlook 2010

This is the way to do it. Install the google tool, then use the updated .exe file and it works perfectly again.
Ahh...

Wednesday, February 17, 2010

Media Monkey

A suprisingly pleasant and refeshing change and improvment on music management...(better in my opinion that itunes)

I was looking for something better than iTunes as I have LOADS of music and need to keep it organised and searchable, but was finding iTunes both too slow (startup time especially) and creating duplicates and other various niggles. I have to say that within an hour of using (and getting to know its features) MediaMonkey, I am completely converted. And this is the free version. Am seriously thinking of buying the lifetime subscription to the full 'Gold' version. It handles all my music and I have completely un-duplicated my library already. It has EXCELLENT features and in my opinion blows all other players / library managers out of the water.