Is it possible to change if a mesh affects nav mesh during run time

Thank you for all the alternate solutions. I found one that would work for my game using a modifier volume. Much simpler than the original solution proposed.