Ejemplo n.º 1
0
        public int GetInputValue(bool IsRead)
        {
            int    InputValue;
            string NumberStr;

            if (IsRead)
            {
                NumberStr = ReadMemoryBox.Text;
            }
            else
            {
                NumberStr = WriteMemoryBox.Text;
            }
            if (NumberStr.StartsWith("0x"))
            {
                NumberStr  = NumberStr.Substring(2);
                InputValue = Int32.Parse(NumberStr, System.Globalization.NumberStyles.HexNumber);
            }
            else
            {
                InputValue = Int32.Parse(NumberStr);
            }

            return(InputValue);
        }