How to convert unsigned integer using the method Convert.ChangeType() if I want to get the number is less than zero ?
Example
uint l = 0xFFF0;
short ret = (short)Convert.ChangeType(l, typeof(short)); // here error instead of -16
How to convert unsigned integer using the method Convert.ChangeType() if I want to get the number is less than zero ?
Example
uint l = 0xFFF0;
short ret = (short)Convert.ChangeType(l, typeof(short)); // here error instead of -16
I am decided that the problem create own implementation class whith interface IConvertible.
Like this
Call