Script to customize button event - "Save"

I am trying to create a "Save" button but am very new at creating JavaScript. What I want to do is add a button on a form that allows form fillers to save the form without having to go to the File Menu-Save or-Save As.
I have selected Click in the Show list, chosen JavaScript for the Language box and Client for the Run At box. But I don't know the script to have the button open up the Save dialogue box.
Application: LiveCycle Designer ES v 8.2 with latest upgrades
OS: MS Windows XP v 2002 Service Pack 3
2G RAM
Printer: HP Photosmart 8250

Hi Jono,
Do you have any script for saving a PDF file that is inside a portfolio, out of the portfolio?
app.execMenuItem("SaveAs"); saves the portfolio itself. I am looking for a script to open the individual PDF in a new (separate) window and then save that file locally.
Thanks,
Niall

Similar Messages

  • SAVE AS BUTTON WITH JAVA SCRIPT FOR MOUSE UP EVENT

    Please any one help with complete code for "SAVE AS" button to auto save the acrobat form in a user specified path
    with unique name or incremental name.Please post only full script for MOUSE UP event.

    Thanks George but i need an example.my actual need is
    i have created a SAVE INVOICE button.i have set the action"Mouse up" to run a Java script.
    Now i need a scriprt for the same.
    If i press that SAVE INVOICE button.the fie should save on "C:\Users\MUNNA\Desktop" automatically
    with unique name and the name should not remain same for next Save.because it overwrites the previous
    file so please post an example pdf with same.

  • How to get a form field valud in delete PL/SQL Button Event Handler

    Hi Friend,
    I have a form. when user clicks delete button. we want to remove system dodelete function
    and add a delete script
    Under delete-top category,
    how can I get value of form EVENT_NUMBER field in form at delete PL/SQL Button Event Handler?
    DELETE FROM PTEAPP.PTE_EVENTS WHERE eventnumber = EVENT_number
    But when I try to save this form and get message as
    1721/15 PLS-00201: identifier 'EVENT_NUMBER' must be declared
    Thanks for any help!
    newuser

    I did something similar but wasn't using a stored procedure. Couldn't you set a flag variable once you know you're not doing the insert and in the "before displaying the form" section put an IF to check if your flag was set, and if so do an HTP.Print('You are overpaid buddy!');
    Then just reset your flag.

  • How to Capture Button event on TrainBean navigation

    Hi All
    i m being required to capture a button event in train bean Navigation, i m doing customization in Iexpense Module,here in Create IExpenseReport i need to capture the events of Remove,Return etc.how is it possible any clue would be very helpful.
    Thanx
    Pratap

    try this..
    if (GOTO_PARAM.equals(pageContext.getParameter(EVENT_PARAM))
    "NavBar".equals(pageContext.getParameter(SOURCE_PARAM))
    // This condition checks whether the event is raised from Navigation bar
    // and Next or Back button in navigation bar is invoked.
    int target = Integer.parseInt(pageContext.getParameter(VALUE_PARAM));
    // We use the parameter "value" to tell use the number of
    // the page the user wants to visit.
    String targetPage;
    switch(target)
    case 1: targetPage = "/oracle/apps/dem/employee/webui/EmpDescPG"; break;
    case 2: targetPage = "/oracle/apps/dem/employee/webui/EmpAssignPG"; break;
    case 3: targetPage = "/oracle/apps/dem/employee/webui/EmpReviewPG"; break;
    default: throw new OAException("ICX", "FWK_TBX_T_EMP_FLOW_ERROR");
    HashMap pageParams = new HashMap(2);
    pageParams.put("empStep", new Integer(target));
    pageContext.setForwardURL("OA.jsp?page=" + targetPage,
    null,
    OAWebBeanConstants.KEEP_MENU_CONTEXT,
    null,
    pageParams,
    true, // Retain AM
    OAWebBeanConstants.ADD_BREAD_CRUMB_NO, // Do not display breadcrumbs
    OAWebBeanConstants.IGNORE_MESSAGES);
    --Prasanna                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                       

  • How can I add a Save form button ( not save as ) for a custom fillable form ?

    How can I add a Save button ( not save as ) for a custom fillable form ?
    idea is ti to have a Save button  at the bottom of each page where the person filling
    the form  clicks the save button  on each page.( it is a 12 page fillable form )
    The only thing I was able to do  was add a button that  opens a Save As
    dialog box only.
    My experience  lever is - end user-intermediate.
    Thnaks.

    Thanks for the response.
    I wonder why  it wont allow.
    If I can  save ( as opposed to save as)   this form by clicking the  save icon on the  menu bar, I am not sure why it is no possible to do so on page level!
    Custom script option is not  even remotely possible!

  • Buttons to save as .pdf and as .xlsx

    Hello everyone,
    I have used the following code to save as pdf but what I would like to do something similar not exactly that (found the code in here Macro
    to create Excel data to PDF file. )
    Sub SavePDF()
        ActiveSheet.ExportAsFixedFormat Type:=xlTypePDF, _
            Filename:="C:\PDFs\No." & _
            ActiveSheet.Range("AY8").Value & ".pdf", _
    Worksheets("Sheet1").Range("A1:I50").ExportAsFixedFormat _
            OpenAfterPublish:=False
    End Sub
    - What I want is saving the file automatically by getting the name from three cells. For example K10, A10, K12 and if the name already exists in that folder than automatically put an underscore on the end or something similar.
    - Furthermore I would like to save data only from Sheet 1 (My Sheet name is: Testing) and page 1 and not the whole sheet. Is that possible?
    - Moreover, make the file as read only
    - To end, as title says, I would like to add another button to save the sheet that I am working at as it is and not the whole workbook using the same customization as for the pdf. 
    Thank you in advance.

    Hi Ioannis,
    Base on your code, it is used to export the current sheet to pdf.
    To save specify sheet to a different file, we could use
    Worksheet.SaveAs method.
    To check whether file is exist, we could use Dir method.
    If Dir([file path]) <> "" Then
    MsgBox "File exists."
    Else
    MsgBox "File doesn't exist."
    End If
    To make the file as read only, we could use
    worksheet.Protect to lock the worksheet. If someone want to change the data, he needs the password. The
    Workbook.Protect method can protect whole workbook.
    Regards
    Starain
    We are trying to better understand customer views on social support experience, so your participation in this interview project would be greatly appreciated if you have time. Thanks for helping make community forums a great place.
    Click
    HERE to participate the survey.

  • Htp.p doesn't work from the custom button event handler ...

    Hi,
    I am trying to pop up an alert from the custom button event handler. I created a button and put the following code.
    htp.p('<script language='JavaScript1.3">
    alert ("Test Message");
    </script>;
    But alter doesn't show up after clicking the button.
    Thanks

    OK i've attached them and copy/pasted the relevent parts. The parent window is the SFLB file.
    -----------------------------------------here's the code in the parent window
    private function editServerPool():
    void
    serverPoolPUW = PopUpManager.createPopUp(
    this,popups.ServerPoolPopup,true);PopUpManager.centerPopUp(serverPoolPUW
    as IFlexDisplayObject); 
    if (newServerPool.SecondarySPAlgorithm != null){
    serverPoolPUW.enableSSCheckBox.selected =true;serverPoolPUW.DisplaySecondaryServerPool();
    serverPoolPUW.bigResize.play();// serverPoolPUW.height = 602; //yes...i know i need to move thisserverPoolPUW.switchoverPolicyCB.selectedItem = newServerPool.SwitchOverPolicy;
    serverPoolPUW.switchoverThresholdTI.text = newServerPool.SwitchOverThreshold;
    ----------------------here's the code in teh popup window (popups.ServerPoolPopup.mxml)
    <mx:Resize id = "bigResize" heightFrom="506" heightTo="602" target="{this}" /> 
    <mx:Resize id = "littleResize" heightFrom="602" heightTo="506" target="{this}"/>
     public function DisplaySecondaryServerPool():void{
    //make the screen large if the secondary server checkbox is selected; otherwise small.  
    if (enableSSCheckBox.selected){
    //display secondary server pool tab, expand the screen 
    //note that we cannot attach a data provider to the data grid until the grid creation is  
    //completed. This is done in an event handler.secondaryPanel.enabled =
    true; switchoverPolicyCB.visible =
    true;switchoverThresholdTI.visible =
    true;thresholdFI.visible =
    true;policyFI.visible =
    true;bigResize.play();
    else
     <mx:CheckBox label="Enable a Secondary Server Pool" width="264" fontWeight="bold" click="DisplaySecondaryServerPool()" id="
    enableSSCheckBox" fontSize="12" x="83" y="40"/>

  • Calling java script from a button

    Hi,
    I have a Form and I would like to let the end-user to confirm some action that was initiated by pressing a button. The best way would be to call Java script, but the button is an 'item' button and not a 'region' button - i..e it is placed between items and not above the region, like Save, Cancel etc.
    In case of 'item' buttons I do not have 'Optional URL Redirect' field where to place the javascript call.
    Tamas

    You can try this..
    Instead of using button
    Edit the Item to which you want to associate a button.
    Go to Element tab
    Under Post Element Text enter
    </ br> <a href="#" -onclick=call_me() class="t20Button">Click me</a>Note : you need to change class="t20Button", i'm using theme 20 and in that the look and feel of button is derive from t20Button.
    remove the hyphen before onclick ..
    Regards,
    Shijesh

  • Execute procedure in pl/sql button event handler

    i have a demo application which consists of text boxes
    eg : when i enter department no in first text box and click proc
    it should display dname and loc in the below text boxes.
    my proc is working fine in sql*plus but its showing errors in pl/sql button event handler.
    any ideas
    my proc is create or replace procedure proc1 (no number)
    as
    DNAME1 dept.dname%type;
    LOC1 dept.loc%type;
    begin
    select DNAME,LOC into DNAME1,LOC1 from scott.dept where deptno = no;
    DBMS_OUTPUT.PUT_LINE (DNAME1);
    DBMS_OUTPUT.PUT_LINE (LOC1);
         Exception When No_Data_Found then
    dbms_output.put_line('Entred name is not found');
    When Others then
    Null;
    End;
    /

    Hi,
    you have to use
    htp.p('<SCRIPT LANGUAGE="Javascript1.1">
    document.all("FORMNAME.DEFAULT.ATTRIBUTENAME.01").value="'||DNAME1||'";
    document.all("FORMNAME.DEFAULT.ATTRIBUTENAME.01").value="'||LOC1||'";
    </SCRIPT>
    instead of
    DBMS_OUTPUT.PUT_LINE (DNAME1);
    DBMS_OUTPUT.PUT_LINE (LOC1);
    where formname is your form name and attribute name is the field name on the page.

  • Adding Script to a Button?

    Is there a way to add JavaScript to a button when creating an Interactive PDF in InDesign (CS6)? This Interactive PDF is being turned over to other developers, who need to tack on a Certificate/Completion process, which is called to from a script that I need to place in the document somewhere.
    Other issues: I know this is probably doable by opening the interactive PDF in Acrobat and adding the script from there - but I have to save the Interactive PDF as a SWF (the developers' process eliminates interactivity from a PDF.)
    Any ideas? Help?

    Perhaps the definition of windows is the issue. Flash swf
    movies are self
    contained in a web browser window web page. So opening an
    external image in
    a MovieClip is simply redrawing the Flash swf.
    If you are thinking of windows within the Flash movie, they
    will have to be
    within the confines of the Flash movie that is first
    launched. You can have
    MovieClips with externally loaded content appear as windows
    and even be
    draggable, but they will not be a separate web browser
    window.
    If you need the web browser to open another window and then
    load another
    Flash movie in it that does the loading, then you need to use
    getURL("
    http://www.domain.com/pagewithotherflashmoviecontainingloadjpg.html/",
    "_blank");
    However it seems it would be less files to simply use html in
    the other
    window page to show the jpg without the Flash movie doing the
    loading unless
    you are using Flash to animate the jpg in some fashion like a
    fade in or
    out.
    Lon Hosford
    www.lonhosford.com
    Flash, Actionscript and Flash Media Server examples:
    http://flashexamples.hosfordusa.com
    May many happy bits flow your way!
    "Chicca81" <[email protected]> wrote in
    message
    news:e92am7$58n$[email protected]..
    >I need some help to understand and find a way to script
    the loading of
    >pictures
    > on different window. I already tryed to use behaviours:
    adding the
    > following
    > script to a button:
    >
    > on (release) {
    >
    > //load Graphic Behavior
    > _root.Contenitore.loadMovie("Cornice 10.jpg");
    > //End Behavior
    >
    > }
    >
    > When I do test the movie though I realised that it
    doesn't work as I
    > expected.
    > The picture "Cornice 10" loads on a what I think to be a
    new window: the
    > Movie
    > Clip "Contenitore" but it doesn't appear to a different
    window. How should
    > I
    > procede then?
    >

  • No save/close button to save Javascript in built-in editor

    I downloaded trial version and am playing with features.  I am editing a form.  I added a button.  In Actions tab, I chose "Run Javascript."  There is an "Add" button which invokes the built-in Javascript editor.  It has a multi-line textbox to enter the script.  However, there is no button to save the code.  All I have is the red "X" button to close the window without saving.
    This is XI trial version on Windows 8.1 machine. 
    Any help will be appreciated.  Thanks.

    George is right, your window is too small. It look like you have room to
    make it bigger. The standard behavior of the window is that you cannot make
    it smaller than a specified size, and that the buttons automatically get
    positioned based on the window size. Somehow your editor window gets
    displayed too small. In the lower right corner, you see the resize drag
    handle. Click on that corner and drag the window larger. I suspect that
    once it's big enough the missing buttons will get shown as well.

  • Creating button event

    Hi there,
    1) I have button and I want to create WhenClikMouse event occurs when click on it from the forms. I'm trying to create button event in PJC, ANYBODY can help?!,,
    2) and where should I save the JavaBean class to call it successfuly from the forms (I'm working on oracle 9i and Jdeveloper 9.2).

    Hi there,
    1) I have button and I want to create WhenClikMouse
    event occurs when click on it from the forms. I'm
    trying to create button event in PJC, ANYBODY can
    help?!,,
    2) and where should I save the JavaBean class to call
    it successfuly from the forms (I'm working on oracle
    9i and Jdeveloper 9.2).Hi - I'd post this to the "Forms" forum on OTN since this is a question about Pluggable Java Components which are a specific (and mighty cool) feature of forms.
    There's also some viewlets and documentation from the Forms section on OTN (http://otn.oracle.com/products/forms) and the how-to debug PJC technical note (http://otn.oracle.com/products/forms/htdocs/howto_debug_pjc.html).
    -steve-

  • Scripting the STOP button

    I swear I've searched for this topic and found nothing.
    It's pretty basic-- when I author a disc and test it, I press the Stop button on the Remote.
    It sits there with a black screen.
    I have gone through the excellent DVD Studio Pro 4 Peachpit Apple Pro Training book and the closest example I could find dealt with scripting for two menus.
    For this project I have only one menu. I have tried to generalize the example to set a GPRM for 1 value (1, in fact) and a second pre-script to Compare if menuID=1. I've attached this to Disc end jump. That doesn;t feel right but there's no place to attach it to, oh, something logical like THE STOP BUTTON.
    It ain't working! Stop leaves me with black screen.
    Pretty basic. Is scripting overkill for a simple escape command while in Play?
    Help appreciated.

    [Your a little confused on the purpose of scripts. You can't attach a script to the Stop button.]
    I'm not confused, my POST is confused!
    I'm aware remote control buttons can't be scripted, but actions and events can. Somewhere.
    Clueless users often expect something helpful when the stop button is pressed, rather than being taken to their player system screen and completely out of the disc. I was certain there was a way to head off this action. Okay, I may be wrong and I'm taking on far too much work looking for a solution. Stop does mean stop, after all. But some folks don't realize there are one or more menu buttons to keep them in the disc. They press stop and then they have to press Play, and navigate to their favorite submenu, etc.
    Russ (hi!) --
    Yeah, I always plug in Return. Those Playback Controls in Advanced however look like they disable controls. I've stayed away from them.
    Thanks, guys.

  • ScriptUI run script from dialog button

    Here is what I have right now.  It is a little clunky in the way it works, and I would just like to make it a bit slicker.
    I have a script on startup that creates a Menu item with a dropdown submenu item. when you click on the submenu item, it starts a script. 
    The first thing the script does is pop up a message box that tells them that two dialog boxes are going to popup. The first one asking them to choose the location of an xml file and the second dialog box that ask them to choose the location of their image folder.  After they finish choosing their folder in the second dialog, the script takes those two values, makes them variables, and continues to run the rest of the script. 
    Here is what I would like it to do..
    1. open a dialog window with two input fields, two "browse" buttons, and OK and CANCEL buttons
    2. when you click the first browse button next to the first input field, it will open a file dialog window.  You select your file and the file string will populate the input field
    3. when you click the second button next to the second input field, it opens a folder dialog window.  You select the folder and the string populates the second input field.
    4. when you click OK, it feeds the values in the input fields to a script.
    I already have scripts to that open the file and folder dialogs, but what I can't figure out  how to do is to start and run a script from a button press, in this case, when the OK button is pressed.  It is probably an onClick, but I haven't been able to find any examples of what the syntax would be. 
    The closest I have found is in the Beginning ScriptUI document that was on Jongware's site, in the section on Communication between windows.  But that opens each of the windows with a different script and not using a button press to call a script.
    As always, any point in the right direction is very much appreciated. thanks.

    Thanks Gotterman, but the issue I was having was that the dialogs I was opening were not being created by me.  They were more like OS generated windows.  So I am not able to give the window a name, or the input field a name in order to reference it.
    Peters response was actually correct, although I did have to open the folder dialog a bit differently to get it to work.  I had to use a style that I got from Jongware in a previous thread, but the concept that Peter showed in the last post pointed me in the right direction. 
    I just have one more piece to figure out, how I am going to pass the variables to another script, but I think that is something i will have to work out on my own.
    For anyone who is curious, here is the code I came up, modifying and combining some of Peters examples from the book plus the help he gave me in this thread.  The alert after closing the dialog is just for testing to show that the values are being held by the variables so I can use them else where.
    function mySnippet(){    
    //<fragment>   
    #target indesign;
    #targetengine "session";
    var w2 = new Window("palette", "Window 2", undefined, {resizeable: true});
    var e2 = w2.add ("edittext"); e2.characters = 30;
    var e3 = w2.add ("edittext"); e3.characters = 30;
    var f2 = w2.add ("button", undefined,"Browse XML");              
    var f3 = w2.add ("button", undefined,"Browse Folder");              
    var f4 = w2.add ("button",undefined,"SAVE AND RUN");              
    var tf              
    var tfo                
    f2.onClick = function()                {               
    tf = File.openDialog("Select your XML File","*.xml");                    
    if (tf != null)                    
    e2.text = tf;                    
    f3.onClick = function()                {              
    var tfol = new Folder("~/My Documents")               
    tfo = tfol.selectDlg("Get Folder");                    
    if (tfo != null)                    
    e3.text = tfo;                    
    f4.onClick = function()               
    w2.close();                   
    alert ("xml value: " + tf  + "\nfolder value: " + tfo);                
    w2.show();    
    //</fragment>

  • Unable to capture button event in pageLayout Controller

    Hi Guys,
    I have the following layout
    pageLayout
    pageLayoutCO (controller)
    ----header (Region)
    ----------messageComponentLayout (Region)
    -----------------MessageLovInpurt
    -----------------MessageChoice(Item)
    -----------------MessageTextInput
    -----------------MessageLayout
    ----------HideShow (Region)
    -----------------MessageLovInpurt(Item)
    -----------------MessageChoice(Item)
    -----------------MessageTextInput(Item)
    -----------MessageComponentLayout (Region)
    -----------------MessageLayout
    ------------------------SubmitButton(ID:SearchBtn)
    ------------------------SubmitButton(ID:ClearBtn, fires partial action named clear)
    -----------header(Region)
    I am not able to capture the event fired by the button ClearBtn in the controller of the pagelayout.....
    The two methods I used as follows aren't worked:
    if ("clear".equals(pageContext.getParameter(OAWebBeanConstants.EVENT_PARAM)))
    if (pageContext.getParameter("ClearBtn") != null) {
    what should i do in order to capture the button event in the pageLayout Controller
    Thanks in advance
    Mandy
    Edited by: user8898100 on 2011-8-2 上午7:49

    Mandy,
    Its really strange that its not able to caputure the event in CO.
    Below is the way in which we handle to Submit action at CO level.
    /Check whether ClearBtn is same in case too.
    if(pageContext.getParameter("ClearBtn")!=null){
    System.out.println("Inside the Clear Btn Action");
    Regards,
    Gyan

Maybe you are looking for

  • Shutdown not working properly. APSCourier: : Stream error APSTCPStream

    since a couple of weeks my imac won't shot down properly from time to time. in the log there are a lot of error messages of this kind: <APSCourier: 0x10011deb0>: Stream error occurred for <APSTCPStream: 0x10060c290>: Error Domain=NSPOSIXErrorDomain C

  • Flash Frames On Incoming Video

    I have the strangest problem with flash frames I've ever seen. Whenever I make a cut at a scene change in my footage I get a flash frame on the incoming cut. I immediately assumed it was a field so I lopped off the first frame and... no luck. I actua

  • Sort column by without case sensitive  using Comparator interface

    Hello, When i sorted my values of a column in a table it was showing all sorted upper case letters at top rows and all sorted lower case letters on bottom. So i would like to sort values without case sensitive order. Like. A, a, B, b, C, c.... I am u

  • When OCCI will support GNU GCC v3.3.2?

    When OCCI will support GNU GCC v3.3.2? Would like to know when Oracle will release OCCI to support GCC 3.2 or newer version GCC. I plan to estimate OCCI on GCC 3.2.* for Solaris and Linux to help us make decision when will deploy OCCI solution to our

  • How can I get customer service?

    How can I get costumer service