전자실업무현황 관련 추가
This commit is contained in:
@@ -13,7 +13,7 @@ using System.Text;
|
||||
using System.Text.RegularExpressions;
|
||||
using System.Threading.Tasks;
|
||||
|
||||
namespace FEQ0000
|
||||
namespace FPJ0000
|
||||
{
|
||||
/// <summary>
|
||||
/// generic method Extension
|
||||
@@ -112,9 +112,28 @@ namespace FEQ0000
|
||||
public static bool IsNumeric(this string input)
|
||||
{
|
||||
double data;
|
||||
input = input.Replace(",", "");
|
||||
return double.TryParse(input, out data);
|
||||
//return Regex.IsMatch(input, @"^\d+$");
|
||||
}
|
||||
public static int ToInt(this string input)
|
||||
{
|
||||
input = input.Replace(",", "");
|
||||
if (input.IsNumeric() == false) return 0;
|
||||
return int.Parse(input);
|
||||
}
|
||||
public static decimal ToDecimal(this string input)
|
||||
{
|
||||
input = input.Replace(",", "");
|
||||
if (input.IsNumeric() == false) return 0;
|
||||
return decimal.Parse(input);
|
||||
}
|
||||
public static double ToDouble(this string input)
|
||||
{
|
||||
input = input.Replace(",", "");
|
||||
if (input.IsNumeric() == false) return 0;
|
||||
return double.Parse(input);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// isnullorempty 를 수행합니다.
|
||||
|
||||
Reference in New Issue
Block a user