Set Folder and Registry Permissions with VBScript

Sample VBScript opens up registry and folder access with write access for the Everyone group:


' Create temp file with the script that regini.exe will use
set oFSO = CreateObject("Scripting.FileSystemObject")
strFileName = oFSO.GetTempName
set oFile = oFSO.CreateTextFile(strFileName)
oFile.WriteLine "HKEY_LOCAL_MACHINE\Software\TraxStar Technologies LLC\Client [1 5 7 11 17]"

' Change registry permissions with regini.exe
set oShell = CreateObject("WScript.Shell")
oShell.Run "regini " & strFileName, 8, true

' Delete temp file
oFSO.DeleteFile strFileName

Dim strHomeFolder, strHome, strUser
 Dim intRunError, objShell, objFSO

 strHomeFolder="C:\Program Files\TraxStar"

 Set objShell = CreateObject("Wscript.Shell")
 Set objFSO = CreateObject("Scripting.FileSystemObject")
 If objFSO.FolderExists(strHomeFolder) Then
 intRunError = objShell.Run("%COMSPEC% /c Echo Y| cacls """ & strHomeFolder & """ /t /c /g everyone:F ", 2, True)
 End If

– Soli Deo Gloria

A Weekend with Plex

Finally decided to take the plunge and bought the lifetime subscription for Plex so I could dump all my TV shows into it and stream them to my TV in the living using Chromecast. However, certain TV shows just wouldn’t show up and the server log files weren’t much help.  The issue is that Plex expects to see files in the SXXEXX format, where S is the season and E is the episode number.  If your files don’t have this format, Plex will refuse to add them properly.

The real bear of course is that you may have many files…thousands of files…that do not fit this format.  What’s a guy to do?  Filebot to the rescue!  Basically: this program looks at each filename trying to determine what TV show it belongs to from an online TV database and then offers to put it in the proper naming format.  If the files are missing the TV show name, you can use Bulk Rename to add the show name to any part of the file en mass.  To find out if you are missing any episodes you can use TV Rename.

– Soli Deo Gloria