Sublime Forum

Search a number greater than

#1

Hey guys,

i try to search and replace all numbers greater than 1000. How can i do this on sublime text? I try a lot of ideas myself, f.e. with the “<” command or something… nothing func…, ;(( Can anyone help me please?

Thanks.

0 Likes

#2

You can just use the search-replace function (ctrl+h) with regex enabled (alt+r) and search for \d{4,}, i.e. a number with at least 4 digits. If you want to avoid negative numbers you could use a negative lookbehind for -, i.e. (?<!-)\d{4,}

3 Likes

#3

Top! thanks.

0 Likes