Shorten printer name on remote desktop logon
I need to run a script when a user logs on using Remote Desktop. I have an application that doesn't accept printer names over 24 characters long. I've searched and searched and have the below code,...
View ArticleVBS trying to find a link on users desktops on a list of computers in my network
Ok, I provide a list of computers in a text file to the code. The code searches all users on each computer and determines if a file exists or not. If it exists it records the computer/user name as...
View ArticleTrying to create a VB script to open Notepad with data.
Greetings all, I could use some assistance with getting this script to work. What I am trying to do is to pull the log from a remote workstation, and take that data and have it open into Notepad.Const...
View ArticlePinging multiple host names and verifying the IP addresses
Hi Experts, I am novice to the batch scripting. I am looking to fullfill one of my requirement. I have one host file which is having multiple host names and IP addresses. Below is the example of the...
View ArticleBatch command time out
Hey I have a script that needs to run a command and a few commands afterwards. The issue is, is that the one command has a tendency to never finish when it actually does. Is there a way for me to...
View ArticleCSV to PRN Automation
I need some help with this code. It works like 99%, but every once in a while I get print from the PRN file that goes beyond the 2 space placeholder that I set in the bottom part of the code....
View ArticleArray assignment to [#,#,#] failed because assignment to slices is not supported
Please consider the following fail:PS C:\> $x=@("a","b","c","d","e") PS C:\> $x[1..3]=@("x","y","z") Array assignment to [1,2,3] failed because assignment to slices is not supported. At line:1...
View ArticleHow can I automatically get a link to open in Chrome while using Firefox?
I'm trying to get a specific link in Firefox to open in Chrome. I need to run it this way for the link i'm opening.
View ArticleUsing DOM DocumentFragments to update HTA Listbox using VBScript
Hey, Scripting Guy!I followed -> http://blogs.technet.com/b/heyscriptingguy/archive/2005/08/15/how-can-i-dynamically-populate-a-list-box-in-an-hta.aspx?CommentPosted=true#commentmessage to...
View ArticleAny way to feed username/password into the following cmdlet? ===...
http://technet.microsoft.com/en-us/library/jj657535.aspxI want to be able to put my username/password in a script so I don't have to input the username/password manually
View ArticleGet-WinEvent - Security
I've been trying to use eventcombmt to find some user logon attempts but the application crashes. Since there are no other alternatives I thought PowerShell would be my friend.I need to crawl the...
View ArticleNot able to store the value in the variable
Dear All,I am trying to read the file and storing the fileds into the variable. But facing below issue while running the script.myfile.txt127.0.0.1 BLRKEC272851D Test1 Test2 127.0.0.2 Test3 Test4...
View ArticleScript that will back up an existing file then replaces it with an updated one
Hi All,Well, I have little knowledge about scripting so I tried to search the net for a program that will replace a file with an updated one after it has been backed up. I was thinking of a script that...
View ArticleAvoiding comments while reading file in powershell
Hi Experts,I am reading a host file file using getcontes cmdlet.$lines = Get-Content myfile.txt | Where {$_ -notmatch '^\s+$'} foreach ($line in $lines) { $fields = $line -split '\s+' $ip = $fields[0]...
View ArticleVB script to list the software installed from a list of computers
I have a vb script which will list the software installed on local machine.Is there any way to read the computer names from a list and provide the output to a csv file. Output should contain Computer...
View ArticleHow to check a list of users against AD if they exist
Hi Scripting Guys,I have a powershell script that allows me to query a list of users against AD, and if they exist, it will write their details into a new file.I want to adapt this script so that it...
View ArticleSQL Powershell for executing objects in multiples SQL Servers
Hi All,The following are the requirements in building the powershell script.1) Need to find whether the given stored procedure exists in a particular DB in a list of servers.(Server list will be given...
View ArticleI want to generate log which should show in the event viewer when the...
I want to generate log which should show in the event viewer when the powershell starts in a machine. That log can be having information about machine name or IP address etc..
View ArticleVbscript Exit Code
Hello,i'm using a software that is automatically running Vbscripts and prints out the output. i want the softwareto print out the same message each time the script fails to run, due to a VBScript...
View ArticlePowershell bcdedit.exe
Has anyone figured out how to take the normal bcdedit.exe /enum response and convert it to objects? In the example below....if you had created and an array of objects called $bcdedit then you can loop...
View Article