The problem related to comma in the Textbox is because you are using an Int64.TryParse()
, so the expected value are an integer…
When you use a value with comma, isn’t a integer value anymore, so you need to use Double.TryParse()
or Decimal.TryParse()
.
But, even using this, I recomend you to use a MaskedTextbox (like described in the comments), so you don’t need to worry about handling if the user inputs a comma or a dot.
solved Text-box Functions