Little Shutdown Script
2
If you're using passwords of any type on your site, it is best to keep them random. That way they cannot be easily guessed at by intruders.
First, it's good to know a little about ASCII characters. Every character your keyboard can type is actually represented by a number. So the letter A is represented by 65. The letter Z is represented by 90. So all you need to do is generate a series of random numbers, each number between 65 and 90. That would give you a way to find the equivalent letters.
If you want to include numbers too, those are found between spots 48 and 57. I wouldn't use the spots between 57 and 65 - those are odd characters like colons.
So let's say you want to create a 7 character password that contains a random assortment of letters and numbers. You could do something like this:
2
To get the name of the computer/host
2
To create a shortcut to an url you can do as follows
2
If you want to create a shortcut programatically use the code below. Found somewhere on net
5
This script demonstrates the use of the Speech API via VBScript. Simply type in the word or phrase that you want to the computer to speak and click OK. Useful for vocalizing the results of a function or literally reading a text file to the user.
Note: To successfully run this code you MUST have the Speech API installed. The Speech API is installed during a complete Office install. If the required libraries are not present on your system, search Microsoft.com for the speech API SDK download. See this page for help on setting up Text To Speech: http://support.microsoft.com/kb/306902/
Note: To successfully run this code you MUST have the Speech API installed. The Speech API is installed during a complete Office install. If the required libraries are not present on your system, search Microsoft.com for the speech API SDK download. See this page for help on setting up Text To Speech: http://support.microsoft.com/kb/306902/
7
I wrote this script to ease installation of LDIF files into ADAM (Active Directory Application Mode). Some .NET portal vendors choose a hybrid of SQL and ADAM for their applications, ours did just that. When developing portlets, they must be registered in ADAM to be made available to the portal.
In the course or portlet development it was a pain to locate the directory the LDIF file (description file) lived and then to execute the LDIF installer - so I made it easy - a generic LDIF installer script. It uses the common OpenDialog to allow for searching for the file and then installing it once the file is selected - a real time-saver.
I will have more AD type goodies for you soon...(LDIFs are also used for creating or manipulating User and Computer accounts in AD)
In the course or portlet development it was a pain to locate the directory the LDIF file (description file) lived and then to execute the LDIF installer - so I made it easy - a generic LDIF installer script. It uses the common OpenDialog to allow for searching for the file and then installing it once the file is selected - a real time-saver.
I will have more AD type goodies for you soon...(LDIFs are also used for creating or manipulating User and Computer accounts in AD)
4
This was an update someone else's snippet...
VBScript is a graceful language and Windows Scripting Host cleans up after itself, so this is a compact version for simple usage - reducing code bloat is what small scripts are for.
Just my $.02...
VBScript is a graceful language and Windows Scripting Host cleans up after itself, so this is a compact version for simple usage - reducing code bloat is what small scripts are for.
Just my $.02...
9
This script demonstrates the user of a procedure that forces the currently executing script to execute under the WScript scripting host. This forces the output from WScript.Echo statements to be displayed message box dialog. This functionality may be useful in situations where the default scripting host is set to cscript.exe and/or the programmer uses a common set of code to program for wscript.exe and cscript.exe.
Typical usage would see the ForceWScript procedure called at the beginning of a script.
Typical usage would see the ForceWScript procedure called at the beginning of a script.
7
This script demonstrates the user of a procedure that forces the currently executing script to execute under the CScript scripting host. This allows the output from WScript.Echo statements to be displayed in a command prompt dialog in a similar way to older style batch files, making this procedure ideal for batch processing.
Typical usage would see the ForceCScript procedure called at the beginning of a script.
Typical usage would see the ForceCScript procedure called at the beginning of a script.
4
This is a quick and dirty function for preventing SQL Injection, the function is designed to clean any variable that will be concatenated into an SQL query. Apostrophes and Double-Quotes are changed to entities in order to ensure that encoding does not become an issue when the content is pulled back into a page. I'm looking for criticism here, I want to know if this is secure or not.









