Solved

KIX script: map drive based on OU membership

Posted on 2008-06-11
3
2,603 Views
Last Modified: 2012-06-22
I am trying to convert our current vbs login script to kix script.

The script maps a drive based on OU membership, eg:
===============================
select case LCase (oParent.name)
     case "ou=execs"
      oNet.RemoveNetworkDrive "S:"
      oNet.MapNetworkDrive "S:", "\\CORPFS01\Execs$"
end select
==============================

I want to do the same thing with KIX, but am having no luck in getting the IF inOU("Execs") variable working.

Is there a simple way to do this?


Mapping drives via group memberships is working fine by using
IF InGroup("groupname") =1
   use f: \\corpfs01\fileshare
ENDIF

What am I missing???????
0
Comment
Question by:davewhy
  • 2
3 Comments
 
LVL 3

Accepted Solution

by:
Isorg earned 500 total points
Comment Utility
in kix there is no InOU() command.

but there is a really nice InContainer() UDF that can be found here.  http://www.kixtart.org/forums/ubbthreads.php?ubb=showflat&Number=82433&site_id=1#import
0
 

Author Comment

by:davewhy
Comment Utility
Thankyou Isorg.  I shall setup the UDF and try to call from the script.  Any tips?

0
 

Author Comment

by:davewhy
Comment Utility
Isorg, the InContainer() and dependent TranslateName() UDF's worked a treat.  I have included both in a seperate UDF (.kxf) file, called them from the script, and got the result I wanted.  Brilliant.
0

Featured Post

What Security Threats Are You Missing?

Enhance your security with threat intelligence from the web. Get trending threat insights on hackers, exploits, and suspicious IP addresses delivered to your inbox with our free Cyber Daily.

Join & Write a Comment

If you get a (Blue Screen of Death), your system writes a small file called a minidump. Your first step is to make certain your computer is setup to record memory dumps. Right click My Computer, choose properties. Click on the advanced tab, an…
This article is meant to give a basic understanding of how to use R Sweave as a way to merge LaTeX and R code seamlessly into one presentable document.
This tutorial will teach you the core code needed to finalize the addition of a watermark to your image. The viewer will use a small PHP class to learn and create a watermark.
In this seventh video of the Xpdf series, we discuss and demonstrate the PDFfonts utility, which lists all the fonts used in a PDF file. It does this via a command line interface, making it suitable for use in programs, scripts, batch files — any pl…

771 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

12 Experts available now in Live!

Get 1:1 Help Now