Set default name of document before save

I have created a "save as" button on a form.
When the user presses the button (e.g., mouse up) I want the save as dialog box to appear with a NEW programmatically defined file name to appear.  (NOT the existing file name).
The block comes because saveAs is a restricted method.
Any clues how to accomplish this seemingly simple task?

If you didn't mind some extra steps for the user, you could accomplish much the same thing by creating a dialog asking if the user wants to save the file named with the current date (as above).
Then if they wanted the file to be saved, you could ask them to navigate using app.browseForDoc ({ bSave: true}), and save using the returned cPath and your new filename.
Not quite a true save-as dialog, but you can get the file where the user wants it, and with the name you want to give.
Or if you want to save it in the same folder as the current document, just do doc.saveAs({ cPath: this.path })
Darryl

Similar Messages

  • Set default font for document

    Is there a way to set the default font for all objects in a document? For some reason it is Helvetica Neue every time and I need to change it to what I want.

    Hello
    The defaults reached thru the Terminal are not storing infos about the font used as default one in a template.
    I apologize but when I select all in a Numbers document and save it as a template, it doesn't match your requirements.
    Each time I insert a new table it defaults to HelveticaNeue.
    This is why I gave the tip which changes the font name in the Index.xml file.
    From my iDisk:
    <http://idisk.mac.com/koenigyvan-Public?view=web>
    you may download:
    :For_iWork:changeFont.zip
    which gives you the ability to do the job very easily.
    you may also download
    For_iWork:removePrintRecord.zip
    which removes the print Record embedded in our documents if this one is annoying.
    Yvan KOENIG (from FRANCE vendredi 6 juin 2008 14:57:02)

  • ExprHow to set default name for Express VI

    I have created an express and when I drag drop the express in block diagram, I am getting a name "A1". What should I do to set a default name (for example "B") for my express VI? I tried updating the Window title properties of the source VI.
    Thanks in advance.
    Regards,
    Satish

    Hello diademi!
    Select the menu 'Einstellungen' / 'Optionen' / 'Allgemeines...'. You get the dialog 'Allgemeine Einstellungen'. Click on the button 'Kompatibilität...'. In the dialog 'Kompatibilität' you have the flag 'Sprachunabhängige Ergebniskanalnamen in ANALYSIS' where you can set the behaviour. If you press Ctrl+A and paste in a text editor you can see that it is variable CompResChnNaming.
    Matthias
    Matthias Alleweldt
    Project Engineer / Projektingenieur
    Twigeater?  

  • JFIleChooser set default name

    Why is that if I do
    chooser.setSelectedFile(something)
    everytime I change the directory the file name is replaced by the current working directory?
    I wanna set the name that stays there until the user explicitly decides otherwise.
    How can I make it that the file name stays?

    I have noticed this bug in older versions of Swing. Use JDK 1.3 or above to fix this problem.
    -Andrew

  • Setting default value of document library column using powershell

    Created document library based on template which is using custom content type containing managed metadata based column.
    I can upload documents. Everything looks normal except when I visit Column default value settings page in DL settings, I get error message below
    Application error when access /_layouts/15/ColumnDefaults.aspx, Error=Value does not fall within the expected range.   at Microsoft.SharePoint.SPWeb.GetWebRelativeUrlFromUrl(String strUrl, Boolean includeQueryString, Boolean canonicalizeUrl)    
    at Microsoft.Office.Server.WebControls.MetaDataNavTree.TreeViewDataBound(Object sender, EventArgs e)     at System.Web.UI.WebControls.HierarchicalDataBoundControl.PerformSelect()     at Microsoft.Office.DocumentManagement.MetadataNavigation.MetadataNavigationContext.OnTreeViewLoad(SPTreeView
    spTreeView)     at Microsoft.Office.Server.WebControls.MetaDataNavTree.PerLocationPageLoad()     at Microsoft.Office.DocumentManagement.Pages.ColumnDefaultsPage.OnLoad(EventArgs e)     at System.Web.UI.Control.LoadRecursive()
        at System.Web.UI.Page.ProcessRe...  6bf73b9c-e4f3-10ae-0f74-9672cdd9936f
    I tried many things but nothing seems to work. When I create document library using SharePoint OOB template, everything works.
    Any help would be appreciated.
    Thanks.

    I found another way to fix this. Thanks to you pointing me to the file "{List Name}/Forms/client_LocationBasedDefaults.html"
    I found the difference between this file and the one of a list that worked:
    I had "&" in the names of some folders. The recreated subsites from a template that contained such folders in the document library had the problem descriped by the OP. In the recreated client_LocationBasedDefaults.html there were actual '&'
    in the folder names instead of '%26' escape characters. After replacing those characters with their escaped version everything worked as expected again.

  • Set default tab for Document Properties windows

    Greetings!
      Once I open a PDF document and go to File > Properties I always get the Security tab open by default:
      Can you suggest me a way to change tab displayed by default to the other one, for example Description please?
      Thank you!

    Oh. This is a logic.
    I used to click to closing X at the top right.

  • Set default monitor at boot before X?

    Hi,
    I have a plasma tv and a normal 24" monitor plugged into a Nvidia GTX 960 both are DVI.
    When I boot up the TV is the default and the monitor doesnt display anything.
    Both work fine in X but how can I set the monitor to be the default monitor on boot?
    Thanks.

    shtnarg wrote:I wouldn't think both ports are different? That'd be unique! Try physically switching them at the video card side. I think it should work.
    Honestly the DVI ports are two different types DVI-D and DVI-I. Only one is able to covert DVI to old VGA with an adaptor. So the TV has to be lugged into that port as it's VGA.
    Here's a picture of my actual card http://www.gigabyte.com/fileupload/prod … 44_big.png
    Those extra 4 holes in the port on the left are what allow the analogue conversion. I think manufactures are starting to phase out the old DVI-D like they did for VGA.

  • Setting Workstation name automatically after/before imaging

    Hello,
    I am planning on imaging 150 workstations from one base image. Currently, the workstation name (computername or wsname) is 'uitdelen'. All imaged workstation also receive this name.
    In the past i used the tool WSNAME to change the name upon first boot using the /GH switch.
    But doing this on 150 PCs is troublesome.
    What i would like is that i have a txt file with the serial numbers of the machines, and the workstation name (computername) it should receive. This file would have to be read by the Zen 7 boot CD (i use 6.5, but use the 7 bootcd, because that recognises the nic, where the PXE doesnt)
    Any hints?
    Stations are Windows XP pro

    stgvolks,
    It appears that in the past few days you have not received a response to your
    posting. That concerns us, and has triggered this automated reply.
    Has your problem been resolved? If not, you might try one of the following options:
    - Visit http://support.novell.com and search the knowledgebase and/or check all
    the other self support options and support programs available.
    - You could also try posting your message again. Make sure it is posted in the
    correct newsgroup. (http://forums.novell.com)
    Be sure to read the forum FAQ about what to expect in the way of responses:
    http://support.novell.com/forums/faq_general.html
    If this is a reply to a duplicate posting, please ignore and accept our apologies
    and rest assured we will issue a stern reprimand to our posting bot.
    Good luck!
    Your Novell Product Support Forums Team
    http://support.novell.com/forums/

  • I need Badi for PO Before save.

    Hi Abappers,
    i want Badi name for PO Before save.
    Regards,
    vani.

    Hi,
    To find the badi for a particular transaction goto TCode SE24 and give the class name as CL_EXITHANDLER and then display it. now double-click on GET_INSTANCE you will get some source code , put a break point on class name and give TCode on command field then debug . double click on class name and go on pressing F5, you willl get list of BADI's and according to your requirement choose the right one.
    Second procedure:
    Go to SE84, Enhancements< Business-addin< definition(double click) and give package name of particular transaction then you will get BADI's. Read documentation by going to SE18 or SPRO and choose the right one according to your requirement
    I think ME_PROCESS_PO_CUST may satify your requirement.

  • Saving a Pages document: when I first save a pages document it saves and I don't know where it goes or what its name is.  I want to be asked every time I save a pages document what to name it and where to save it. How do I set this preference?

    Saving a Pages document: when I first save a pages document it saves and I don't know where it goes or what its name is.  I want to be asked every time I save a pages document what to name it and where to save it. How do I set this preference?

    I'll guess that you've used a page layout document & pasting created a text box. You can add more pages & create linked text boxes, but I think you'd be better of using a word processing document. In word processing documents there is a basic text layer & additional pages will be created as needed to fit the text. Take a look at the toolbar of your document. If it says "sections" for the +page icon it's a word processing document, if it says "pages" it's a page layout document.

  • Set default save for documents to Full Size

    My Acrobat 9 Standard got reset to save my documents at 10%, I need to save them at 100% without resaving every document under Save as.

    No. You can't pre-fill the Save As dialog. What you can do is offer the new
    name in a prompt window just before the file is saved, or you can use a
    script that automatically saves the file under the new name (this requires
    the script to be installed on the local machine, not just to be embedded in
    the PDF file).

  • Whenever you try to save a PDF file to a location other than the default location ('My Documents'), Firefox freezes & you have to go to the 'Task Manager' to exit Firefox and stop the error, so you can load Firefox again.

    Whenever you try to save a PDF file to a location other than the default location ('My Documents'), Firefox freezes & you have to go to the 'Task Manager' to exit Firefox and stop the error. I have Windows XP (Media Center Edition) and all updates (Firefox, Adobe PDF, Microsoft, virus protection, etc) are installed. This has only been a problem since Firefox 4, and isn't a problem in Internet Explorer.

    Hi David,
    Thank you for your detailed question. It sounds like the real issue is pdf files. Are there any antivirus/firewalls that might be blocking this specific file type? or are there any preferences in your control panel that might be blocking this?
    Do you have any stored preferences for PDF files in Firefox?
    *[[Applications panel - Set how Firefox handles different types of files]]

  • How do I get a "Details" display--as the default--when downloading a file, in the "Enter name of file to save to..." dialog box?

    When I receive an attachment to an email, and I click it and select "Download", I get the "Enter name of file to save to..." dialog box (because I already set the option to "Always ask me where to save files." But the file display always defaults to a "List". At least recently. I don't recall it always doing that. In any case, I want it to default to a "Details" display, in ascending order, as I can then find things sooo much faster that way. (I often use the "Date Modified" tab to bring to the top the most recent version of a file.) I know that I can go to the "View Menu" icon and select "Details", but each time I go into a sub folder while in this dialog box, I have to do that all over again and it wastes a lot of time and attention.
    I did some internet searches but didn't find a way to fix this.

    Thanks for reaching out, glennr.
    The dialog box you are describing is controlled by Windows, not Firefox, so unfortunately Firefox cannot change what you see by default.
    I think your best bet would be to ask on the [http://answers.microsoft.com/en-us/windows/forum/windows_xp?auth=1 Windows support site].

  • Setting name and type on save-file...

    Hi !
    New to this board, hope you will excuse me if i�m asking something stupid :-)
    I�m pretty new to JAVA, and at the moment I need to modify some code, so that it will dynamically preset the name and file-type when the user chooses to save. I'ts a small bit of code that uses different JPEG-pics, and I need to get the name of the current pic+ a type on every save. I think I have the saving part fixed, but need someway to set the name for every save..
    Thanks in advance, sincerely
    Ramzez

    Look at the JFileChooser API. Feed it with an appropriate FileFilter implementation and a default name (setSelectedFile(File f)).

  • How to set the default name when exporting a report ?

    <p><span class="PSLONGEDITBOX">I use crystal reports in my C# asp application, with the CrystalReportViewer class. When the end user exports the reports by clicking on the toolbar button, the "save as" dialog box appears, with  default name "_viewer.pdf" or "_viewer.xls" etc. "_viewer" being the CrystalReportViewer&#39;s instance name. <br />Has anyone an idea to change this default name ? </span></p><p><span class="PSLONGEDITBOX">T</span><span class="PSLONGEDITBOX">he end user would like at least the report name. <br /><br />Thanks</span></p>

    I looked around and I it appears that you have found the only way to set this. There doesn't seem to be dynamic support for the exported file names.
    Rob Horne
    http://diamond.businessobjects.com/blog/10

Maybe you are looking for

  • Advice on buying first imac?

    Hello all, I would like a little help with the following? I am looking at trading up from my old 10" netbook running windows xp, 143GB of hard drive of which I have only used 26GB, 1.60Ghz, 2GB of RAM, I upgraded that myself from one to two. I also h

  • Parental control issue

    I am unable to unlock the parental controls in iTunes 9.0. I receive the following error message "The parental control preference could not be unlocked because the user "dw00521" does not have administrative privileges." I don't ever remember creatin

  • Itunes version on latest Muontain Lion

    is this new version of OS X Mountain Lion includes the latest version of itunes?? because i had problems with iphone USB tethering in the latest itunes version that i had to go through **** to fix it...

  • Assistance with multiple HD Setup

    I was wondering what would you guys recomend on how I should approach setting up all these disks for a backup/ scratch drive  and to best utilize/ optimize the computer's tasks read/ write. I'm using Premier Pro and After effects mostly. (1) 180 GB S

  • REFERENCE VALUES BETWEEN REPORTS MODULES COMPONENTS IN DESIGNER6I

    Good afternoon; I am building a report in Designer 6i which inludes 4 different module components. My question is.. How can you verify (and pass) a field's actual value between module components? Thank you, Michel Turcot