Error comparing files / Word 2013

745 views
Skip to first unread message

Galin Gichev

unread,
Nov 22, 2012, 3:51:50 AM11/22/12
to us...@tortoisesvn.tigris.org
I am attempting to get started with tortoise svn. I am using
Microsoft Office 2013 on Windows 7 computer.

I have made a repository. I've checked out of my WORD document and
made changes. Now I wish to check the difference. When I try to do it,
I get a popup errorbox saying Error comparing file1 and file2. It
attempts to open the Word file, but it doesn't, i.e. Word starts, but
it doesn't load the file.

Somebody must have had similar difficulties before me. I have run out
of things to try. Does anyone have any idea what is the cause of this
problem?

Thank you in advance,
Galin Gicheff

------------------------------------------------------
http://tortoisesvn.tigris.org/ds/viewMessage.do?dsForumId=4061&dsMessageId=3030156

To unsubscribe from this discussion, e-mail: [users-un...@tortoisesvn.tigris.org].

Moshe Katz

unread,
Dec 19, 2012, 4:42:46 PM12/19/12
to us...@tortoisesvn.tigris.org
I have had the same problem since I installed Office 2013.

The Word comparison is done using a JScript file executed by the Windows Scripting Host. I opened the script in a debugger to get the real error:

> The Compare method or property is not available because this command is not available for reading.

I looked up the error and found similar errors discussed all over by other people using scripts to interact with Word.

I am looking for a solution, but I have not yet found one.

------------------------------------------------------
http://tortoisesvn.tigris.org/ds/viewMessage.do?dsForumId=4061&dsMessageId=3037382

Moshe Katz

unread,
Dec 19, 2012, 5:26:53 PM12/19/12
to us...@tortoisesvn.tigris.org
I did some testing and found the reason:

The comparison script forces the files to open in Read-Only mode. Word 2013 no longer allows you to compare files that are Read-Only.

When I edited the script to tell it to open the files normally and I made sure that the temporary file for the old version was not marked Read-Only on disk, then the comparison worked.

I can find no documentation on whether this behavior is intentional or not on Microsoft's site. I may have a contact at Microsoft who I can ask.

------------------------------------------------------
http://tortoisesvn.tigris.org/ds/viewMessage.do?dsForumId=4061&dsMessageId=3037388

Simon Large

unread,
Dec 20, 2012, 4:38:46 AM12/20/12
to us...@tortoisesvn.tigris.org
On 19 December 2012 22:26, Moshe Katz <kohe...@gmail.com> wrote:
> I did some testing and found the reason:
>
> The comparison script forces the files to open in Read-Only mode. Word 2013 no longer allows you to compare files that are Read-Only.
>
> When I edited the script to tell it to open the files normally and I made sure that the temporary file for the old version was not marked Read-Only on disk, then the comparison worked.
>
> I can find no documentation on whether this behavior is intentional or not on Microsoft's site. I may have a contact at Microsoft who I can ask.

Thanks for digging into this Moshe, please keep us updated with what
you find out.

Thanks,

Simon

