How do I write a IDN domain name with IDN codes?
mjölk.com with IDN codes? (mjölk is milk in swedish)
And is there any list of available IDN codes and letters? E.g. all possible for .com ?
What you're looking for is called Punycode. You can do pretty much any Unicode character with it, I believe.
Verisign have a nifty conversion tool here.
In your scenario,
(You can try this in your browser. In both my FF and IE, http://mjölk.com redirects you to http://www.xn--mjlk-6qa.com/