If the batch file you provided is what you are using then it might not work...
As ADUC will give DN of the object as command line argument to the script
and iisftp.vbs requires username (samaccountname) of the user to work.
 
so, VBS will be better in this case...
 
' *** Start Code
Dim oUser1 
Set oUser1 = getobject(wscript.arguments(0))
oUser1.FTPDir = oUser1.samaccountname
oUser1.FTPRoot = "\\hermes\Z Drives"
oUser1.SetInfo
Set oUser1 = Nothing
Set ouserFTP = Nothing
' *** End Code
 
--
Kamlesh

 
On 12/24/05, Marc A. Mapplebeck <[EMAIL PROTECTED]> wrote:
I need to propogate the FTPRoot and FTPDir fields in the user objects, they are not available through ADUC, only by using iisftp or a vbs. I am using FTP via IIS in AD Isolation Mode.


From: [EMAIL PROTECTED] [mailto: [EMAIL PROTECTED]] On Behalf Of Al Mulnick
Sent: December 23, 2005 12:17

To: [email protected]
Subject: Re: [ActiveDir] Display Specifier + Command Variables

 
I'm still not clear on whether you want to do this for the homedrive attribute or if you are trying to do something else.
 
Might just be a little dense (that sometimes happens around this time of year). 
 
You want to add a _vbscript_ to your ADU&C so you can right click and enable some function that currently is not available, vs. using a script to enable it in bulk.  Is that correct?
 
I believe you want something similar to this, right? http://www.2000trainers.com/article.aspx?articleID=317&page=2

 
On 12/23/05, Marc A. Mapplebeck <[EMAIL PROTECTED] > wrote:
Sure, I was just using a batch file that called iisftp
the context was "iisftp username"
all Z drives are the homedir of the user stored on our hermes server in the share Z Drives, the purpose of this was to give users access to their homedir remotely.
however, now that I want to use it from within AD Users & Computers, I think I will have to rewrite it to set the variables using vbs.
 
setftp.bat
-----
IIsFtp /SetADProp %1 FTPDir %1
IIsFtp /SetADProp %1 FTPRoot "
\\hermes\Z Drives"
-----
end
 
I will probably end up using a .vbs that looks similar to this:
 
setftp.vbs
-----
Dim ouserFTPDir
Dim ouserFTPDRoot
Dim oUser1
Set oUserFTPDir = GetObject(ouser1(0))
Set oUserFTPRoot = "\\hermes\Z Drives"
oUser1.SetInfo
Set oUser1 = Nothing
Set ouserFTP = Nothing
WScript.Quit
-----
end
 
I'm actually teaching a class right now(yes, one of my students showed up for class the day before the holiday break starts, so I gave him a nice subnetting lab, I'm soo sadistic), so I do not have access to any of my reference/test servers, so this script will prolly crash on line 1. But, the general idea is there.
 

From: [EMAIL PROTECTED] [mailto: [EMAIL PROTECTED]] On Behalf Of Al Mulnick
Sent: December 23, 2005 11:23
To: [email protected]
Subject: Re: [ActiveDir] Display Specifier + Command Variables

 
Marc, can you post the code you're using?  Cleaned up for internet consumption of course.
 
Al

 
On 12/23/05, Marc A. Mapplebeck <[EMAIL PROTECTED] > wrote:
Hi all, I am working on setting up FTP in AD Isolation mode. I have written
a batch file that I run to enable a user on the FTP server, I would like to
change this so that I can just right click on a user in AD Users & Computers
to do this, I have made the modification to the display specifier to call
the batch file, however, it is not passing what I want, does anybody know
if/what the variable is for the CN of the user, or would it be just as easy
to script this with VB instead? If so, does anybody already have a script or
a model that can be used for this? Thanks - Marc


List info   : http://www.activedir.org/List.aspx
List FAQ    : http://www.activedir.org/ListFAQ.aspx
List archive: http://www.mail-archive.com/activedir%40mail.activedir.org/





--
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
"Be the change you want to see in the World"
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Reply via email to