Editable_if expression based on value from another table

Hi,

I want to know how could to achieve the following,

I have a table where in a particular cell i want to add a editable_if expressionโ€ฆhere i want it to be editable on when the value of another column in another table is for instance โ€œPendingโ€. If its โ€œCompletedโ€, i want it to not be editable.

The common info for both rows in both the tables is Order No

How to do this ???

Solved Solved
0 3 318
1 ACCEPTED SOLUTION

Sure! If only one user:

AND(
  (USEREMAIL() = "abc@gmail.com"),
  (
    "Completed"
    <> LOOKUP(
      [_THISROW].[Order ID],
      "Anther Table",
      "Order ID",
      "Another Column"
    )
  )
)

If more than one user:

AND(
  IN(
    USEREMAIL(),
    LIST(
      "abc@gmail.com",
      "def@gmail.com"
    )
  ),
  (
    "Completed"
    <> LOOKUP(
      [_THISROW].[Order ID],
      "Anther Table",
      "Order ID",
      "Another Column"
    )
  )
)

In both of the above, I made the assumption that you only want the column value editable if the user is one of the designated ones and the other tableโ€™s column is not Completed. If instead you want the column editable if one of the designated users or Completed, change the initial AND to OR.

See also:


View solution in original post

3 REPLIES 3

Steve
Platinum 4
Platinum 4

Try:

(
  "Completed"
  <> LOOKUP(
    [_THISROW].[Order ID],
    "Anther Table",
    "Order ID",
    "Another Column"
  )
)

See also:

can i also add a particular user who can edit this like useremail()=โ€œabc@gmail.comโ€ to the above expression

Sure! If only one user:

AND(
  (USEREMAIL() = "abc@gmail.com"),
  (
    "Completed"
    <> LOOKUP(
      [_THISROW].[Order ID],
      "Anther Table",
      "Order ID",
      "Another Column"
    )
  )
)

If more than one user:

AND(
  IN(
    USEREMAIL(),
    LIST(
      "abc@gmail.com",
      "def@gmail.com"
    )
  ),
  (
    "Completed"
    <> LOOKUP(
      [_THISROW].[Order ID],
      "Anther Table",
      "Order ID",
      "Another Column"
    )
  )
)

In both of the above, I made the assumption that you only want the column value editable if the user is one of the designated ones and the other tableโ€™s column is not Completed. If instead you want the column editable if one of the designated users or Completed, change the initial AND to OR.

See also:


Top Labels in this Space