Hi Bram, On Fri, Dec 25, 2020 at 4:54 AM Bram Moolenaar <[email protected]> wrote:
> > Yegappan wrote: > > > The following vim9 script generates a E1030 error: > > ============================================ > > vim9script > > var bnr = bufnr() > > bnr->setbufline(1, "Hello") > > ============================================ > > > > The following fragment works properly: > > ============================================ > > vim9script > > var bnr = bufnr() > > setbufline(bnr, 1, "Hello") > > ============================================ > > The base is passed as the third argument, the text. This works: > > "Hello"->setbufline(bnr, 1) > > The idea is that you somehow generate the text with a series of function > calls, then store it in a buffer line. > > > Thanks. I somehow missed reading that in the help. As I was using other buffer functions (getbufline(), setbufvar(), getbufvar(), getbufinfo(), deletebufline(), bufloaded(), etc.) as methods using the buffer number, I tried that with the setbufline() function. Regards, Yegappan -- -- You received this message from the "vim_dev" 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 --- You received this message because you are subscribed to the Google Groups "vim_dev" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To view this discussion on the web visit https://groups.google.com/d/msgid/vim_dev/CAAW7x7%3DAr%2BzUpJytiqgMY2xme2p80jnGZ423NejYH-ewUDu65w%40mail.gmail.com.
