I would like to know how to highlight matches after invoking a function p.e.
function! s:MyFunction() let search = '\d\+' let @/ = search return "normal n" endfunction :call <SID>Test()<CR> does not highlight the matches. I know I can add :set hls<CR> after the function call but that creates problems with output of echo commands. :set hls<CR> does also create problems if the function waits for an user input p.e. :%s/pattern/replace-pattern/gc Thanks in advance. -- You received this message from the "vim_use" maillist. Do not top-post! Type your reply below the text you are replying to. For more information, visit http://www.vim.org/maillist.php