Photo Gallery Member List Search Calendars FAQ Ticket List Log Out


If Not problem

 
Logged in as: Guest
arrSession:exec spGetSession 2,2,61833
 Active Users: There are 0 members and 0 guests.
 Users viewing this topic: none
 

 

 
  
  Printable Version
All Forums >> [Scripting] >> WSH & Client Side VBScript >> If Not problem
  Do you like VisualBasicScript.com? Link to us and help spread the word about our forum. Thanks!
Page: [1]
Login
Message << Older Topic   Newer Topic >>
 If Not problem - 6/25/2008 12:29:40 AM   
  SirBlade

 

Posts: 28
Score: 0
Joined: 1/11/2006
Status: offline
I've made the following script to give me some info about right on exchange mailboxes. This work fine. But I;m only interested in the explicitly defined rights, I  want to ignore all inherited rights. Unfortunately the output I need is in the Else part of the If...then...else... I can comment out the wscript.echo command between "if" and "else" but that not very nice looking. Change "if" into "if not" doesn't produce the required result either. What do


      
 
 
Post #: 1
 
 RE: If Not problem - 6/25/2008 12:36:23 AM   
  mbouchard


Posts: 1894
Score: 14
Joined: 5/15/2003
From: USA
Status: offline
You could just add a NOT in there

    If ace.AceFlags And NOT ADS_ACEFLAG_INHERITED_ACE Then
       wscript.echo Ace.AceFlags & Vbtab & "Explicit" & VbTab & Ace.AccessMask & VbTab & AceName
    End If
Not sure if that is what it would be since I am not that familiar with Exchange scripting, but it should give you a start.

_____________________________

Mike

For useful Scripting links see the Read Me First stickey!

Always remember Search is your friend.

(in reply to SirBlade)
 
 
Post #: 2
 
 RE: If Not problem - 6/25/2008 12:56:38 AM   
  SirBlade

 

Posts: 28
Score: 0
Joined: 1/11/2006
Status: offline
quote:

ORIGINAL: mbouchard

You could just add a NOT in there

   If ace.AceFlags And NOT ADS_ACEFLAG_INHERITED_ACE Then
      wscript.echo Ace.AceFlags & Vbtab & "Explicit" & VbTab & Ace.AccessMask & VbTab & AceName
   End If
Not sure if that is what it would be since I am not that familiar with Exchange scripting, but it should give you a start.


No, I also tried that earlier. if I do that all the lines which were originally printed by both wscript.echo statements will be printed using only the first.

(in reply to mbouchard)
 
 
Post #: 3
 
 RE: If Not problem - 6/25/2008 1:15:17 AM   
  SirBlade

 

Posts: 28
Score: 0
Joined: 1/11/2006
Status: offline
Found the solution:


      

and remove the "else" part.

(in reply to SirBlade)
 
 
Post #: 4
 
 
 
  

If you found our site useful please link to us <a href="http://www.visualbasicscript.com">VisualBasicScript.com</a>.
All Forums >> [Scripting] >> WSH & Client Side VBScript >> If Not problem Page: [1]
Jump to:





New Messages No New Messages
Hot Topic w/ New Messages Hot Topic w/o New Messages
Locked w/ New Messages Locked w/o New Messages
 Post New Thread
 Reply to Message
 Post New Poll
 Submit Vote
 Delete My Own Post
 Delete My Own Thread
 Rate Posts