How to create string variable without any txt elment

How can I create string variable in nextion editor to save string value.

In the component pane of the editor, there is a component, called „variable“. Add it to your page (appears in the bottom line below the page‘s visual), go to the attribute pane and change its style from „number“ to „text“.

Thanks it did solved my problem.

Can this string variable be global (accessible on all pages)
I tried with vscope global but that doesn’t work

Vscope global is an important step. But when accessing your global variable from another page, you’ll have to tell the compiler the origin, though, by fully addressing the component with page.component.attribute in your code. Example btn0.txt=page0.va2.txt