Solved

Appending Roles

Posted on 2004-09-30
13
549 Views
Last Modified: 2013-12-18
@IsMember("[Sales]"; @UserRoles)

How would I add another role to this?

[PMMEMEA]

would it be something like this

@IsMember("[Sales]":"[EMEAPMM]"; @UserRoles)
0
Comment
Question by:Jaziar
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 4
  • 4
  • 3
  • +2
13 Comments
 
LVL 24

Expert Comment

by:HemanthaKumar
ID: 12192831
Right, (@IsMember("[Sales]":"[EMEAPMM]"; @UserRoles)) means that user has both the roles enabled...

What is that you want to check or do ?

~Hemanth
0
 

Author Comment

by:Jaziar
ID: 12192859
I want the user can be in one or the other not both
0
 
LVL 14

Expert Comment

by:p_partha
ID: 12193183
That's get tricky as there might be a logical flaw.. i would try this:

!@IsMember(@UserRoles; "[Sales]") & 
!@IsMember(@UserRoles; "[EMEAPMM]")
0
Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

 
LVL 13

Expert Comment

by:CRAK
ID: 12193231
I usually check with:

@Userroles *= "[Sales]":"[EMEAPMM]"
0
 
LVL 14

Expert Comment

by:p_partha
ID: 12193250
But crak, he wants to hide it , if the user has both the roles

Partha
0
 
LVL 9

Accepted Solution

by:
HappyFunBall earned 50 total points
ID: 12193311
That's not exactly right partha - the parameters are backwards.

This should work:

(@IsMember("[Sales]"; @UserRoles) | @IsMember("[EMEAPMM]"; @UserRoles)) & 
!@IsMember("[Sales]":"[EMEAPMM]"; @UserRoles)

That says, return 1 if Sales Or EMEAPMM roles are selected but not both.
0
 
LVL 13

Expert Comment

by:CRAK
ID: 12193329
Hmm.... I overread that bit.
In that case I guess there's nothing left to add other that to congratulate you!
;-))
0
 
LVL 13

Expert Comment

by:CRAK
ID: 12193365
I don't see the full features of that one yet (I'm getting tired), but HappyFunBall does have a point Partha:
What if the user has neither?
0
 
LVL 14

Expert Comment

by:p_partha
ID: 12193383
Yeah funball is right Crak.. Hide whens are always Head aches...:)

Partha
0
 

Author Comment

by:Jaziar
ID: 12193450
The user may not have either. I also hate hide statements!!!!
0
 
LVL 13

Expert Comment

by:CRAK
ID: 12193451
Then why do you keep trying? There are loads of other challenges!
I once found getting a headacke a pretty good reason to try to stop bumpung my head against things.
Worked well! Saved lots on painkillers too!
0
 
LVL 14

Expert Comment

by:p_partha
ID: 12193464
Jaziar,
If funball's logic also not fits for you, then put down the requirements explaining exactly what do u want

Partha
0
 

Author Comment

by:Jaziar
ID: 12193633
Never thought about not bumping my head Crak - WOW
Funball's logic works for me - You guys have a good weekend and buy yourself a beer with the savings from the painkillers.  Thanks to all of you
0

Featured Post

[Webinar] Learn How Hackers Steal Your Credentials

Do You Know How Hackers Steal Your Credentials? Join us and Skyport Systems to learn how hackers steal your credentials and why Active Directory must be secure to stop them. Thursday, July 13, 2017 10:00 A.M. PDT

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Lack of Storage capacity is a common problem that exists in every field of life. Here we are taking the case of Lotus Notes Emails, as we all know that we are totally depend on e-communication i.e. Emails. This article is fully dedicated to resolvin…
IBM Notes offer Encryption feature using which the user can secure its NSF emails or entire database easily. In this section we will discuss about the process to Encrypt Incoming and Outgoing Mails in depth.
There's a multitude of different network monitoring solutions out there, and you're probably wondering what makes NetCrunch so special. It's completely agentless, but does let you create an agent, if you desire. It offers powerful scalability …
Add bar graphs to Access queries using Unicode block characters. Graphs appear on every record in the color you want. Give life to numbers. Hopes this gives you ideas on visualizing your data in new ways ~ Create a calculated field in a query: …

688 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