[bug] Windows 7 double-click file brings up empty vim

14 views
Skip to first unread message

Garner Halloran

unread,
Jul 20, 2010, 10:22:12 AM7/20/10
to vim...@vim.org
Using 7.3a BETA on Windows 7.  If I double click on any file in explorer that has been associated with gvim it brings up an empty editor.  I can drag the file into the window and it will work.  I can right click and Edit with Vim and it will work.  Gvim is my editor for p4v and if I double click a file there it works.

I removed my _vimrc and the problem still exists.  That is the version I created the bug report with to limit the size.

I tried rebooting and that didn't fix it.  I tried associating the file type with another editor and re-associated with gvim.  To do that I'm using "open with..." and then "choose default program".

Let me know if you want me to try something or give more information.
bugreport.txt

Garner Halloran

unread,
Jul 27, 2010, 3:03:06 PM7/27/10
to vim...@vim.org
Still happening in 7.3b.

Is there a list of open bugs?  I don't want to keep harping on something as long as I know it'll be addressed at some point.

Thanks!

Bram Moolenaar

unread,
Jul 27, 2010, 4:48:46 PM7/27/10
to Garner Halloran, George V. Reilly, vim...@vim.org

Garner Halloran wrote:

I can reproduce the problem. The "Edit with Vim" menu works fine, the
"Open with..." results in starting Vim without a file.

I'm using the 64 bit version of Windows 7, if that matters.

George?

--
People who want to share their religious views with you
almost never want you to share yours with them.

/// Bram Moolenaar -- Br...@Moolenaar.net -- http://www.Moolenaar.net \\\
/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
\\\ download, build and distribute -- http://www.A-A-P.org ///
\\\ help me help AIDS victims -- http://ICCF-Holland.org ///

Ben Fritz

unread,
Jul 27, 2010, 6:52:25 PM7/27/10
to vim_dev


On Jul 20, 9:22 am, Garner Halloran <garner...@gmail.com> wrote:
> Using 7.3a BETA on Windows 7.  If I double click on any file in explorer
> that has been associated with gvim it brings up an empty editor.  I can drag
> the file into the window and it will work.  I can right click and Edit with
> Vim and it will work.  Gvim is my editor for p4v and if I double click a
> file there it works.
>


What happens if you set up file associations manually?

http://vim.wikia.com/wiki/Windows_file_associations

This is probably a problem with the installer...maybe Windows 7 does
file associations differently than previous Windows versions? If so we
should update the tip as well as the installer.

Garner Halloran

unread,
Jul 28, 2010, 10:20:58 AM7/28/10
to vim...@googlegroups.com

--
You received this message from the "vim_dev" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

That did not work.  I tried this with just a .txt file.

assoc .txt=txtfile
ftype txtfile="c:\vim\vim73b\gvim.exe" --remote-silent "%1"

It still launches gvim but no text.

I also tried this:

assoc .=txtfile

Then I tried to double-click _vimrc and it opened it up in an existing gvim and replaced one of my buffers.  I then closed all of my gvim windows and tried again.  Double-clicking _vimrc opened it up in a new window.  Very strange.

And finally I closed all gvim windows and tried opening a .txt file again, but no luck.

Bram Moolenaar

unread,
Jul 28, 2010, 4:57:07 PM7/28/10
to Garner Halloran, vim...@googlegroups.com

Garner Halloran wrote:

I suspect it's a problem with OLE. It registers Vim as a server, but
uses the ordinary registry methods.

The installer src/dosinst.c was changed to use registry methods that
also work for a 32 bit binary running on 64 bit windows. Perhaps
someone can look into this and adjust src/if_ole.cpp?

--
If all you have is a hammer, everything looks like a nail.
When your hammer is C++, everything begins to look like a thumb.
-- Steve Hoflich, comp.lang.c++

Stormy

unread,
Jul 29, 2010, 10:49:26 AM7/29/10
to vim_dev
I have the same problem with 7.3b BETA on Windows XP SP3 32-bit,
having associated a filetype by right-clicking in Windows Explorer and
setting it to always open in gvim.exe.

On Jul 28, 3:57 pm, Bram Moolenaar <B...@Moolenaar.net> wrote:
> Garner Halloran wrote:
> > On Tue, Jul 27, 2010 at 6:52 PM, Ben Fritz <fritzophre...@gmail.com> wrote:
>
> > > On Jul 20, 9:22 am, Garner Halloran <garner...@gmail.com> wrote:
> > > > Using 7.3a BETA on Windows 7.  If I double click on any file in explorer
> > > > that has been associated with gvim it brings up an empty editor.  I can
> > > drag
> > > > the file into the window and it will work.  I can right click and Edit
> > > with
> > > > Vim and it will work.  Gvim is my editor for p4v and if I double click a
> > > > file there it works.
>
> > > What happens if you set up file associations manually?
>
> > >http://vim.wikia.com/wiki/Windows_file_associations
>
> > > This is probably a problem with the installer...maybe Windows 7 does
> > > file associations differently than previous Windows versions? If so we
> > > should update the tip as well as the installer.
>
> > > --
> > > You received this message from the "vim_dev" maillist.
> > > Do not top-post! Type your reply below the text you are replying to.
> > > For more information, visithttp://www.vim.org/maillist.php
>
> > That did not work.  I tried this with just a .txt file.
>
> > assoc .txt=txtfile
> > ftype txtfile="c:\vim\vim73b\gvim.exe" --remote-silent "%1"
>
> > It still launches gvim but no text.
>
> > I also tried this:
>
> > assoc .=txtfile
>
> > Then I tried to double-click _vimrc and it opened it up in an existing gvim
> > and replaced one of my buffers.  I then closed all of my gvim windows and
> > tried again.  Double-clicking _vimrc opened it up in a new window.  Very
> > strange.
>
> > And finally I closed all gvim windows and tried opening a .txt file again,
> > but no luck.
>
> I suspect it's a problem with OLE.  It registers Vim as a server, but
> uses the ordinary registry methods.
>
> The installer src/dosinst.c was changed to use registry methods that
> also work for a 32 bit binary running on 64 bit windows.  Perhaps
> someone can look into this and adjust src/if_ole.cpp?
>
> --
> If all you have is a hammer, everything looks like a nail.
> When your hammer is C++, everything begins to look like a thumb.
>                         -- Steve Hoflich, comp.lang.c++
>
>  /// Bram Moolenaar -- B...@Moolenaar.net --http://www.Moolenaar.net  \\\
> ///        sponsor Vim, vote for features --http://www.Vim.org/sponsor/\\\
> \\\        download, build and distribute --http://www.A-A-P.org       ///

Garner Halloran

unread,
Aug 2, 2010, 1:47:41 PM8/2/10
to vim...@googlegroups.com
7.3c fixes the problem!  Thanks! 

Reply all
Reply to author
Forward
0 new messages