CFContent open file with # in the name of the file

I am launching a file when the user clicks on a link. Sometimes the file name has a # sign in the name, like "my file #1.xlsx. When he clicks on it, they get an error message saying "the file specified in the contentTag does not exist", then shows... /My file not found.

In addition, even if I do not of course at the moment, I think that I had trouble with some other characters such as ^, *,?, ", <>, |.» And consecutive periods (.) as my... Filename.xlsx. However, I can live with this problem but not the # in the name of the file!

There must be something I can do to start such a file.

Here is what I use:

It's the call: < td > < a \#qryGetFileNames.ServerFile# href="./fileopener.cfm?attached_file=true & posted = #qryGetFileNames.ServerDirectory #" > #qryGetFileNames.ServerFile # < /a > < table > "

< cfset posted = ' #url.file_location # ' >

< name cfheader = "content-disposition" value = "attachment; filename = #file_location #">"

< cfcontent deleteFile = ' ' line = #file_location # reset = "yes" >

Thank you.

Have you tried to escape the #?

#replace(file_location,"#","##","all") #.

OR

In the URL: #URLEncodedFormat (qryGetFileNames.ServerFile) #.

^_^

Tags: ColdFusion

Similar Questions

  • Help! Need a script to automatically open files with the same name but in another location.

    Good morning friends,

    So for my work, I need a script to open files with the same name but located in a different folder. But since I'm a total noob when it comes to programming, I can't understand how do. That's what I have in mind:

    -J' I manually open an image.

    -The script will look for a file with the same name in another folder that I've specified.

    -The script will then select the channel CMYK of the second file and copy and paste it into the first file.

    -The second file is then closed without saving the changes.

    I have problems with the part where the script searches for a file with the same name as the opened file. I would really appreciate help. Thanks in advance.

    If (app.documents.length > 0) {}

    myDocument var = app.activeDocument;

    var Nomdoc = myDocument.name;

    try {var basename = docName.match (/(.*)-.)} [ ^\.] +$/)[1]}

    catch (e) {var basename = thedoc.name};

    var path = / * path of folder to insert as a string here * / + ' / ' + base name + / * insert file extension, including the period as a string here * /;

    If (queue (path) .exists == true) {var otherDocument = app.open (File (path))};

    };

  • . Exe file does not open and with the 'Open with' error popsup program to select

    Original title: my exe file located on my desktop and in my control panel do not open when I click on it

    My exe file located on my desktop and in my control panel will not open when I click on them calling the open window with pop and I have to choose a program to open the file, it's I think that when I was attacked by what looks like a scanning device legitimate XP security 2011. How to address this issue.

    Hi MichelleHarewood,
     
    -With what program to this problem?
     
    This problem occurs when one or more of the following conditions are met:
    • The registry values that are associated with the file name extension are corrupted or missing values.
    • The computer is infected with a virus.

    Follow the steps listed in the article given below to resolve this issue:

    Cannot open files with extensions such as.exe, .com, and.lnk on a Windows XP-based computer

  • Adobe *.pdf files can be opened in Internet Explorer, the default program can not be changed to acrobat reader in the properties or select 'Open with'

    Adobe *.pdf files can be opened in Internet Explorer, the default program can not be changed to acrobat reader in the properties or select 'Open with'. Cannot change the default program of Adobe in the file association list.

    I have the latest version of Adobe (9.3.3).

    Hello

    Don't forget to log on as an ADMINISTRATOR

    Use this utility to unassociate the. PDF and then re - associate with Adobe Acrobat Reader.

    How Unassociate a Type of Extension file in Vista and a utility to help
    http://www.Vistax64.com/tutorials/91920-unassociate-file-extention-type.html

    How to set default Associations for a program under Vista
    http://www.Vistax64.com/tutorials/83196-default-programs-program-default-associations.html

    How to associate a file Extension with a program Type in Vistahttp://www.vistax64.com/tutorials/69758-default-programs.html

    How to view and change an Extension of filename on Vista
    http://www.Vistax64.com/tutorials/103171-file-name-extension.html

    Restore the Type Associations by default Vista file extensions
    http://www.Vistax64.com/tutorials/233243-default-file-type-associations-restore.html
    I hope this helps.

    Rob Brown - MS MVP - Windows Desktop Experience: Bike - Mark Twain said it right.

  • To-do bar display of the names of open files

    In Windows Vista, it used to display my documents open in the taskbar with all instances of applications (such as IE) and the names of open files. Windows 7 is not that. Is it possible to restore that? I find it really useful to the click on the right app or the document I want to open.

    David

    Anchorage Alaska

    Right click on the taskbar-> properties-> Taskbar Button :-> select never combine-> Apply-> OK

    See if that helps.
  • How can I determine the full path and name of the currently open file .ai?

    In Photoshop, right click the file name of the current open file shows an option 'Reveal in Explorer' so I know exactly where the file was opened from.

    In Lightroom, it is displayed in the metadata.

    New to illustrator, I looked in the options of the menu get charge can not see how to find this information.

    Would appreciate the help.

    agckent,

    Is it ALWAYS the case where the folder opened by "Save AS" is the file of the source code for the file that I am saving?

    I believe, with a reservation for the strange behaviour of the different OS versions: in the contrary case, the save option under would lead astray you.

    Edit: Hi Carlos.

  • Problems with the opening of attachments when the user has restristed privilege to run executable code from Program Files and Windows folders.

    I'm trying to prevent users from running potentially dangerous files. According to the Windows policies so I put. Users can run any application Program Files, files (x 86), windows, and folder to all users of the program office. Users have no permission to write anything in this files. When the user double clicks for example document.doc on his desk - document opens fine with MS Word. But when the user tries to open this document in attachment directly (by selecting open with MS Word, instead of the economy) - he sees an error - "this action is limited by local politics. Ask your system administrator. "(not exact text).

     So I want, users able to open attachments from Thunderbird automatically, but not able to run any application or link, except Program Files, Program Files (x86), Windows and all users' desktop folder. How can I get this result?
    

    Thanks in advance.
    Calvo is serious.

    PS Sorry for my bad English. It is not my mother tongue.

    Thanks for responding.
    I discovered what was going on.
    This strange "bug" affects multiple computers with Windows 7 Ultimate in my case.
    When you create a SRP (software restriction policies) it creates two rules by default to run programs: windows folder and the Program Files folder. I manually add "C:\Program Files (x 86)" in places without restriction. BUT Windows and Program Files folder to default rules directly, but through registry keys. And this part seems difficult. You CAN run the executable files of Program Files. You CAN run the Program Files (x 86) executables. But if Thunderbird or Firefox try to run MS Word or excel or editor for.doc or *.odt opening or another file - downloaded files running programs blocked by SRP.
    In order to fix this, simply replace the rules for indirect paths like % HKLM/software/microsoft/windows... etc % with direct, for example "C:/Windows" and "C:/Program Files /". After that, everything works fine. Attachments and downloaded files automatically opens without a problem.

  • Changed the name of a bookmark in a folder, now when I try to open the file, it tries to open every bookmark in the file.

    I have a folder of bookmarks in the toolbar. I changed the name of one of the bookmarks in that folder. The next time I tried to open the file, I had (and continue to receive) a message saying that I'm about to open 47 tabs, and this can slow down the firefox. I have only to open the file, not each bookmark in it and does not know how to get it by allowing me to do.

    That only happens if you click on this button to folder in the bookmarks toolbar, or you cannot open this folder in the sidebar (Ctrl + B) or the bookmarks menu as well?

  • When I open a link irc with a string name that contains "~" at the end, firefox (14.0.1) opens the same channel name but with "7%" instead of "~" at the end

    When I open a link irc with a string name that contains "~" at the end, firefox (14.0.1) opens the same channel name but with "7%" instead of "~" at the end
    http://img835.imageshack.us/img835/2856/clipboard05nq.jpg

    I can't open the image, but I can say something in general about the tilde.

    The tilde "~" is an unreserved character and that's why it can be replaced by its form encoded percentage '% 7' inside a URI without changing the meaning. See

    http://en.Wikipedia.org/wiki/percent-encoding

    According to article 2.3 of RFC3986 we should prefer the encrypted form so this behavior seems to be somewhat outdated.

  • I created a custom and registered with a specific name date format. However, when I open a new worksheet, my saved format does not display in the menu drop-down? Am hoping that I don't need to create the same format for each new sheet?

    I created a custom and registered with a specific name date format. However, when I open a new worksheet, my saved format does not appear in the menu drop-down? Am hoping that I don't need to create the same format for each new sheet?

    You must save the spreadsheet containing the new date as a model format and use this custom template for each new spreadsheet where you want that this date format personalized at your disposal.

  • In the Photos of El Capitan how to record a double published in a separate with its own name and the ID file file?

    In the Photos of El Capitan how to record a double published in a separate with its own name and the ID file file?

    Only by exporting - with Photos (and iPhoto and Aperture) - you can have several versions of an image by duplicating the image (control - D), but this does not create an image file separated until you export - it creates a separate edit list in the database that applies to the original when you watch or export the photos

    Photos as it were its predecessors is a non-destructive control Digital Asset Manager (DAM) which does not any changes to files in the database but built a list of validation

    LN

  • Problem with opening files and programs after the attack "rogue security."

    Earlier this year, I met a rogue security program called Windows Security 2011. I had removed it, but I'll still have some serious problems. I found another user here, who had a similar encounter: http://answers.microsoft.com/en-us/windows/forum/windows_xp-windows_programs/exedirectory-file-association-problems/5dcd9044-8b57-43e0-a3bc-0c966326f0da

    "But since the incident, the PC has struggled to open .exe files. If I open Mozilla Firefox, for example, it will ask me to specify the program to run it with. I can browse the OS and find the firefox.exe and open it with that, but it won't allow me to check the box "always use this option. "

    It's exactly the same problem that I have now, as well as some sections of the control panel not working not at all, but there is no answer about what to do after the malware has been removed. Is there a way this can be fixed now?

    Hi Lapeul,

    You can create a new user account and check if you can solve the problem.

    How to create and configure user accounts in Windows XP

    If you are able to resolve the problem, you can consult the following article to fix the damaged user account.

    How to recover damaged Windows XP user profile

  • Cannot open .exe programs in XP except MS IE - ask "open with - choose the program you want to use to open this file.

    Any of the My .exe programs such as office, Firefox, Skype can be opened from desktop file icons or programs. Request to the dialog box opens: "open with, choose the program you want to use to open this file" - but only lists MS programs that don't work, or "error - Application not found". Only the program that works is MS IE.

    Looks like your Windows file associations have to dispose. This means that XP is not
    know what to do with the files by looking at the file extension (for example, .exe for executables,
    .doc for MS documents, etc.).

    If you don't have it you, something done for you - most likely malware.

    Go to this site WWW by Doug Knox:

    http://www.dougknox.com/

    On the left, click on the Win XP fixes, file Association fixed and read the instructions at the top of the page.

    Download the EXE File Association Fix on your desktop, unzip the file and apply it by following the instructions at the top of the page, then to restart and test.

    Run the following scans for malware, and then fix any problems:

    Download, install, update and do a full scan with these free malware detection programs:

    Malwarebytes (MMFA): http://malwarebytes.org/
    SUPERAntiSpyware: (SAS): http://www.superantispyware.com/
    They can be uninstalled later if you wish.

  • I have windows vista and when I click on a shortcut on the desktop I have a pop up asking what file to open it with. In order to open the file I find the actuall file.

    Original title: registry exe problem

    I have windows vista and when I click on a shortcut on the desktop I have a pop up asking what file to open it with. In order to open the file I find the actuall file. This also occurs when you download the software, which makes it difficult, because the file is not on the pc yet. All solutions?

    Looks like you may have a virus or other malware. Get your updated antivirus program and boot into Safe Mode. Note that some viruses can hide from your normal antivirus program, so you really need to scan in Safe Mode. To enter in Safe Mode when you turn on first, press F8 on every seconds until you get the menu, and then select Safe Mode. Then run a complete system scan.

    Microsoft has suggestions and offerings to

    http://Windows.Microsoft.com/en-us/Windows7/how-do-I-remove-a-computer-virus

    Moderator Forum Keith has a few suggestions along this line to

    http://answers.Microsoft.com/en-us/Windows/Forum/Windows_7-performance/Windows-Explorer-has-stopped-working/6ab02526-5071-4DCC-895F-d90202bad8b3

    If that suits him fine. If this is not the case, use system restore to go back to an earlier date at the beginning of the problem. To run system restore, click Start-> programs-> Accessories-> System Tools-> system restore. Click on the box that says show more restore points.

    You can check the corrupted system files. Open an administrator command prompt and run SFC if the above does not help. Click START, and then type sfc in the search box, right-click to SFC. EXE and click run as administrator. Then, from the command prompt type sfc/scannow.

    Finally if all else fails, you can look at the rather cryptic system event log. To make, click Start-> Control Panel-> administration-> event viewer tools. Once in Event Viewer system log-click and scroll entries looking for these "error" with indicator see if you can find guidance on where the problem may be.

    I hope this helps. Good luck.

  • Cannot open files with the EXTENSION of the PPT FILE

    I can't open a file with the following extension using PowerPoint ppt. The message below is what I get-

    The selected file is not a valid Microsoft PowerPoint file. It may be a file created by another program.

    Try by double-clicking the file in Windows Explorer to see if another program opens to it. If PowerPoint opens again when you double-click the file in Windows Explorer, it is possible that the file is not a PowerPoint file, but its extension has been renamed to be that of a PowerPoint file type registered (for example, .ppt, .pptx, .pps, .ppsx, .pptx, .pot or .potx) but the file is not a PowerPoint file.

    To determine which program can open the file, try one of the following:

    • Contact the original author (if known) to know what program you used to create this file. Then rename the file with the correct extension so that it can be opened by this program.
    • Try opening the file in other programs.
    • If you or someone you know, are very knowledgeable about software, review the file header in a text editor to determine which program can read the file.

    Another possibility is that the file has been damaged during transfer from another computer. Trying to transfer the file again.

    The file may be damaged. If you have a copy of the file backup, use it. It is not possible repair corrupted file.

    Hello

    see if this applies to your problem

    you don't say what version of Microsoft office powerpoint, you try to open it with

    read below link information saying that you have need of powerpoint 2010 or other programs listed for ppt file extensions

    http://www.FileInfo.com/extension/ppt

    Microsoft PowerPoint 2010 Info
    Microsoft PowerPoint Viewer Info
    Nuance OmniPage 17 Info
    ACD Systems Canvas 12 Info
    Corel WordPerfect Office X 5 Info
    OpenOffice.org

    If you have an earlier version of powerpoint read this

    Install the compatibility pack if you want to open, edit and save documents, workbooks, and presentations that were created in newer versions of Word, Excel and PowerPoint. Scroll down to see the instructions and system requirements.

    http://www.Microsoft.com/downloads/en/details.aspx?FamilyID=941b3470-3ae9-4aee-8f43-c6bb74cd1466&DisplayLang=en

Maybe you are looking for