using System.Text.RegularExpressions;
:
:
:
public string isNumber(string chk)
{
string patten = @"[^0-9+]+";
string buff;
Regex regex = new Regex(patten);
buff = regex.Replace(chk, "");
if (buff.Length > 0 && int.Parse(buff) > 0)
return buff;
else
return "false";
}
/**************
메타문자 의미
------------------------
^ 라인의 처음
$ 라인의 마지막
\w 문자(영숫자) [a-zA-Z_0-9]
\s Whitespace (공백,뉴라인,탭..)
\d 숫자
* Zero 혹은 그 이상
+ 하나 이상
? Zero 혹은 하나
. Newline을 제외한 한 문자
[ ] 가능한 문자들
[^ ] 가능하지 않은 문자들
[ - ] 가능 문자 범위
{n,m} 최소 n개, 최대 m개
( ) 그룹
| 논리 OR
***************/
2015년 8월 25일 화요일
피드 구독하기:
글 (Atom)
vsftpd FTP 서버 접속은 성공하였으나, "디렉토리 목록 조회 실패" 현상 발생시
FTP Passive 모드를 활성화 필요. 1. vsftpd 설정 변경 /etc/vsftpd/vsftpd.conf 상에 아래 내용 추가 기입 #passive modpasv_enable=YES pasv_min_port=5001 pasv...
-
from PIL import Image, ImageTk E : Unable to locate package python3 - pil E : Unable to locate package python3 - imaging - tk $sudo ...
-
FTP Passive 모드를 활성화 필요. 1. vsftpd 설정 변경 /etc/vsftpd/vsftpd.conf 상에 아래 내용 추가 기입 #passive modpasv_enable=YES pasv_min_port=5001 pasv...