Solved

Excel add other variable to if statement

Posted on 2014-09-11
2
119 Views
Last Modified: 2014-09-11
Dear experts,

Could anybody assist with this:

Add other variabe
=IF(ISERROR(SEARCH("GIL",P14))*1=1,"enable-mailbox -identity "&A14&" -Alias "&A14,"enable-mailbox -identity "&A14&" -Alias "&A14&" -database DBGIL"&TEXT(INT(RAND()*42)+1,"000"))

Should change to
if "GIL" then "enable-mailbox -identity "&A14&" -Alias "&A14&" -database DBGIL"&TEXT(GANZZAHL(ZUFALLSZAHL()*42)+1,"000"))
iF "GAL" then "enable-mailbox -identity "&B2&" -Alias "&B2&" -database DBGAL"&TEXT(GANZZAHL(ZUFALLSZAHL()*30)+1,"00")
all other ,"enable-mailbox -identity "&A14&" -Alias "&A14
0
Comment
Question by:Mandy_
[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
2 Comments
 
LVL 52

Accepted Solution

by:
Rgonzo1971 earned 500 total points
ID: 40316411
pls try

="enable-mailbox -identity "&IF(ISERROR(SEARCH("GIL",P14)),IF(ISERROR(SEARCH("GAL",P14)),A14&" -Alias "&A14,B2&" -Alias "&B2&" -database DBGAL"&TEXT(INT(RAND()*30)+1,"00")),A14&" -Alias "&A14&" -database DBGIL"&TEXT(INT(RAND()*42)+1,"000"))
0
 
LVL 2

Author Closing Comment

by:Mandy_
ID: 40316467
perfect as usual. Thank you so much
0

Featured Post

Free Tool: SSL Checker

Scans your site and returns information about your SSL implementation and certificate. Helpful for debugging and validating your SSL configuration.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

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

This article will guide you to convert a grid from a picture into Excel format using Microsoft OneNote and no other 3rd party application.
After seeing numerous questions for Dynamic Data Validation I notice that most have used Visual Basic to solve the problem. This suggestion is purely formula based and can be used in multiple rows.
This Micro Tutorial will demonstrate in Microsoft Excel how to add style and sexy appeal to horizontal bar charts.
Excel styles will make formatting consistent and let you apply and change formatting faster. In this tutorial, you'll learn how to use Excel's built-in styles, how to modify styles, and how to create your own. You'll also learn how to use your custo…

636 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