Off the top of my head you have two options.
1. Go south to Vientiane and cross the border into Thailand and Nong Khai.
If your only reason for going to Chiang Mai is to catch the train then it might be easier to cancel it and get one back to Bangkok from Nong Khai.
Otherwise you'll probably have to get a bus to Udon Thani (about an hour) and then another bus to Chiang Mai from there (about another 12 hours I think).
2. Go North to Luang Prabang. Either fly to Chiang Mai(Lao Airlines does that route) or do the two day slow boat trip to Huay Xai and cross into Thailand from there. There's a thread about that slow boat trip somewhere on here if you do a search.
Thanks for your help, we're looking at spending some time in Chiang Mai before heading to Bangkok, so the bus is looking to be the best option. Would like to do the boat, even taking into consideration the things that I've heard, but we're a bit pressed for time
#3 TravellingAnge has been a member since 24/6/2009. Posts: 2
Hmm. If you do that you are going to miss some truly spectacular scenery. The road between Vang Vieng and Luang Prabang is wonderful for scenery, much better than anything you'll see around Chiang Mai IMO. Lao Airlines are a bit expensive but if you can afford it, it might be worth doing that rather than retracing your steps. (I assume you'll be flying into Vientiane)
Another option is a "posh boat" to the Thai border.
I don't know how much time you have, but definitely check out Brucemoon's trip report. If you have time, he had some stops that were must sees / dos.
#5 MADMAC has been a member since 6/6/2009. Posts: 6,957