What is the preferred way to open a new url in a new window/popup?

Hi Guys,
I have an application that requires me to show another URL (Fedex tracking number) once a button is clicked.
what is the preferred way to do it?
Should I open a new browser or a popup?
I would appreciate if you have a code example I can use.
Thanks,
Itay

hi,
For opening a URL , you could also close previous window and open a new browser.
Follow the steps :
-> make an outbound plug in your window.
-> Add URL of type string as a parameter for your outbound plug.
->Do remember to add Component Name in the Properties Tab of View ( othervs Calling Outbound plug of win from view wont b psbl).
Write the below mentioned code to call a URL  in the OnAction of button :
DATA lo_zexit TYPE REF TO ig_zexit .
lo_zexit =   wd_this->get_zexit_ctr( ).
  lo_zexit->fire_out_window_plg(
    url =   'http://www.google.com'                            " string
here replace ig_zexit with your  ig<applicatin name>.
Other way around is using Code Wizard ( control _ F7).
Write the below code in the onaction of button :
data lo_window_manager type ref to if_wd_window_manager.
data lo_api_component  type ref to if_wd_component.
data lo_window         type ref to if_wd_window.lo_api_component  = wd_comp_controller->wd_get_api( ).
lo_window_manager = lo_api_component->get_window_manager( ).CALL METHOD lo_window_manager->CREATE_EXTERNAL_WINDOW
  EXPORTING
    URL            = 'http://www.google.co.in/'
    MODAL          = ABAP_FALSE
    HAS_MENUBAR    = ABAP_TRUE
    IS_RESIZABLE   = ABAP_TRUE
    HAS_SCROLLBARS = ABAP_TRUE
    HAS_STATUSBAR  = ABAP_TRUE
    HAS_TOOLBAR    = ABAP_TRUE
    HAS_LOCATION   = ABAP_TRUE
  RECEIVING
    WINDOW         = lo_window.lo_window->open( ).
You can choose any way whichever suits your requirements.
I hope it helps.
Thanx.

Similar Messages

  • What's the preferred way to load database properties (url...) in a web app?

    In a simple stand alone app, I would normally use a properties file for the database url, username, and password instead of hardcoding the values. But I am not so sure about web apps. I don't even know where I put a properites file for a servlet to see. Is there a section in the deployment descriptor (web.xml) for me to define such properties?
    Any help would be greatly appreciated.
    By the way, I am using the Tomcat version that came with the jwsdp-1.3.

    Don't now if it's the recommended way, but we're doing this with the context-param elements of the web.xml file.
    Example :
    <web-app>
    <display-name>MyWebApp</display-name>
    <description>
    A sample Web Application
    </description>
    <context-param>
    <param-name>driver</param-name>
    <param-value>org.postgresql.Driver</param-value>
    </context-param>
    <context-param>
    <param-name>url</param-name>
    <param-value>jdbc:postgresql://mydbhost/mydbname</param-value>
    </context-param>
    <context-param>
    <param-name>user</param-name>
    <param-value>dummy</param-value>
    </context-param>
    <context-param>
    <param-name>password</param-name>
    <param-value>garbled</param-value>
    </context-param>
    <session-config>
    <session-timeout>60</session-timeout>
    </session-config>
    </web-app>
    In our Web application, we read those values in the following way :
    public class MySVCImpl implements ServiceLifecycle, MySVCIF {
    public void init(Object context) {
    ServletEndpointContext seContext = (ServletEndpointContext) context;
    ServletContext sContext = seContext.getServletContext();
    String driver=sContext.getInitParameter("driver");
    String url=sContext.getInitParameter("url");
    String user=sContext.getInitParameter("user"),
    String password=sContext.getInitParameter("password"),
    Hope this helps.
    Mark

  • What is the best way to open emails and attachments without using wifi?

    For I-phone and I-pad, what is the best way to open emails and attachments without using wifi?  I turned off wifi in my settings but my boss thinks there may be another way and a better way to use something else instead of wifi.  Any help would be appreciated!  Thank you!

    Thanks!  That is a very good question you post.  My boss asked me that and I am assuming that he is having issues with using wifi wherever he is at.  My boss is the kind of person that when he asks something you look into it and ask him no questions...he's the only one asking questions!  But thank you for your response I will tell him the information you told me and hopefully that will help!

  • What is the best way to open close and pass instrument handles from labview in teststand parallel model?

    I have a number of test systems that use a parallel model with labview. We have a good number of instruments(PXI).
    What is the prefered method for open,closing and passing instrument handles in teststand using labview? 
    Solved!
    Go to Solution.

    Hi,
    No, Below is a bit from the Session Manager Help
    Currently, Session Manager supports the following instrument session types:
    IVI Sessions—Use an IVI session to obtain the C-based instance handle for an IVI logical or virtual instrument name. NI Session Manager does not support IVI-COM drivers at this time. When IVI-COM drivers are available, you can use an IVI session to obtain an ActiveX interface reference to an IVI-COM driver.
    VXIplug&play Sessions—Use a VXIplug&play session to obtain a C-based instance handle for a VXIplug&play logical or virtual instrument name. Configure VXIplug&play names in the <VXIplug&play directory>\<Platform directory>\NISessionMgr.ini file.
    VISA Sessions—Use a VISA instrument session to obtain a C-based viSession handle to a VISA resource or logical name. Configure VISA logical names in the <VXIplug&play directory>\<Platform directory>\NISessionMgr.ini file.
    Custom Sessions—Use a custom session to create a data container object that shares ActiveX objects you create or other data between software components you write. Use the Attach and Get methods to attach data to and retrieve data from a session. A custom session does not initialize, close, or own an instrument handle. The data you share with a custom session does not have to be instrumentation related. You can create a custom session with any name you request.
    Regards
    Ray Farmer
    Regards
    Ray Farmer

  • What is the best way to open a HTTPS connection?

    What is the best way to open a HTTPS connection and retrieve the content as XML? This is how most of the online API is done nowadays, how can this be done on the iphone SDK?
    Thanks

    Have a look at the SeismicXML example that comes with the iPhone SDK. It uses http instead of https but it may work for you.
    You can also look at the NSURLRequest and NSURLConnection classes.
    Enjoy.

  • What's the quickest way to open Access Connections?

    What's the quickest way to open Access Connections, apart from its Taskbar level meter?
    I prefer to use the Power Manager battery meter instead, as it looks pretty ugly when both are used, and they take up too much space.
    Fn+F5 no longer gives any access to Access Connections either.  And it is not integrated into the standard Windows network system tray icon's right-click menu, like Power Manager is with the standard power system tray icon.
    You cannot even type Access Connections in the Start Menu search box, as the shortcut is called something else, which I can never remember.
    Ideally, I would at least like to be able to access it though the Fn+F5 box again (I'm pretty sure it was possible in versions).
    jason404 - X220 (my sixth ThinkPad)

    If you are still interested in using a translator, I recommend the [https://addons.mozilla.org/en-US/firefox/addon/gtranslator/?src=userprofile gTranslator] add-on.<br>
    This add-on is similar to the Google Chrome translation bar.

  • This community is great -- very helpful. What is the best way to read "word" docs on my brand new iPad 2? Is there an app for that?

    This community is great -- very helpful. What is the best way to read "word" docs on my brand new iPad 2? Is there an app for that?

    If you're just reading them from email attachments, you can just open it to "view" the document.
    However, if you wish to do editing and work, you'll need an application. I use Documents to Go, but there are other versions that people are happy with - do a search in the App store for "office suite" or "word processing".
    The next challenge is getting docs back and forth. Doc2Go and others have their own ways to physically sync docs when connected to a computer; you can also email changed/revised/new documents from the iPad to yourself. However, I use a "cloud service" called DropBox that stores docs in the cloud (so I can get to them anywhere) - I paid for the Premium version of Docs2Go to allow that kind of syncing.

  • What is the best way to transfer my iTunes library to my new mac book pro?

    WHAT IS THE BEST WAY TO TRANSFER MY ITUNES LIBRARY TO MY NEW MAC BOOK PRO?  I AM A NOVICE COMPUTER WIZARD!

    From your Old Computer... Copy your ENTIRE iTunes FOLDER to an External Drive... and then from the External Drive to your New Computer..
    Backup iTunes to an External Drive
    http://support.apple.com/kb/HT1751
    Moving iTunes Media Folder (Mac)
    http://support.apple.com/kb/HT1449
    If your Old Computer is a PC... See Here...
    Move iTunes Library from PC to MAC
    http://www.macworld.com/article/146958/2010/03/move_itunes_windows_mac.html

  • What is the best way to migrate my MacBook Pro to my new Imac desk top, both seem to be running OS X version 10.9.5

    What is the best way to migrate my MacBook Pro to my new Imac desk top, both seem to be running OS X version 10.9.5

    OS X: How to migrate data from another Mac using Mavericks

  • What is the quickest way of moving a itunes music library from a windows 7 machine to an apple Macbook pro?

    What is the quickest way of moving an itunes music library from a windows 7 machine to an apple Macbook pro?

    If you wany Everything from your PC itunes on your MBP... Then... See Here...
    Move iTunes Library from PC to MAC
    http://www.macworld.com/article/146958/2010/03/move_itunes_windows_mac.html

  • What is the best way to import photos from aperture to my new Lightroom

    What is the best way to import photos from aperture to my new Lightroom ?

    See if this helps
    http://lightroomsolutions.com/articles/migrating-from-aperture-to-lightroom-where-do-i-beg in/

  • What is the best way to transfer iTunes from iBook G4 to new MacBook Pro?

    What is the best way to transfer iTunes from iBook G4 to new MacBook Pro?

    Copy the entire itunes folder.

  • What is the better way to open and close connection in bean

    Hello, may i ask about the best way to open and close the connection?
    At the first, the connection code is store in Conn class bean. The JSP page will call a method in Process bean to process the query and update of database. the Process bean is using th Conn to connect to database.
    In my process bean, it have a method for each type of sql like select, insert, update, and delete for each tables. Each method will call the Conn to open and close the connection. The jsp page can simply call a method retrieve or update records.
    However, when calling the processUpdate method, it is a method that update a group of tables base on the query result of another group of tables and calculation. If I calling the query method in the same bean file, it will open and close the connection many times (more than 1000 times). After open and close the connection several times, the connection to mySQL will be fail.
    Currently, i include 2 method in Process that is only calling the Conn to open the connection and close connection. When calling the openConnection method, it will also set the boolean connected in the class to true and call Conn to open connection. When calling the closeConnection method, it will also set the boolean connected in the class to false and call Conn to close connection.
    After that, i add some change to the query method which is when the connected is false, it will open the connection by calling the Conn and close the connection themself. If the connected is true, it will not call the Conn to open and close the connection because it already connected to the database.
    Now, i when i calling the query method in jsp, it can open the connection and close the connection individually. When i call the processUpdate in the jsp, this method will calling the openConnection before calling the query and calling closeConnection at the end. It not only faster the process(less open and close), it also no cause the connect to mySQL fail error again. However, it also make the coding in the bean file more longer and complex.
    Is there have any better solution?

    Use connection pooling. This will put the connection management in the hands of the webserver, not your code. Check out this post:
    http://forum.java.sun.com/thread.jspa?threadID=741788&messageID=4252932#4252932

  • HT201364 what is the best way to open up disk space on my macbook pro

    WHAT IS THE BEST WAY TO FREE DISK SPACE ON MY MACBOOK PRO,  I NEED SPACE TO DOWNLOAD YOSEMITE

    OmniDiskSweeper (free download)
    <http://www.omnigroup.com/more>
    <http://www.macupdate.com/info.php/id/7402/omnidisksweeper>
    DO NOT delete files in your Home Folder -> Library tree as there are things like your iPhone backups, your email messages, your application preferences, etc...
    DO NOT delete files outside your home folder, as you may end up deleting something essential to Mac OS X, and turn your Mac into an expensive “Door Stop”.
    I will point out that you will find some very large files in private -> var -> vm (these are the Mac OS X virtual memory paging files (swapfiles) and where Mac OS X stores the copy of RAM when your Mac is put to sleep).  The swapfiles get deleted on reboot, and the sleep image is just going to be created again when you put your Mac to sleep.
    If you think you have found something to delete outside your home folder, it would be best to ask first before deleting.  There are many examples of people deleting files outside their home folder, or renaming files, or changing the ownership or permissions of files, and then their Mac stops running.  Do not be one of those people.  Ask first.
    PS.  Please do not use ALL CAPS for your entire messages.  In the world of text messages, forums, etc... ALL CAPS is shouting, and we haven't done anything that annoying yet

  • What is the Proper Way to "Sync My Music & Apps to a New Computer Using ITunes"

    What is the Proper Way for Me to "Sync My Music, Pictures & Apps to a New Computer Using ITunes"?
    I had to buy a New Computer since my other one went out, but when I log into ITunes with the New Computer using My Apple ID "Nothing is there"...
    None of My Previously Purchased Music or Apps are in My ITunes Media Library; so, I any not sure how to Properly Proceed with Syncing?
    Any Help & Guidance would be Greatly Appreciated!!!
    Thanks,
    Don

    Sounds like something might be wrong there. Years ago I set up the playlists to sync to my iPhone and 'Everything' for my iPod and I've never needed to change or even check it since, ever.
    However, how and why are you 'restoring' the iPod? This is not something you should ever need to do. If you restore back to original settings, then I guess that would throw away your own settings, but as I said, there should be no need to keep doing that. Or at all in fact.

Maybe you are looking for