Copilot studio Condition node not working. Choice variable selection not saving

Sibusiso 20 Reputation points
2025-05-21T05:39:29.6966667+00:00

I am creating a topic which gives users information in copilot studio. I created a multiple choice question with a choice variable but the selection in the condition goes back to object Object after savings. Do you know what might be happening?Condition error choice not saving

Microsoft Copilot Other
{count} votes

1 answer

Sort by: Most helpful
  1. Karan Shewale 170 Reputation points Microsoft External Staff
    2025-05-21T08:20:11.26+00:00

    Hi Sibusiso,

    you can try this way to resolve this issue. The issue where a choice variable turns into [object Object] in a Condition node happens because the variable is stored as an object, not a plain string.


    Fix: Convert to Text

    To resolve it, cast the choice variable using Text() before the condition.

    Option 1 – Inline Fix:

    If(Text(Topic.YourChoiceVariable) = "Technical", ...)

    Option 2 – Set a new variable first:

    Set(ChoiceAsString, Text(Topic.YourChoiceVariable))

    Then use ChoiceAsString in your condition.


    Documents for reference:

    Power Fx Functions - Text()

    Copilot Studio Authoring Guide

    Thanks,  

    Karan Shewale .

    *************************************************************************  

    If the response is helpful, please click "Accept Answer" and upvote it. You can share your feedback via Microsoft Teams Developer Feedback link. Click here to escalate. 


Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.