VIEW_Program call GL_Program ?
Posted: Wed Jun 29, 2022 9:15 am
Quiero crear una aplicación que,
1/ primero arrojará un formulario de ventana VIEW_Program, donde el usuario podrá elegir entre varias opciones de personalización.
2/ Una vez presionado el botón Ok en el formulario debe arrojar un GL_Program de acuerdo a esa opción.
Como ejemplo, puedo pensar en una postal navideña presentada como demostración aquí:
Hola mundo en VR-VIEW
http://msxvr.es/doc/wiki/mdwiki.html#!3 ... 6c2ddf6.md
Postal Navideña en VR-Script + GL
http://msxvr.es/doc/wiki/mdwiki.html#!5 ... 13651e9.md
La idea en el código podría ser así:
E2.pi file,
main.pi file,
Pero el comando NewObject no está presente en VIEW_Program.
Preguntas:
1/ ¿Cómo puedo hacer eso?
2/ ¿Cómo puedo pasar el bean de formulario de VIEW_Program a GL_Program?
I want to create an app that,
1/ first will throw a VIEW_Program window form, where the user could choose among several personalization options.
2/ Once pressed the Ok button on the form it should throw a GL_Program according to that option.
As an example, I can think about a Christmas postcard presented as a demo here:
Hola mundo en VR-VIEW
http://msxvr.es/doc/wiki/mdwiki.html#!3 ... 6c2ddf6.md
Postal Navideña en VR-Script + GL
http://msxvr.es/doc/wiki/mdwiki.html#!5 ... 13651e9.md
The idea in code could be like that:
E2.pi file,
main.pi file,
But the NewObject command is not present on VIEW_Program.
Questions:
1/ How can I do that?
2/ How I can pass the form bean from VIEW_Program to the GL_Program?
1/ primero arrojará un formulario de ventana VIEW_Program, donde el usuario podrá elegir entre varias opciones de personalización.
2/ Una vez presionado el botón Ok en el formulario debe arrojar un GL_Program de acuerdo a esa opción.
Como ejemplo, puedo pensar en una postal navideña presentada como demostración aquí:
Hola mundo en VR-VIEW
http://msxvr.es/doc/wiki/mdwiki.html#!3 ... 6c2ddf6.md
Postal Navideña en VR-Script + GL
http://msxvr.es/doc/wiki/mdwiki.html#!5 ... 13651e9.md
La idea en el código podría ser así:
E2.pi file,
Code: Select all
class E2 implements VIEW_Program
{
virtual Start()
{
_wnd = CreateWindow();
_menu = _wnd.CreateMenu();
_section = _menu.AddSection("File");
_section.AddItem("Exit", this, "End");
_label = _wnd.CreateLabel(10, 10, 200, 200);
_label.SetText("Hola mundo!!");
}
function End()
{
//End(0);
NewObject("main", "main");
}
}main.pi file,
Code: Select all
class Main implements GL_Program
{
function Start()
{
//Postal Navideña
...
::Start();
}
}
Preguntas:
1/ ¿Cómo puedo hacer eso?
2/ ¿Cómo puedo pasar el bean de formulario de VIEW_Program a GL_Program?
I want to create an app that,
1/ first will throw a VIEW_Program window form, where the user could choose among several personalization options.
2/ Once pressed the Ok button on the form it should throw a GL_Program according to that option.
As an example, I can think about a Christmas postcard presented as a demo here:
Hola mundo en VR-VIEW
http://msxvr.es/doc/wiki/mdwiki.html#!3 ... 6c2ddf6.md
Postal Navideña en VR-Script + GL
http://msxvr.es/doc/wiki/mdwiki.html#!5 ... 13651e9.md
The idea in code could be like that:
E2.pi file,
Code: Select all
class E2 implements VIEW_Program
{
virtual Start()
{
_wnd = CreateWindow();
_menu = _wnd.CreateMenu();
_section = _menu.AddSection("File");
_section.AddItem("Exit", this, "End");
_label = _wnd.CreateLabel(10, 10, 200, 200);
_label.SetText("Hola mundo!!");
}
function End()
{
//End(0);
NewObject("main", "main");
}
}
main.pi file,
Code: Select all
class Main implements GL_Program
{
function Start()
{
//Postal Navideña
...
::Start();
}
}Questions:
1/ How can I do that?
2/ How I can pass the form bean from VIEW_Program to the GL_Program?