Need to create a button to open an URL

Hi, everyone:
I want to create a button that response opening a webpage. How? someone can help me?
Thanx
Khriz

Hey ! Go for this , this is very easy !!
public void actionPerformed(ActionEvent ae)
    // showContent is a button
   if( ae.getSource()==showContent)
      try
        Process process = Runtime.getRuntime().exec("start www.yahoo.com");
      catch(Exception e)
}

Similar Messages

  • Created a button to link to URL, need it to open a new window

    I created a PDF with several buttons. When the reader clicks the button it opens a URL. I need that URL to open in a separate window but I can't figure out how to do it.
    Any help would be greatly appreciated.
    Fernando

    You might get more help in the Acrobat Forum.

  • How to create a button to open directory

    Dear all,
    is it possible to create a button can open directory
    like My Documents
    i test this in CMD command prompte it's work but in
    in forms they are not work
    "explorer.exe" & @MyDocumentsDir
    or
    cmd /c "explorer.exe" & @MyDocumentsDir
    in forms :
    i create a button with trigger When-button-pressed
    in trigger :
    host('"explorer.exe" & @MyDocumentsDir');
    host ('cmd /c "explorer.exe" & @MyDocumentsDir'); ----> i think this should work
    but it's not work
    can you help please
    thanks
    regard

    hi Ammad
    sorry Ammad, but in the first step i get this errors
    Compilation errors on WEBUTIL_DB_LOCAL:
    PL/SQL ERROR 201 at line 9, column 12
    identifier 'WEBUTIL_DB.OPENBLOB' must be declared
    PL/SQL ERROR 0 at line 9, column 5
    Statement ignored
    PL/SQL ERROR 201 at line 18, column 12
    identifier 'WEBUTIL_DB.CLOSEBLOB' must be declared
    PL/SQL ERROR 0 at line 18, column 5
    Statement ignored
    PL/SQL ERROR 201 at line 24, column 5
    identifier 'WEBUTIL_DB.WRITEDATA' must be declared
    PL/SQL ERROR 0 at line 24, column 5
    Statement ignored
    PL/SQL ERROR 201 at line 29, column 12
    identifier 'WEBUTIL_DB.READDATA' must be declared
    PL/SQL ERROR 0 at line 29, column 5
    Statement ignored
    PL/SQL ERROR 201 at line 35, column 12
    identifier 'WEBUTIL_DB.GETLASTERROR' must be declared
    PL/SQL ERROR 0 at line 35, column 5
    Statement ignored
    PL/SQL ERROR 201 at line 40, column 12
    identifier 'WEBUTIL_DB.GETSOURCELENGTH' must be declared
    PL/SQL ERROR 0 at line 40, column 5
    Statement ignored
    PL/SQL ERROR 201 at line 45, column 12
    identifier 'WEBUTIL_DB.GETSOURCECHUNKS' must be declared
    PL/SQL ERROR 0 at line 45, column 5
    Statement ignored
    Failed to generate library.more help plz
    thanks

  • Hwo to create a button that opens a popup

    Hallo,
    I wanna create a button on a page (thats not the problem) that opens a popup where data from a table (two rows) is in.
    I found different documents but nothing that really solves the problem.
    Any idea and helps is really appreciated.
    Thanks and regards, Jade

    Hi Jade
    I'm not sure what documents you've looked and why they haven't helped you. To call any page as a popup, you just need to run some javascript:
    <script type="text/javascript">
    function callMyPopup () {
    var url;
    url = 'f?p=&APP_ID.:123:&APP_SESSION.';
    w = open(url,"winLov","Scrollbars=1,resizable=1,width=800,height=600");
    if (w.opener == null)
      w.opener = self;
    w.focus();
    </script>
    and you button should call the javascript function:onClick="javascript:callMyPopup();"
    I tend to put things like this in A tags on my page.
    Is there something further that you need to do with the popup report?  Do you need to set some value to filter the report and/or return a selected value from the report back to the calling page?
    Andy                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                           

  • I need to create a button that links to another swf file...

    i'm creating my first website, and, for each menu item, i am
    creating a new flash document... is this the correct way to create
    a multi-page website?
    plus: how to create a button that links to a jpg, thanks!
    jane

    Creating separate swf's these days as far as I know is
    considered to be a better practice than using the "scenes" that are
    in Flash. The reason is you can load various sections of your
    entire Flash entity rather than the user downloading everything at
    once.
    But, it also depends on the complexity of where your menu
    items are leading. If they are simple enough, then there may be no
    need to create new documents.
    To create a button that links to a jpeg, try this.
    Whatever graphic you're using for the button, select it and
    hit F8 to convert it to a movie clip. Once it's in your library,
    click on your new movie clip on the stage and give it an instance
    name in the properties window.
    Click the first frame in your timeline (preferably on a layer
    named "actions") and put this example in for the actionscript:
    //buttonName is the instance name you gave it
    //.onPress tells Flash when buttonName is pressed then do
    what's
    //inside the brackets of the function
    buttonName.onPress = function (){
    //getURL is the Flash function that will load your
    picture.jpg
    //_blank is the target. e.g. _blank, _self etc.
    getURL("picture.jpg", "_blank");
    }

  • Need to create a button through personalization

    Hi
    I have an oracle seeded page where in one region i need to add a button thru personalization.I followed this steps:
    1. I went that region and personalized that region.
    2. Clicked on the Crete Item and selected item type as button.
    3. Here what all fields need to filled in order to properly work.
    I have an extended controller for aoracller seeded controller.When i press on this button the logic written in the extended controller should work.Can you please provide any solution for the same?
    Thanks
    Preeti

    Hi Preeti,
    Instead of creating button using personalization, crearte the button programatically in extended controller, and attach an event to this if it is not submit button.
    In PFR you can handle this button easily, using personalization if you will create button then you have to attach an event to this extended controller and then you need to handle the event for this So I think creating button programatically is simple than attaching an event to it.
    Regards,
    Reetesh Sharma

  • Create a Button that Opens a Specific Web Link from a Dropdown Box

    Hi guys.  My main question is, how do I make a Button that opens a specific Web Link, depending on the URL selected in a Dropdown box?
    Example:
    I'm a comlpete newbie and need a code sample of how this would work!  Thanks!
    I have a couple other questions which are related to this. 
    1) Is it possible to hide the URL in the Dropdown list, and only show the Name, so for examlpe, it would only list Hotmail, Gmail, Yahoo, and not the www....com?
    2) Another more advanced question is, once the web link is opened, is it possible to have adobe input or fill-in the Login and Password fields into the website and then hit "Enter" for you.  The Username and Password would be stored somewhere in adobe and would depend on the weblink opened. So for example: When you open Hotmail, it would use the following; Username:[email protected] and Password:password1, but if you opened Gmail, it would use a different Username and Password stored for Gmail.
    3) Finally, out of curiousity, is it possible to have adobe extract data from a website, and fill them into an adobe form?  This maybe over my head, but any starting point or examples would be of great help!

    Use something like this as the button's MouseUp action:
    app.launchURL(this.getField("URL Dropdown").value));
    To answer your other questions:
    1) Yes. Place the URL as the export value of each option, and the name of the site as the display value. The code I provided can remain the same.
    2) No.
    3) Might be possible, but it's very tricky. The way to do it would be to convert the website to a PDF, process that PDF to extract the data from it, and then use that to populate the form fields. That would require quite advanced scripting knowledge, but it could be possible.

  • I need to create a button that add "1" to a number box in "numbers" program

    hi
    I making an inventory list that often being change.
    I want to create a button that "add 1" and a button that "reduce 1" so i can adjust it faster
    how can i do it ?
    thanks

    Hi Yaniv,
    With a single Stepper, I can't see how you can make it refer to different cells in your *locked* inventory.
    Maybe this will work. Old Inventory (2012), then a mirror table with Steppers for every cell, then New Inventory (2013) with formulas to add or subtract Stepper values. Old and New inventories are locked. Stepper Table is not locked. That is where you enter the changes.
    Formula in B2 of the 2013 Inventory is
    =Inventory 30 June 2012 :: B2+Add or subtract :: B2
    Where the Stepper Table is called "Add or Subtract".
    Fill Down and Right.
    Regards,
    Ian
    Message was edited by: Yellowbox. Oops, had to revise Table names.

  • Toolbar Button to Open Custom URL for a Business Partner

    Hi All,
    for a CRM 5.2 implementation, I'm trying to open a URL in a new explorer window when on hte BP Account Overview ( Corporate Account ).
    I've created and added the Button, I've created an event, but when I launch the code behind the event to open a new explorer window, this does not work.
    I've tried several alternatives already ( see below ), but can't seem to find a working one.
    Can someone please helpme out ?
    Component BP_HEAD, view BPHEADOverview.
    CALL METHOD navigation->GOTO_PAGE
      EXPORTING
        URL     = 'http://www.sap.com'
       SESSION =
    or
    call method cl_gui_frontend_services=>execute
      exporting
        application = 'iexplore.exe'
      parameter   = 'http://www.sap.com'
      exceptions
        others = 1.
    or
      CALL FUNCTION 'CALL_BROWSER'
        EXPORTING
          URL                          = w_url
        WINDOW_NAME                  = ' '
          NEW_WINDOW                   = 'X'
        BROWSER_TYPE                 =
        CONTEXTSTRING                =
       EXCEPTIONS
         FRONTEND_NOT_SUPPORTED       = 1
         FRONTEND_ERROR               = 2
         PROG_NOT_FOUND               = 3
         NO_BATCH                     = 4
         UNSPECIFIED_ERROR            = 5
         OTHERS                       = 6.
      IF SY-SUBRC <> 0.
    MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
            WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
      ENDIF.
    Thanks

    Hi,
    First of all I would advice you to post this question in the new CRM 2007 forum.
    We have created our own button that calls an URL in a separate window. Here is some coding from the method CALLBACK~GET_BUTTONS which may inspirere you:
    CONCATENATE 'javascript:window.open'
                  lv_http
                  '","Print","resizable=yes,height=850,width=700,dependent=yes,status=1");'
             INTO lv_java.
      ls_button-type     = cl_thtmlb_util=>gc_icon_print.
      ls_button-tooltip  = cl_wd_utilities=>get_otr_text_by_alias( 'CRM_UIU_BT_SALES_QUOT/SALESQUOT_PRINT' ).
      ls_button-on_client_click = lv_java.
      ls_button-page_id  = me->component_id.
      ls_button-enabled  = abap_true.
      APPEND ls_button TO rt_buttons.
      CLEAR ls_button.
      ls_button-text     = cl_wd_utilities=>get_otr_text_by_alias( 'CRM_UIU_BT_SALES_QUOT/SORDER_CREATEFOLLOW-UP' )."#EC NOTEXT
      ls_button-tooltip  = cl_wd_utilities=>get_otr_text_by_alias( 'CRM_UIU_BT_SALES_QUOT/SORDER_CREATEFOLLOW-UP' )."#EC NOTEXT
      ls_button-on_click = 'FOLLOWUP'.                          "#EC NOTEXT
      ls_button-page_id  = me->component_id.
      ls_button-enabled  = lv_persistent.
      APPEND ls_button TO rt_buttons.
      CLEAR ls_button.
    /Anders

  • How can I create a button to open email client and allow the user to e-mail pdf to a friend?

    I need to find a way to let our members share our marketing pdf files with their friends as an email attachment. I can only seem to find a way to send a mailto to a specific address. I am thinking that the form is the only way to create that possibility, but would be open to any help even if not by a form.

    Thanks you but I want the end user to be able to open my pdf file from my website and email it as an attachment to their family and friends. ( no specific email address assigned) I tried adding a empty mailto tag and it opens the email client, but no attachment. I don't think I am making my question understandable and maybe it is not possible to do this in Acrobat.

  • Create a button that opens a XML data file

    I have a PDF form that was created in LifeCycle Designer. I want to have a button that when you click on it, it will open the "select File window" so that you can then import an XML data file to the PDF form.
    You can do this option manually when you are Adobe Reader in the Form by clicking Advanced, Data, Import Data to Form.
    I want to automate that by just clicking a button. Does anyone know the script to use behind the button to make this work. It's gotta be easy but I can't figure out how to bring up the "Select File Window"
    Can anyone help.
    Thanks
    Sean

    Hi Sean,
    You can import an XML data file by clicking a button, with following code:
    xfa.host.importData();

  • Need to create "GO" button on Template

    Hello Colleagues,
    I have 4 dropdowns on Web template (plant, Material, Material Gr and Date). Whenever selected any entries in any of the 4 dropdowns (say plant-1000 from PLANT dropdown), the whole screen gets refreshed.
    I am looking for something...say, select the desired value from all 4 dropdowns and then click one one extra button "GO" and then refreshed the whole screen.
    Please do provide some suggestions.
    Regards
    Milind

    Hi Milinda,
    you have to define your own form and dropdownboxes for this. To fill your dropdownboxes you can use the web item dropdowns with the parameter ONLY_VALUES = X.
    Then define a button on your web template and generate with javascript the right URL-command.
    the code below is a short example with one dropdownbox and a button. Hope you can adapt this code to your requirements.
    <HEAD>
    <META NAME="GENERATOR" Content="Microsoft DHTML Editing Control">
    <TITLE>BW Web Application</TITLE>
          <link href="/sap/bw/Mime/BEx/StyleSheets/BWReports.css" type="text/css" rel="stylesheet"/>
    <script type="text/javascript">
    function filter () {
    var url = SAP_BW_URL_Get()+'&DATA_PROVIDER=*';
    url = url + '&MULTI=X&FILTER_IOBJNM_1=0CALMONTH&';
    url = url + 'FILTER_VALUE_1='+document.selects.CALMONTH.value + '&FILTER_COLLAPSE=';
    SAPBWOpenURL(url);
    </script>
    </HEAD>
    <BODY>
    <form name="selects" action="" enctype="text/plain">
    <select name="CALMONTH">
    <object>
             <param name="OWNER" value="SAP_BW"/>
             <param name="CMD" value="GET_ITEM"/>
             <param name="NAME" value="DROPDOWNBOX_1"/>
             <param name="ITEM_CLASS" value="CL_RSR_WWW_ITEM_FILTER_DDOWN"/>
             <param name="DATA_PROVIDER" value="DATAPROVIDER_1"/>
             <param name="BORDER_STYLE" value="NO_BORDER"/>
             <param name="GENERATE_CAPTION" value=""/>
             <param name="IOBJNM" value="0CALMONTH"/>
             <param name="ONLY_VALUES" value="X"/>
             <param name="TARGET_DATA_PROVIDER_1" value="DATAPROVIDER_1"/>
             ITEM:            DROPDOWNBOX_1
    </object> </select>
    <input type="button" name="go" value="GO" onClick="filter()">
    </form>
    </P>
    <P><object>
             <param name="OWNER" value="SAP_BW"/>
             <param name="CMD" value="GET_ITEM"/>
             <param name="NAME" value="TABLE_1"/>
             <param name="ITEM_CLASS" value="CL_RSR_WWW_ITEM_GRID"/>
             <param name="DATA_PROVIDER" value="DATAPROVIDER_1"/>
             ITEM:            TABLE_1
    </object></P>
    regards
    Alex

  • How can I create a custom button for opening a form?

    I have a parent form having child forms. In my main form I want to create custom buttons for opening child forms. I want to use master-detail form but there are more than one child forms, and in master-detail form I can only create one detail form. So I will create a form based on a table and in that form I will call the child forms by custom buttons. Can I do that?
    Thanx,
    Gulsah.

    This can be easily done. First open up two instances of your Portal. In one window, you will need to go into your component you wish to link FROM. In the other window you will need to go into your component you wish to link TO. In the component you wish to link TO there will be a moduleid. Note this somewhere. Then, you will see an area that says: "Call Interface: Show". Click on this. (In the window you are linking to.). In this window, you will see a bunch of stuff. At the bottom you will see a URL call. This is the call you need to use. At the top, it explains each piece of the URL call. Just subsitute YOUR appropriate information into the URL call. In the form you wish to link FROM, create a button. Once you create this button, it will appear at the bottom, click on it and you will see an area to insert a Javascript. Click the onClick and insert:
    //this is the variable you want to pass from one form to the other
    get_field_name = getField(this.form,'COLUMN_NAME_IN_DATABASE');
    //this is so you can open the "child" form
    window.open('/pls/cc_prod/DAD_NAME.wwa_app_module.link?p_arg_names=_moduleid&p_arg_values=MOD_ID_HERE&p_arg_names=_sessionid&p_arg_values=&p_arg_names=COLUMN_NAME_IN_DATABASE&p_arg values='+GETFIELD_NAME+'&p_arg_names=_COLUMN_NAME_IN_DATABASE_cond&p_arg_values=%3D');
    In the fourth tab, where it says, "....before displaying form" insert the following: (This will tell the form how to handle the getField function.)
    htp.p('<script language="JavaScript1.3">
    < !--
    function getField(form,fieldName)
    var objName = "";
    var tmp = "";
    var dAction = "";
    var sel_idx = 0;
    var cnt = 0;
    var instance = 0;
    var slicedName;
    var fillData = new Array();
    for (var i = 0; i < form.length; i++)
    slicedName = form.elements.name.split(".");
    tmp = slicedName[2];
    instance = parseInt(slicedName[3],10);
    if (!tmp)
    continue;
    objName = tmp;
    if (objName == fieldName)
    return form.elements[i].value;
    //-->
    </script>');
    I hope this helps.
    null

  • I need instructions on how to create a button that will email a pdf form to someone else on a websit

    I NEED ASSISTANCE CREATING A BUTTON THAT WILL EMAIL A PDF FORM FROM A WEBSITE TO WHOEVER THE VIEWER WANTS TO

    Just a bit more info. E-mail can be used, but has potential problems -- often related to the client machine that you have no control over. Use the data submissions (either FDF or XML) rather than the full PDF so you do not have to deal with Reader Rights and the related license issues. The FDF and XML data files are easily imported into the original form so that you see what the client sees. With those aspects in mind, just go ahead and try one. Be aware that you can add form fields using the form tools in the Advanced Editing tools, OR use the forms menu that will take you to Designer. You might want to try both to see the pros and cons. Be sure to keep such a test simple so you are not wasting time on your final form just for testing. I typically create a 1 page form that has all of the possible fields for such a test.

  • Need to create a function that will act like the save as browser function

    I need to create a button on a web page that will open up a save dialog box and then save the current web page as an .html file on the persons hard drive. The reason for this is because the window is a pop up that does not have the browser menu or any toolbars showing just the what we call print view. This window was used only as a print view so people can print the form out but now the powers that be want a save button as well so the people can save it to there HD. I can do this in IE using javascript but no other browser allows that so I need to create something in java. I have read about the setHeader() to download the file but I am sort of new and from what I've read it all sounds like you will be downloading a specific file and not the web page as a file. Anyone have any ideas as to how I can accomplish this? It doesn't have to be the save as dialog box just a way the person can get the current web page on their HD for viewing offline and done at the press of a button. Thanks.

    You'll be wanting to output a PDF or the like instead of a web page. That's the solution to your problem.
    Please next time consider using a line break or two when you post. Thank you for your consideration.

Maybe you are looking for

  • Open PO details in the back date

    Hi, We had shorclosed/deleted/changed the quantities of some line items of open POs (Material PO & Service PO) and migrated those line items into new POs in new plants some time back. Now we need to take a report of the old PO line items at that time

  • Sound but no picture on Apple TV airplay from macbook

    Hi, To give a little more depth to this. I was working on a presentation on my Samsung TV on airplay connected through Apple TV, I left the room and then the external display had gone blank. I am able to connect with airplay and sounds can be played

  • I can not connect my apple wireless keyboard to my iPad Mini?

    I can not connect my apple wireless keyboard to my iPad Mini?

  • Air supply?

    Hey, I have a question. Im getting a cinema display for my iMac and MacBook Pro Im not sure what one Im going to use it for. I just wanted to know if this had any air intake and/or outake?

  • Multiple Details section in BO

    Post Author: fenn CA Forum: Desktop Intelligence Reporting Hi,     I have to create a report from  one master table and two details tables. (ie), the data from the master table should be displayed first line followed by the records from 1st detail ta