I have a little function, it has a daft name, but I never was any good at thinking of those. It accepts an object as input and returns a Byte Array. I use it to combine several different Byt...
I'm creating a script to do the following:
Go into the default log file location for Exchange 2003
Get the list of files held inside
If it's E00*.log, I care about it.
If it's res1.log or ...
I have been searching on the net and found some very bloated code to create mailboxes for exchange 2003. I was wondering if anyone knew the most efficient way (via a snap-in or whatever) to d...
HI
I have an application that is accessible via web portal, WPF client and Powershell
Now, there are many data entry forms in the web client and WPF client, each with several controls when...
I'm trying to do this efficiently, as I've already accomplished this in a not-so-elegant way.
Using the command "Get-QADComputer" from Quest AD Snapin and specifying the scope then doing a pi...
Hi All,
Powershell question...If I return an attribute e.g
[PS] C:\>Get-MailContact testuser1 | Select-Object DistinguishedName
How do I then convert the output...
DistinguishedName
---...
Im playing with the following script to find files older than 1 day.
$DateToCompare = (get-date).AddDays(-1)
$logFiles = get-childitem C:\logs -recurse | ? {$_.LastWriteTime -lt $DateToCo...
Hello,
I am attempting to execute a an SQL query through PowerShell against an MS Access database. My query works 99% of the time, but occasionally a localized string will cause an error b...
Why do the simple things have to be so hard :(
How do I migrate this simple Batch command to Powershell?
move "\\Server\c$\windows\system32\config\Archive*.evt" "c:\logs\backup\Server-Arch...
Hi,
I wonder if somebody has a powershell/vb/batch script to move files which are older than 4 hours (create time) to different location and rename those with adding create date & time at e...
I have a script that gets the size of folders in a share directory - but I want to sort it from largest to smallest and I cannot figure out how to sort it
I am trying to run this command:
Import-Csv $sourceMachinesList | ForEach-Object
{
# some code
}
I get no error messages, but I do get this message asking for a parameter
"cmdlet...
This is probably pretty simple, but I've been playing around with the set-acl command to add a user to a folder's permission list. So far all i can find is exaples where people do a get-acl on...
I'm doing something screwy. This script runs thru a bunch of folders and checks the size, and it works (sort of) but I'm setting up the hash wrong. It seems to reset for each folder it goes ...
HI
How can I get the current user domain from PowerShell ??
I have tried the following, but didn't got the domain....
I have a powershell script that gets mailbox sizes, display names, Total Items, and storage limit status and creates a textfile as the output.
now I get this "WARNING: 2 columns do not f...
HI
I have a custom powershell cmdlet I have wrote in C#
The command syntax is :
New-Desktop -templateObject]<Template> -name <String>
Now, everything is just fine if I run the command...
HI Experts
I have added few custom cmdlets to powershell and I want to be able to get help on those commands using the PS get-help command.
Whats steps should I follow ?
Thanks
When I write a script which requires user input and I want to stop the script without inputing any data what is the key combination I press to end the script and go back to the command line?
Is there a fork() equivalent in powershell? I'm trying to gather event logs in powershell from a number of computers at a time, currently it takes about a minute per machine to query event lo...
HI
Are there any known issues when upgrading from PS 1.0 to PS 2.0 ?
Should I uninstall PS 1.0 first?
Can I be sure that all scripts running on PS 1.0 will keep working on PS 2.0 ???
...
I am able to redirect the output of a ps1 file to a file by executing it like:
myfile.ps1 > mylog.log
or myfile.ps1 | out-file mylog.log
but how can I make sure that I write to the screen...
can anyone recommend one? pros and cons and such?