Search found 83 matches
- Wed Aug 20, 2008 6:20 am
- Forum: VBScript
- Topic: Rename global groups by appending to name
- Replies: 13
- Views: 6447
Rename global groups by appending to name
Let me back up. I didnt mean use that code verbatim. It was more of the technique. Here is what you could do. get-content d:groupname.txt | Get-QADGroup | % { Rename-QADObject -Identity $_.DN -NewName $($_.Substring(0,$_.length-2)) -WhatIf} I can't try this code at the moment from where I'm at so te...
- Wed Aug 20, 2008 4:30 am
- Forum: VBScript
- Topic: Rename global groups by appending to name
- Replies: 13
- Views: 6447
Rename global groups by appending to name
absolutely, Its just string manipulation of the name.
$name = "myserver-y"
$name.Substring(0,$name.length-2)
You can use this in the -newname parameter to rename the object.
joel.delatorre2008-08-20 11:31:45
$name = "myserver-y"
$name.Substring(0,$name.length-2)
You can use this in the -newname parameter to rename the object.
joel.delatorre2008-08-20 11:31:45
- Wed Aug 20, 2008 3:07 am
- Forum: VBScript
- Topic: Rename global groups by appending to name
- Replies: 13
- Views: 6447
Rename global groups by appending to name
Well its not really an append function per se`. Im just tacking on an '-y' to the name.
- Tue Aug 12, 2008 1:55 am
- Forum: PowerShell
- Topic: archiving files based on month
- Replies: 7
- Views: 4691
archiving files based on month
Looks like you just using it as a script. Delete the function name and just start with the Param statement as the first part of the script file.
- Sun Aug 10, 2008 12:52 pm
- Forum: VBScript
- Topic: beginner question
- Replies: 2
- Views: 1285
beginner question
Well if you already know what needs to be done and can do it manually then after running the script wouldn't you know if it was a success of not? If you want to start off with a brand new script then start planning what you want the script to do step by step. Visit the MS Scripting guys site to get ...
- Tue Aug 05, 2008 4:29 am
- Forum: VBScript
- Topic: Rename global groups by appending to name
- Replies: 13
- Views: 6447
Rename global groups by appending to name
So do you need a VBScript version of this task? If so, then I'll have to dig out some ADSI and some time as well. 8)
- Tue Aug 05, 2008 3:58 am
- Forum: VBScript
- Topic: Rename global groups by appending to name
- Replies: 13
- Views: 6447
Rename global groups by appending to name
sure. Just Add a Get-content and pipe that to the existing command.get-content groupname.txt | Get-QADGroup | % { Rename-QADObject -Identity $_.DN -NewName $( $_.Name + "-y") -WhatIf}Far from genius however.
- Tue Aug 05, 2008 3:27 am
- Forum: VBScript
- Topic: Rename global groups by appending to name
- Replies: 13
- Views: 6447
Rename global groups by appending to name
While I dont have a VBScript example this can be VERY easily done in PowerShell using Quest AD Cmdlets. So easily as a matter of fact that it can be done in one line of code. Get-QADGroup | % { Rename-QADObject -Identity $_.DN -NewName $( $_.Name + "-y") -WhatIf}Take note of the -Whatif pa...
- Tue Jul 29, 2008 5:55 am
- Forum: VBScript
- Topic: Finding new Users accounts
- Replies: 2
- Views: 1337
Finding new Users accounts
You have an error in your query. it should be something like this"SELECT Name, whenCreated FROM 'LDAP://dc=yourdomain,dc=com' WHERE objectCategory='user' and " & _ "whenCreated >='" & dtmCreationDate & "'"Notice the 'and'Would have responded early but just h...
- Thu Jul 10, 2008 6:26 am
- Forum: VBScript
- Topic: reading from - writing to a text file
- Replies: 3
- Views: 1553
reading from - writing to a text file
Just a small tip to help troubleshoot. Start simple. Try not to include too much code at first. Tackle your objective one step at a time. For example. Try to get just the name of the server written to the text file. Once you get that, try to get the description of the nic. Then the ip, then the subn...