Hello,
I'm creating my own type for representing css values (like pixels eg. 12px ). To be able to add/subtract/multiply/... my type and ints I've defined two implicit operators to and from int. Everything works great except one thing.. If I write:
CssUnitBase c1 = 10;
Console.WriteLine(c1);
I get "10" instead of "10px" - implicit conversion to int is used instead ToString() method. How can I prevent that?