An odd Windows behaviour

Discussion in 'NZ Computing' started by Gib Bogle, Mar 7, 2013.

  1. Gib Bogle

    Gib Bogle Guest

    Normally when you right-click on a file and select 'Open with' you can
    choose the program to open the file, either from the supplied list of
    candidates or by browsing for the .exe. I have found that on one
    machine I use (Windows XP, work computer) I am not able to open a
    particular file type like this. The file is .pro, and is opened by
    qtcreator.exe. When I browse for and select qtcreator.exe, the OS
    ignores my choice and insists on opening it with my text editor. The
    only way to open the file is to start qtcreator then open it. Other
    machines I use do not have this problem.

    It would be nice to understand what's happening, but more important to
    know how to correct the problem. Presumably there is a way to tell
    Windows that qtcreator.exe is the way to open a .pro file. Can someone
    tell me what this is?
     
    Gib Bogle, Mar 7, 2013
    #1
    1. Advertisements

  2. Gib Bogle

    Gib Bogle Guest

    BTW the standard approach to set the file association does not work.
    There seems to be something special about the .pro extension, on XP anyway.
     
    Gib Bogle, Mar 7, 2013
    #2
    1. Advertisements

  3. Gib Bogle

    ~misfit~ Guest

    Maybe it's been told to always open with notepad (checkbox ticked)? I could
    be wrong.......

    If so I think there's a registry setting that can be changed to go back to
    giving you a choice.
    --
    /Shaun.

    "Humans will have advanced a long, long, way when religious belief has a
    cozy little classification in the DSM."
    David Melville (in r.a.s.f1)
     
    ~misfit~, Mar 7, 2013
    #3
  4. Gib Bogle

    Gib Bogle Guest

    Unticking the checkbox and trying to set up a different program doesn't
    succeed. Presumably the setting procedure (going through Control Panel,
    Folder Options, File Types... takes you to the same place as the
    right-click, open with, ...) does write a registry setting. I could
    search for it I guess...
     
    Gib Bogle, Mar 7, 2013
    #4
  5. Gib Bogle

    Gib Bogle Guest

    Oddly, qtcreator.exe is in the registry setting for .pro. It does not
    appear in the list offered in Explorer though. It's as if it doesn't
    meet some Windows criterion. I thought perhaps its location needed to
    be in the PATH, but that didn't make any difference.
     
    Gib Bogle, Mar 8, 2013
    #5
  6. Gib Bogle

    ~misfit~ Guest

    Bugger! Well, that's me out of ideas then. :-/ Sorry my suggestion wasn't
    of use.
    --
    /Shaun.

    "Humans will have advanced a long, long, way when religious belief has a
    cozy little classification in the DSM."
    David Melville (in r.a.s.f1)
     
    ~misfit~, Mar 8, 2013
    #6
  7. Gib Bogle

    Gib Bogle Guest

    Thanks for trying, mate!
     
    Gib Bogle, Mar 8, 2013
    #7
  8. Gib Bogle

    Malcolm Guest

    Malcolm, Mar 8, 2013
    #8
  9. Gib Bogle

    Gib Bogle Guest

    Gib Bogle, Mar 8, 2013
    #9
  10. Gib Bogle

    Gib Bogle Guest

    Gib Bogle, Mar 8, 2013
    #10
  11. Gib Bogle

    Guest Guest

    Try adding qtcreator to the "send to" list

    http://support.microsoft.com/kb/310270
     
    Guest, Mar 8, 2013
    #11
  12. Gib Bogle

    Malcolm Guest

    Hi
    Strange indeed, something out of whack somewhere...

    Have you browsed the registry for the extension to see where it exists?
     
    Malcolm, Mar 8, 2013
    #12
  13. Gib Bogle

    Gib Bogle Guest

    As I mentioned, qtcreator.exe is in the registry entry for .pro, but it
    is ignored.
     
    Gib Bogle, Mar 8, 2013
    #13
  14. Gib Bogle

    Gib Bogle Guest

    Gib Bogle, Mar 8, 2013
    #14
  15. Gib Bogle

    Ralph Fox Guest


    Does a search find registry keys for .pro in other places?
    There is more that one place in the XP registry where you find
    registry entries for file extensions.

    For example...

    1. HKEY_CLASSES_ROOT\
    which is a merger of:
    1.1 HKEY_CURRENT_USER\Software\Classes\
    1.2 HKEY_LOCAL_MACHINE\SOFTWARE\Classes\

    2. HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Explorer\FileExts\
     
    Ralph Fox, Mar 8, 2013
    #15
  16. Gib Bogle

    Guest Guest

    Try making a batch file that does
    echo %1
    and add the batch file to the send to list.

    If you type
    qtcreator.exe yourfile.pro
    on the command line, does the file get opened?
     
    Guest, Mar 8, 2013
    #16
  17. Gib Bogle

    Gib Bogle Guest

    Command line invocation of qtcreator works as expected.

    I added the echo batch file to sendto - what should I expect to see?
     
    Gib Bogle, Mar 9, 2013
    #17
  18. Gib Bogle

    Guest Guest

    If you "send" yourfile.pro to the batch file it should output the name
    of the file to the screen - but come to think of it, it's going to
    immediately close the shell (cmd.exe) - so you need to add a pause
    command to the end of the batch file. This just checks that send to
    is working.

    If you run regedit and look at HKEY_CLASSES_ROOT.pro - there should be
    several entries there - you could compare them with what you see for
    some other file extension - say, .txt
     
    Guest, Mar 9, 2013
    #18
  19. Gib Bogle

    Guest Guest

    uh, do you mean that right click on yourfile.pro -> send to -> qt
    creator - doesn't work? I was trying to suggest an alternative to
    the file association.

    Also, you could try this - found this on the internet



    Fix file associations from the Command Line: Did you leave the Always
    Use This Program To Open This File option
    turned on? Do you want to change it back so it prompts you to specify
    a program each time? To delete the association
    with that file type, at the command prompt enter the command
    ASSOC.EXT= [where .EXT specifies the extension of
    the file type whose association you want to delete (e.g., .WAV for
    wave files)].

    Now whenever you double-click on the file of that type, the system
    will ask you what program you want to use to open
    the file. For more information:
    http://www.dougknox.com/xp/tips/xp_easy_file.htm.
     
    Guest, Mar 9, 2013
    #19
  20. Gib Bogle

    Gib Bogle Guest

    Oh, I didn't understand that. That works! The mystery about 'Open
    with' remains, but this is a feasible alternative. Thanks!
    ASSOC.PRO= left the text editor as the automatic program that opens a
    ..pro file.
     
    Gib Bogle, Mar 9, 2013
    #20
    1. Advertisements

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments (here). After that, you can post your question and our members will help you out.