Forums

Find answers, ask questions, and connect with our
community all around the world.

Home Forum Omnis General Forum Passing a parameter to a subwindow

  • Passing a parameter to a subwindow

    Posted by Obonye on September 13, 2024 at 5:52 pm

    Hello,

    I have this command in a remote form to pass a parameter to a subwindow:<br clear=”none”><br clear=”none”>Do $cinst.$objs.subwindow.$parameters.$assign(‘Add Record’)<br clear=”none”><br clear=”none”>If I test this, I get an error: Control subwindow: parameters cannot be assigned at runtime.<br clear=”none”>Any help please why this won’t work in runtime and how parameter assignment to a subwindow works.

    Martin.

    Minh Phuong Vu replied 8 months, 3 weeks ago 3 Members · 2 Replies
  • 2 Replies
  • Diego Mendoza Muñoz

    Member
    October 8, 2024 at 3:49 am

    you have to passing parameter before assign classname

  • Minh Phuong Vu

    Member
    November 7, 2024 at 9:03 am

    You can use $userinfo to pass parameters to a sub window:

    Do $cinst.$objs.[subwindowName].$userinfo.$assign(con(“‘”,pParameter1,”‘,'”,pParameter2,”‘”))

    Then in the subwindow, those variables can be retrieved in the $init method as parameters.

Log in to reply.