# bizarre error

**URL:** https://forum.highend3d.com/t/bizarre-error/6839
**Category:** Maya
**Tags:** mel
**Created:** [October 1, 2001, 4:43am UTC](https://forum.highend3d.com/t/bizarre-error/6839 "2001-10-01T04:43:02Z")
**Posts on this page:** 4
**Page:** 1

<div class="post-metadata">

### Author: ![wcy93](https://forum.highend3d.com/letter_avatar_proxy/v4/letter/w/8797f3/32.png) [@wcy93](https://forum.highend3d.com/u/wcy93)
#### Post date: [October 1, 2001, 4:43am UTC](https://forum.highend3d.com/t/bizarre-error/6839/1 "2001-10-01T04:43:02Z")

</div>

can anyone tell me why I might be getting an error when the command for this menu item is executed? It gives me an "unterminated string" error. whats the deal with that?

menuItem -l "no selected items" -command ( "print "no selected itemsn" " );

cheers,.

---

<div class="post-metadata">

### Author: ![tnt](https://forum.highend3d.com/letter_avatar_proxy/v4/letter/t/9fc29f/32.png) [@tnt](https://forum.highend3d.com/u/tnt)
#### Post date: [October 1, 2001, 6:57am UTC](https://forum.highend3d.com/t/bizarre-error/6839/2 "2001-10-01T06:57:14Z")

</div>

the line has to look like this:

menuItem -l "no selected items" -command ("print "no selected itemsn"");

---

<div class="post-metadata">

### Author: ![\-mike--1](https://forum.highend3d.com/letter_avatar_proxy/v4/letter/-/8e8cbc/32.png) [@\-mike--1](https://forum.highend3d.com/u/-mike--1)
#### Post date: [October 1, 2001, 7:11am UTC](https://forum.highend3d.com/t/bizarre-error/6839/3 "2001-10-01T07:11:14Z")

</div>

> [@](#):
>
> In reply to:   
> can anyone tell me why I might be getting an error when the command for this menu item is executed? It gives me an "unterminated string" error. whats the deal with that?
> 
> menuItem -l "no selected items" -command ( "print "no selected itemsn" " );
> 
> cheers,.

Hi,  
if you want to use a `` in your output string (here in the escape sequence for new line) you have to  
mask it, so using `n` instead `n` should work for you.

menuItem -l "no selected items" -command ( "print "no selected itemsn" " );

[mike]

---

<div class="post-metadata">

### Author: ![wcy93](https://forum.highend3d.com/letter_avatar_proxy/v4/letter/w/8797f3/32.png) [@wcy93](https://forum.highend3d.com/u/wcy93)
#### Post date: [October 1, 2001, 7:30am UTC](https://forum.highend3d.com/t/bizarre-error/6839/4 "2001-10-01T07:30:12Z")

</div>

awesome, thanks for that...
