Yes you must be out of Thailand to apply because you have to submit exit stamps from passport and it should all be submitted via evisa app, however this is Thailand, in vietianne you can pay an agent 10k to 15k and get new visa in 1 to 3 days, the agent submits the documents in person !! And when it is done he gets the email visa document and prints for you - this was certainly the case with a non B this week, non o, provided you have all of the documentation, should be the same