Forums

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

Home Forum Omnis General Forum Opening new links in a web application.

  • Opening new links in a web application.

    Posted by Allan Sullivan on June 4, 2024 at 2:49 pm

    I have a technical question….

    I have an application written for the web. I want to set up functionality to open up a new web page (in a separate tab or window) within the code, but I have not yet figured out how to do that.

    The closest I have found is to create a label, set the ‘textishtml’ property, include the html anchor/href references, and have the user click on it, but I would prefer if the code would just ‘jump/open up’ to the web page without any sort of user interaction.

    Thank you in advance.

    Allan Sullivan replied 11 months, 3 weeks ago 2 Members · 2 Replies
  • 2 Replies
  • Andreas Pfeiffer

    Administrator
    June 4, 2024 at 3:00 pm

    Hi Allan,

    I suppose you are talking about an Omnis JS application?

    You have several options:

    1. Do $cinst.$showurl(‘http://someURL’) .. will open a new browser instance (or tab) and point to the given URL. This only makes sense if you want to refer to a URL outside of the current Omnis app.

    2. Do $cinst.$clientcommand(“subformdialogshow”,row(jsNextForm,300,600)). .. this will open a dialog window inside the current Omnis remote task instance and you can communicate between the main form and the subform by using $cinst.$container, i.e.

    Do $cinst.$container().$getID() .. will call the $getID from the main form

    3. You can use a main form that has a subform field. This can than be used to switch between several other remote forms assigning the $classname of the subform field.

    I hope this helps.

    Best,

    Andreas

  • Allan Sullivan

    Member
    August 15, 2024 at 9:48 am

    Sorry for the late response. But I would like to thank you for your answer.

    It managed to solve the problem we had.

Log in to reply.