Re: variable question

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • Terry Reedy

    Re: variable question



    Support Desk wrote:
    I am trying to assign a variable using an if / else statement like so:
    If condition1:
    Variable = something
    If condition2:
    Variable = something else
    Do stuff with variable.
    But the variable assignment doesn’t survive outside the if statement.
    When things do not work as you expect, post minimal actual code that
    does not work, what happened, and if not obvious, what you expected
    different.

Working...