Does Session need to be Active to call AddStandardAlias or ModifyAlias?

  I'm programatically changing the Private & NetDir paths from inside my
code based upon user input.  To do this, I dropconnections & close the
session.  However, I then call AddStandardAlias or ModifyAlias for some
other changes before reactivating the session.  Is this the right order, or
should I open the session with the new settings, then change the alias?