--
: ___
: oo // \\ "De Chelonian Mobile"
: (_,\/ \_/ \ TortoiseSVN
: \ \_/_\_/> The coolest Interface to (Sub)Version Control
: /_/ \_\ http://tortoisesvn.net

------------------------------------------------------
http://tortoisesvn.tigris.org/ds/viewMessage.do?dsForumId=4061&dsMessageId=3037568

Moshe Katz

unread,
Jan 13, 2013, 8:03:33 PM1/13/13
to us...@tortoisesvn.tigris.org
I haven't found anything new, but several people have asked me what they need to change in the compare script.

In diff-doc.js on line 134 (see http://code.google.com/p/tortoisesvn/source/browse/trunk/contrib/diff-scripts/diff-doc.js#134), you need to change the second `true` to `false`. See the Microsoft documentation here: http://msdn.microsoft.com/en-us/library/ff835182.aspx . (It also needs to be changed a few lines below that.)

However, just as important, you need to make sure that the file's properties on disk (i.e. right-click and click "properties") do not say read-only. There may be an issue with this if your files are read-only on purpose, but I didn't have that issue myself.

I have no word back from Microsoft yet about whether this is by design.

------------------------------------------------------
http://tortoisesvn.tigris.org/ds/viewMessage.do?dsForumId=4061&dsMessageId=3043194

Ben Fritz

unread,
Jan 14, 2013, 10:58:42 AM1/14/13
to us...@tortoisesvn.tigris.org
On Sun, Jan 13, 2013 at 7:03 PM, Moshe Katz <kohe...@gmail.com> wrote:
>
> However, just as important, you need to make sure that the file's properties on disk (i.e. right-click and click "properties") do not say read-only. There may be an issue with this if your files are read-only on purpose, but I didn't have that issue myself.
>

So is this going to cause problems if the svn:needs-lock property is
set on Word document files, so that SVN automatically sets them as
readonly?

------------------------------------------------------
http://tortoisesvn.tigris.org/ds/viewMessage.do?dsForumId=4061&dsMessageId=3043362

Stefan Küng

unread,
Jan 14, 2013, 2:14:32 PM1/14/13
to us...@tortoisesvn.tigris.org
On 14.01.2013 16:58, Ben Fritz wrote:
> On Sun, Jan 13, 2013 at 7:03 PM, Moshe Katz <kohe...@gmail.com> wrote:
>>
>> However, just as important, you need to make sure that the file's properties on disk (i.e. right-click and click "properties") do not say read-only. There may be an issue with this if your files are read-only on purpose, but I didn't have that issue myself.
>>
>
> So is this going to cause problems if the svn:needs-lock property is
> set on Word document files, so that SVN automatically sets them as
> readonly?

No, that file attribute is reset by the script.

Try the attached script (don't have office 2013 installed to test myself).

Stefan

--
___
oo // \\ "De Chelonian Mobile"
(_,\/ \_/ \ TortoiseSVN
\ \_/_\_/> The coolest interface to (Sub)version control
/_/ \_\ http://tortoisesvn.net

------------------------------------------------------
http://tortoisesvn.tigris.org/ds/viewMessage.do?dsForumId=4061&dsMessageId=3043408
diff-doc.zip

Dau Nugmanov

unread,
Mar 4, 2013, 5:21:50 AM3/4/13
to us...@tortoisesvn.tigris.org, Stefan Küng
Don't want to create new discussion.
Had same problems with Word 2013.
By default my instance of ms word opens in wdReadingView
(destination.ActiveWindow.View.Type == 7)

Adding to diff-doc.js:
Line31: var wdReadingView = 7;
Line144: || (destination.ActiveWindow.View.Type == wdReadingView)) && (destination.Subdocuments.Count == 0))

solved my problems.
Maybe such fix needs diff-ppt.js and diff-xls.vbs

------------------------------------------------------
http://tortoisesvn.tigris.org/ds/viewMessage.do?dsForumId=4061&dsMessageId=3050255
diff-doc.zip

Steve Romanow

unread,
Oct 14, 2013, 2:34:11 PM10/14/13
to us...@tortoisesvn.tigris.org
I see that Dau has a fix for the "default Reading Mode" error. I have added this to my current 1.8.2 tortoise and it works for me.

I looked at trunk and it looks like this was not submitted to the issue tracker for inclusion.

Attached is a patch against trunk. I will file an issue in the tracker if it looks like a change that will be desired.

------------------------------------------------------
http://tortoisesvn.tigris.org/ds/viewMessage.do?dsForumId=4061&dsMessageId=3066315
diff-doc.patch

Stefan Küng

unread,
Oct 14, 2013, 3:13:54 PM10/14/13
to us...@tortoisesvn.tigris.org
On 14.10.2013 20:34, Steve Romanow wrote:
> I see that Dau has a fix for the "default Reading Mode" error. I have added this to my current 1.8.2 tortoise and it works for me.
>
> I looked at trunk and it looks like this was not submitted to the issue tracker for inclusion.
>
> Attached is a patch against trunk. I will file an issue in the tracker if it looks like a change that will be desired.

Committed your patch in r24845

Stefan

--
___
oo // \\ "De Chelonian Mobile"
(_,\/ \_/ \ TortoiseSVN
\ \_/_\_/> The coolest interface to (Sub)version control
/_/ \_\ http://tortoisesvn.net

------------------------------------------------------
http://tortoisesvn.tigris.org/ds/viewMessage.do?dsForumId=4061&dsMessageId=3066318

wumudy

unread,
May 7, 2014, 11:22:08 PM5/7/14
to us...@tortoisesvn.tigris.org
Thanks a lot for you solution, which fixed my trouble on below TortoiseSVN
platform.

TortoiseSVN 1.7.12, Build 24070 - 64 Bit , 2013/03/29 08:00:43
Subversion 1.7.9,
apr 1.4.6
apr-utils 1.3.12
neon 0.29.6
OpenSSL 1.0.1e 11 Feb 2013
zlib 1.2.7



--
View this message in context: http://tigris-scm.10930.n7.nabble.com/Error-comparing-files-Word-2013-tp34229p96726.html
Sent from the tortoisesvn - users mailing list archive at Nabble.com.

------------------------------------------------------
http://tortoisesvn.tigris.org/ds/viewMessage.do?dsForumId=4061&dsMessageId=3077804
Reply all
Reply to author
Forward
0 new messages