# moveline to empty line fails

**URL:** https://community.mp3tag.de/t/moveline-to-empty-line-fails/3063
**Category:** Web Sources Discussion
**Created:** [March 20, 2006, 10:51am UTC](https://community.mp3tag.de/t/moveline-to-empty-line-fails/3063 "2006-03-20T10:51:49Z")
**Posts on this page:** 6
**Page:** 1

<div class="post-metadata">

### Author: ![anon40688970](https://community.mp3tag.de/letter_avatar_proxy/v4/letter/a/898d66/32.png) [@anon40688970](https://community.mp3tag.de/u/anon40688970)
#### Post date: [March 20, 2006, 10:51am UTC](https://community.mp3tag.de/t/moveline-to-empty-line-fails/3063/1 "2006-03-20T10:51:49Z")

</div>

Hi all,

consider the following html fragment:

```
<TR>
  <TD valign="top" align="right"><i>foo</i></TD>
<TD><b>Bold text</b>

```

```
<TR>
  <TD valign="top" align="right"><i>next row</i></TD>
<TD><b>Bold text</b>

```

Assuming further that the current position is at the first tag. If now a "moveline 3" jumps behind the first **and** the target line is empty (i.e. just consists of a carriage return and/or newline) then the script will fail with this error "ERROR(Lnnn/moveline): line does not exist".

A bug?

---

<div class="post-metadata">

### Author: ![dano](https://community.mp3tag.de/user_avatar/community.mp3tag.de/dano/32/6_2.png) [@dano](https://community.mp3tag.de/u/dano)
#### Post date: [March 20, 2006, 11:39am UTC](https://community.mp3tag.de/t/moveline-to-empty-line-fails/3063/2 "2006-03-20T11:39:15Z")

</div>

Try moveline 3 1

Or the best thing is to avoid moveline if possible

---

<div class="post-metadata">

### Author: ![anon40688970](https://community.mp3tag.de/letter_avatar_proxy/v4/letter/a/898d66/32.png) [@anon40688970](https://community.mp3tag.de/u/anon40688970)
#### Post date: [March 20, 2006, 12:12pm UTC](https://community.mp3tag.de/t/moveline-to-empty-line-fails/3063/3 "2006-03-20T12:12:31Z")

</div>

> [@](#):
>
> Try moveline 3 1

What is the meaning of the second argument?  
An absolute column number?

> [@](#):
>
> Or the best thing is to avoid moveline if possible
> 
> \<{POST\_SNAPBACK}\>

Yes, of course. But that's not always possible,  
especially in situations where a simple  
findline "foo" will eventually fail because "foo"  
is optional and the parsing will be aborted too  
early.  
The conditionals like IF and WHILE only compare  
the text at the current position to the argument, so  
its sometimes a bit tricky to move around the web  
source data if it has many optional components which  
may or may not be there.

Anyway, please let me know if there is documentation,  
a manual or tutorial which is more up-to-date than the  
one which is deployed with the programm. I'm sure  
that my script can be improved...

Thanks again

---

<div class="post-metadata">

### Author: ![dano](https://community.mp3tag.de/user_avatar/community.mp3tag.de/dano/32/6_2.png) [@dano](https://community.mp3tag.de/u/dano)
#### Post date: [March 20, 2006, 1:07pm UTC](https://community.mp3tag.de/t/moveline-to-empty-line-fails/3063/4 "2006-03-20T13:07:00Z")

</div>

If you add a 1 as last argument, the script will not terminate if moveline goes in an empty line.  
You can also use it on findline and findinline  
findline 1 1 or findinline 1 1 (you need two numbers here because they have an optional parameter)  
If findinline fails, the pointer will jump to the end of the row.

Have a look at my discogs or AMG scripts as example.

And no, there is no futher documentation available at the moment.

---

<div class="post-metadata">

### Author: ![anon40688970](https://community.mp3tag.de/letter_avatar_proxy/v4/letter/a/898d66/32.png) [@anon40688970](https://community.mp3tag.de/u/anon40688970)
#### Post date: [March 20, 2006, 9:10pm UTC](https://community.mp3tag.de/t/moveline-to-empty-line-fails/3063/5 "2006-03-20T21:10:08Z")

</div>

> [@](#):
>
> If you add a 1 as last argument, the script will not terminate if moveline goes in an empty line.  
> You can also use it on findline and findinline  
> findline 1 1 or findinline 1 1 (you need two numbers here because they have an optional parameter)  
> If findinline fails, the pointer will jump to the end of the row.
> 
> Have a look at my discogs or AMG scripts as example.
> 
> And no, there is no futher documentation available at the moment.
> 
> \<{POST\_SNAPBACK}\>

Thanks a lot! Knowing that this should work with findline and findinline should  
help me a lot. It will probably allow me to replace some strange moveline/if  
jumps with cleaner findline/findinline equivalents.

Apropos - 'saynextnumber' - what exactly is it supposed to do? I bet you know  
how it works, don't you :-; ?

---

<div class="post-metadata">

### Author: ![dano](https://community.mp3tag.de/user_avatar/community.mp3tag.de/dano/32/6_2.png) [@dano](https://community.mp3tag.de/u/dano)
#### Post date: [March 20, 2006, 9:59pm UTC](https://community.mp3tag.de/t/moveline-to-empty-line-fails/3063/6 "2006-03-20T21:59:31Z")

</div>

**saynextnumber**  
_It should just output the next number. No parameters._

More command infos maybe in the next days.
