# Which class can i use instead of label to show list and how can order DrRacket to close the previous window after the next one opens?

**URL:** <https://racket.discourse.group/t/which-class-can-i-use-instead-of-label-to-show-list-and-how-can-order-drracket-to-close-the-previous-window-after-the-next-one-opens/890>\
**Category:** Questions & Answers\
**Tags:** question, drracket\
**Created:** [April 17, 2022, 10:05am UTC](https://racket.discourse.group/t/which-class-can-i-use-instead-of-label-to-show-list-and-how-can-order-drracket-to-close-the-previous-window-after-the-next-one-opens/890 "2022-04-17T10:05:12Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![osman44](https://avatars.discourse-cdn.com/v4/letter/o/85f322/32.png) [@osman44](https://racket.discourse.group/u/osman44)\
**Post date:** [April 17, 2022, 10:05am UTC](https://racket.discourse.group/t/which-class-can-i-use-instead-of-label-to-show-list-and-how-can-order-drracket-to-close-the-previous-window-after-the-next-one-opens/890/1 "2022-04-17T10:05:12Z")

</div>

Hi,i am in the midst of creating a graphical user interface of a story i created,i have this long script ,which is why i stored in a list,so i dont have to paste a long script into the function.I tried to call the list into msgs but label does not accept lists,which class will allow me to input this kind of data,and here is my list which i want to attach to this msgs function

(define chapter1-choice1-script '( "The wind howls, the raven’s shriek, the fog blows—something is  
afoot, and t’was something terrible indeed. As the fog began to  
clear, Sir Skelenbottom found his dear half-brother’s deceased  
corpse amongst their very manor. The victim in question was none  
other than Sir Skelentop of Ardenvald, and you, the new  
detective, are going to solve the case behind his sudden murder.  
Best of luck and wishes to you, young blood--may you choose the  
path to justice you deem most appropriate...  
You arrive to the outskirts of Skelen Manor and approach the  
commanding officer for a debriefing.  
Good evening, Detective... Faren, I’ll be your superior for this  
operation, codename Crow.  
Sorry if the call to action was sudden, you were the only  
detective around town when the tragedy happened.”  
He does not look sorry at all.  
As you already know, the Sir of Ardenvald, Skelentop, has been  
murdered. All we found on his body were his wallet containing a  
small photograph of what appears to be his lover, and a butter  
knife found within the inside of his right boot, I know...  
strange.  
You’re overwhelmed by the seemingly confusing information; you  
haven’t done much detective work—even worse something of this  
scale.  
The only witness in the Manor, his half-brother Sir  
Skelenbottom, hasn’t been able to give a statement yet. He is...  
rightfully traumatized, you see.  
We hope that you and your smooth talking can, well, talk some  
sense into him to share more information, so please, go forth  
into Skelen Manor and do what you’ve got to do, no one will get  
in your way, Detective Faren. Crime scene’s all yours" ))

(define msgs (new message% [parent frames]  
[label chapter1-choice1-script]))

i get this error message

instantiate: no argument for required init variable  
init variable name: label  
instantiated class name: message%

---

<div class="post-metadata">

**Author:** ![simonls](https://yyz2.discourse-cdn.com/free1/user_avatar/racket.discourse.group/simonls/32/170_2.png) [@simonls](https://racket.discourse.group/u/simonls)\
**Post date:** [April 17, 2022, 4:24pm UTC](https://racket.discourse.group/t/which-class-can-i-use-instead-of-label-to-show-list-and-how-can-order-drracket-to-close-the-previous-window-after-the-next-one-opens/890/2 "2022-04-17T16:24:08Z")

</div>

You could use a text-field% it allows `label` to be `#f`, you can use its `init-value` to provide initial (multiline) text. Take a look at `string-join`. If you want to you can use its `enable` with `#f` to prevent the user from editing the text. Try to use `style` with `'(multiple)`.

I have no idea how you are opening the windows, so I can't really tell you how to close some previous window. If it is a frame and you have a variable that refers to it e.g. `previous-frame`, you can use `(send previous-frame show #f)` to close it.
