Login | Register
My pages Projects Community openCollabNet

Discussions > users > Re: Access violation, when using TortoiseProc.exe to lock a file.

Project highlights: :. Download .: :. Support .: :. FAQ .: :. Translations .: :. Donate .: :. Report Bug .:

tortoisesvn
Discussion topic

Hide all messages in topic

All messages in topic

Re: Access violation, when using TortoiseProc.exe to lock a file.

Author jonathh
Full name Jon H
Date 2009-01-21 02:02:58 PST
Message Working Copy.

-----------------------
N: Jon Hardcastle
E: Jon at eHardcastle dot com
'..Be fearful when others are greedy, and be greedy when others are fearful.'
-----------------------


--- On Wed, 21/1/09, jerik <jerikmail@google​mail.com> wrote:

> From: jerik <jerikmail@google​mail.com>
> Subject: Re: Access violation, when using TortoiseProc.exe to lock a file.
> To: users at tortoisesvn dot tigris dot org
> Date: Wednesday, 21 January, 2009, 9:58 AM
> What das WC mean?
>
> The Term I have in mind does not fit in this context ;)
> (Water closet)
>
> Cheers -- Erik
>
> On 20 Jan., 18:31, Andy Levy <andy.l...@gmail.com>
> wrote:
> > On Tue, Jan 20, 2009 at 12:16, jerik
> <jerikm...@google​mail.com> wrote:
> > > This is not as easy as it looks. Here we have
> Tortoise v1.4.8
> > > installed. The command line client from collab
> was 1.5.x. worked fine,
> > > but afterwards I was not able to use the Tortoise
> client -- not good.
> >
> > Documented & expected behaviour. Newer clients
> silently &
> > automatically upgrade the WC format. I don't think
> you ever specified
> > that you were running an older release.
> >
> > > I could not find any command line client as zip
> file, so I took the
> > > collab once. Does somebody know where I can get
> command line tools
> > > that are compatible to Tortoise v1.4.8?
> >
> > Should be available somewhere on
> subversion.tigris.org. You'll have to
> > check out a new WC though.
> >
> >
> >
> > > Cheers -- Jerik
> >
> > > On 20 Jan., 14:43, Andy Levy
> <andy.l...@gmail.com> wrote:
> > >> On Tue, Jan 20, 2009 at 08:31, jerik
> <jerikm...@google​mail.com> wrote:
> > >> > hi,
> >
> > >> > On 20 Jan., 14:22, Andy Levy
> <andy.l...@gmail.com> wrote:
> > >> >> On Tue, Jan 20, 2009 at 08:13, jerik
> <jerikm...@google​mail.com> wrote:
> > >> >> > Hi,
> >
> > >> >> > OS: Windows
> >
> > >> >> > i wanted to make life easier
> and create a macro in word, which makes
> > >> >> > it possible to lock the word
> file which is currently open. The macro
> > >> >> > in word, calls:
> > >> >> >
> c:\path\TortoiseProc.exe /command:lock
> /path:"c:\path\file.doc"
> >
> > >> >> > Full macro code:
> > >> >> > Sub svn_lock()
> > >> >> >    ' In the Environment
> varibale svn_cmd is the path to
> > >> >> > TortoiseProc.exe stored!
> > >> >> >    svn_cmd =
> Environ$("svn_cmd")
> > >> >> >    svn_cmd_lock = svn_cmd
> & " /command:lock /path:" & Chr(34) &
> > >> >> > ActiveDocument.FullName &
> Chr(34)
> > >> >> >    Call Shell(svn_cmd_lock)
> > >> >> > End Sub
> >
> > >> >> > I receive the following error
> message (translated from german):
> > >> >> > An access violation has occured
> during the access of C:\path\file.doc
> >
> > >> >> > What should I do to avoid the
> Error message and get the macro to
> > >> >> > work?
> >
> > >> >> > If I use the same macro with
> the /command:log, it works perfectly. I
> > >> >> > think I have to free the
> document in a special way, but dont know
> > >> >> > how.
> >
> > >> >> > btw: vba skills novice.
> >
> > >> >> With the file open, run that same
> command at the command-line. Same result?
> >
> > >> > Same result !
> >
> > >> >> Then, install the Subversion
> command-line client and try using that
> > >> >> (the command-line client is meant to
> be scripted with no user
> > >> >> interaction, the TSVN command-line
> not so much).
> >
> > >> > Currently not an option, cause I have no
> admin rights on the pc.
> >
> > >> No, it's still an option. You can
> download the command-line tools as a
> > >> ZIP file and unpack to your home directory.
> >
> > >>
> --------------------​--------------------​--------------http://tortoisesvn.t​igris.org/ds/viewMes​sage.do?dsForumId=40​61&dsMess...
> >
> > >> To unsubscribe from this discussion, e-mail:
> [users-unsubscr...@t​ortoisesvn.tigris.or​g].
> >
> > >
> --------------------​--------------------​--------------
> >
> >http://tortoisesvn.t​igris.org/ds/viewMes​sage.do?dsForumId=40​61&dsMess...
> >
> > > To unsubscribe from this discussion, e-mail:
> [users-unsubscr...@t​ortoisesvn.tigris.or​g].
> >
> >
> --------------------​--------------------​--------------http://tortoisesvn.t​igris.org/ds/viewMes​sage.do?dsForumId=40​61&dsMess...
> >
> > To unsubscribe from this discussion, e-mail:
> [users-unsubscr...@t​ortoisesvn.tigris.or​g].
>
> --------------------​--------------------​--------------
> http://tortoisesvn.t​igris.org/ds/viewMes​sage.do?dsForumId=40​61&dsMessageId=1​040801
>
> To unsubscribe from this discussion, e-mail:
> [users-unsubscribe@t​ortoisesvn.tigris.or​g].

Re: Access violation, when using TortoiseProc.exe to lock a file.

Author jerik <jerikmail at googlemail dot com>
Full name jerik <jerikmail at googlemail dot com>
Date 2009-01-21 01:58:03 PST
Message What das WC mean?

The Term I have in mind does not fit in this context ;) (Water closet)

Cheers -- Erik

On 20 Jan., 18:31, Andy Levy <andy.l...@gmail.com> wrote:
> On Tue, Jan 20, 2009 at 12:16, jerik <jerikm...@google​mail.com> wrote:
> > This is not as easy as it looks. Here we have Tortoise v1.4.8
> > installed. The command line client from collab was 1.5.x. worked fine,
> > but afterwards I was not able to use the Tortoise client -- not good.
>
> Documented & expected behaviour. Newer clients silently &
> automatically upgrade the WC format. I don't think you ever specified
> that you were running an older release.
>
> > I could not find any command line client as zip file, so I took the
> > collab once. Does somebody know where I can get command line tools
> > that are compatible to Tortoise v1.4.8?
>
> Should be available somewhere on subversion.tigris.org. You'll have to
> check out a new WC though.
>
>
>
> > Cheers -- Jerik
>
> > On 20 Jan., 14:43, Andy Levy <andy.l...@gmail.com> wrote:
> >> On Tue, Jan 20, 2009 at 08:31, jerik <jerikm...@google​mail.com> wrote:
> >> > hi,
>
> >> > On 20 Jan., 14:22, Andy Levy <andy.l...@gmail.com> wrote:
> >> >> On Tue, Jan 20, 2009 at 08:13, jerik <jerikm...@google​mail.com> wrote:
> >> >> > Hi,
>
> >> >> > OS: Windows
>
> >> >> > i wanted to make life easier and create a macro in word, which makes
> >> >> > it possible to lock the word file which is currently open. The macro
> >> >> > in word, calls:
> >> >> > c:\path\TortoiseProc.exe /command:lock /path:"c:\path\file.doc"
>
> >> >> > Full macro code:
> >> >> > Sub svn_lock()
> >> >> >    ' In the Environment varibale svn_cmd is the path to
> >> >> > TortoiseProc.exe stored!
> >> >> >    svn_cmd = Environ$("svn_cmd")
> >> >> >    svn_cmd_lock = svn_cmd & " /command:lock /path:" & Chr(34) &
> >> >> > ActiveDocument.FullName & Chr(34)
> >> >> >    Call Shell(svn_cmd_lock)
> >> >> > End Sub
>
> >> >> > I receive the following error message (translated from german):
> >> >> > An access violation has occured during the access of C:\path\file.doc
>
> >> >> > What should I do to avoid the Error message and get the macro to
> >> >> > work?
>
> >> >> > If I use the same macro with the /command:log, it works perfectly. I
> >> >> > think I have to free the document in a special way, but dont know
> >> >> > how.
>
> >> >> > btw: vba skills novice.
>
> >> >> With the file open, run that same command at the command-line. Same result?
>
> >> > Same result !
>
> >> >> Then, install the Subversion command-line client and try using that
> >> >> (the command-line client is meant to be scripted with no user
> >> >> interaction, the TSVN command-line not so much).
>
> >> > Currently not an option, cause I have no admin rights on the pc.
>
> >> No, it's still an option. You can download the command-line tools as a
> >> ZIP file and unpack to your home directory.
>
> >> --------------------​--------------------​--------------http://tortoisesvn.t​igris.org/ds/viewMes​sage.do?dsForumId=40​61&dsMess...
>
> >> To unsubscribe from this discussion, e-mail: [users-unsubscr...@t​ortoisesvn.tigris.or​g].
>
> > --------------------​--------------------​--------------
> >http://tortoisesvn.t​igris.org/ds/viewMes​sage.do?dsForumId=40​61&dsMess...
>
> > To unsubscribe from this discussion, e-mail: [users-unsubscr...@t​ortoisesvn.tigris.or​g].
>
> --------------------​--------------------​--------------http://tortoisesvn.t​igris.org/ds/viewMes​sage.do?dsForumId=40​61&dsMess...
>
> To unsubscribe from this discussion, e-mail: [users-unsubscr...@t​ortoisesvn.tigris.or​g].

Re: Access violation, when using TortoiseProc.exe to lock a file.

Author Andy Levy <andy dot levy at gmail dot com>
Full name Andy Levy <andy dot levy at gmail dot com>
Date 2009-01-20 09:31:47 PST
Message On Tue, Jan 20, 2009 at 12:16, jerik <jerikmail@google​mail.com> wrote:
> This is not as easy as it looks. Here we have Tortoise v1.4.8
> installed. The command line client from collab was 1.5.x. worked fine,
> but afterwards I was not able to use the Tortoise client -- not good.

Documented & expected behaviour. Newer clients silently &
automatically upgrade the WC format. I don't think you ever specified
that you were running an older release.

> I could not find any command line client as zip file, so I took the
> collab once. Does somebody know where I can get command line tools
> that are compatible to Tortoise v1.4.8?

Should be available somewhere on subversion.tigris.org. You'll have to
check out a new WC though.

> Cheers -- Jerik
>
> On 20 Jan., 14:43, Andy Levy <andy.l...@gmail.com> wrote:
>> On Tue, Jan 20, 2009 at 08:31, jerik <jerikm...@google​mail.com> wrote:
>> > hi,
>>
>> > On 20 Jan., 14:22, Andy Levy <andy.l...@gmail.com> wrote:
>> >> On Tue, Jan 20, 2009 at 08:13, jerik <jerikm...@google​mail.com> wrote:
>> >> > Hi,
>>
>> >> > OS: Windows
>>
>> >> > i wanted to make life easier and create a macro in word, which makes
>> >> > it possible to lock the word file which is currently open. The macro
>> >> > in word, calls:
>> >> > c:\path\TortoiseProc.exe /command:lock /path:"c:\path\file.doc"
>>
>> >> > Full macro code:
>> >> > Sub svn_lock()
>> >> > ' In the Environment varibale svn_cmd is the path to
>> >> > TortoiseProc.exe stored!
>> >> > svn_cmd = Environ$("svn_cmd")
>> >> > svn_cmd_lock = svn_cmd & " /command:lock /path:" & Chr(34) &
>> >> > ActiveDocument.FullName & Chr(34)
>> >> > Call Shell(svn_cmd_lock)
>> >> > End Sub
>>
>> >> > I receive the following error message (translated from german):
>> >> > An access violation has occured during the access of C:\path\file.doc
>>
>> >> > What should I do to avoid the Error message and get the macro to
>> >> > work?
>>
>> >> > If I use the same macro with the /command:log, it works perfectly. I
>> >> > think I have to free the document in a special way, but dont know
>> >> > how.
>>
>> >> > btw: vba skills novice.
>>
>> >> With the file open, run that same command at the command-line. Same result?
>>
>> > Same result !
>>
>> >> Then, install the Subversion command-line client and try using that
>> >> (the command-line client is meant to be scripted with no user
>> >> interaction, the TSVN command-line not so much).
>>
>> > Currently not an option, cause I have no admin rights on the pc.
>>
>> No, it's still an option. You can download the command-line tools as a
>> ZIP file and unpack to your home directory.
>>
>> --------------------​--------------------​--------------http://tortoisesvn.t​igris.org/ds/viewMes​sage.do?dsForumId=40​61&dsMess...
>>
>> To unsubscribe from this discussion, e-mail: [users-unsubscr...@t​ortoisesvn.tigris.or​g].
>
> --------------------​--------------------​--------------
> http://tortoisesvn.t​igris.org/ds/viewMes​sage.do?dsForumId=40​61&dsMessageId=1​038448
>
> To unsubscribe from this discussion, e-mail: [users-unsubscribe@t​ortoisesvn.tigris.or​g].
>

Re: Access violation, when using TortoiseProc.exe to lock a file.

Author jerik <jerikmail at googlemail dot com>
Full name jerik <jerikmail at googlemail dot com>
Date 2009-01-20 09:16:49 PST
Message This is not as easy as it looks. Here we have Tortoise v1.4.8
installed. The command line client from collab was 1.5.x. worked fine,
but afterwards I was not able to use the Tortoise client -- not good.

I could not find any command line client as zip file, so I took the
collab once. Does somebody know where I can get command line tools
that are compatible to Tortoise v1.4.8?

Cheers -- Jerik

On 20 Jan., 14:43, Andy Levy <andy.l...@gmail.com> wrote:
> On Tue, Jan 20, 2009 at 08:31, jerik <jerikm...@google​mail.com> wrote:
> > hi,
>
> > On 20 Jan., 14:22, Andy Levy <andy.l...@gmail.com> wrote:
> >> On Tue, Jan 20, 2009 at 08:13, jerik <jerikm...@google​mail.com> wrote:
> >> > Hi,
>
> >> > OS: Windows
>
> >> > i wanted to make life easier and create a macro in word, which makes
> >> > it possible to lock the word file which is currently open. The macro
> >> > in word, calls:
> >> > c:\path\TortoiseProc.exe /command:lock /path:"c:\path\file.doc"
>
> >> > Full macro code:
> >> > Sub svn_lock()
> >> >    ' In the Environment varibale svn_cmd is the path to
> >> > TortoiseProc.exe stored!
> >> >    svn_cmd = Environ$("svn_cmd")
> >> >    svn_cmd_lock = svn_cmd & " /command:lock /path:" & Chr(34) &
> >> > ActiveDocument.FullName & Chr(34)
> >> >    Call Shell(svn_cmd_lock)
> >> > End Sub
>
> >> > I receive the following error message (translated from german):
> >> > An access violation has occured during the access of C:\path\file.doc
>
> >> > What should I do to avoid the Error message and get the macro to
> >> > work?
>
> >> > If I use the same macro with the /command:log, it works perfectly. I
> >> > think I have to free the document in a special way, but dont know
> >> > how.
>
> >> > btw: vba skills novice.
>
> >> With the file open, run that same command at the command-line. Same result?
>
> > Same result !
>
> >> Then, install the Subversion command-line client and try using that
> >> (the command-line client is meant to be scripted with no user
> >> interaction, the TSVN command-line not so much).
>
> > Currently not an option, cause I have no admin rights on the pc.
>
> No, it's still an option. You can download the command-line tools as a
> ZIP file and unpack to your home directory.
>
> --------------------​--------------------​--------------http://tortoisesvn.t​igris.org/ds/viewMes​sage.do?dsForumId=40​61&dsMess...
>
> To unsubscribe from this discussion, e-mail: [users-unsubscr...@t​ortoisesvn.tigris.or​g].

Re: Access violation, when using TortoiseProc.exe to lock a file.

Author jerik <jerikmail at googlemail dot com>
Full name jerik <jerikmail at googlemail dot com>
Date 2009-01-20 07:37:29 PST
Message Didn't know that. Will try it ;)
Thanks.

On 20 Jan., 14:43, Andy Levy <andy.l...@gmail.com> wrote:
> On Tue, Jan 20, 2009 at 08:31, jerik <jerikm...@google​mail.com> wrote:
> > hi,
>
> > On 20 Jan., 14:22, Andy Levy <andy.l...@gmail.com> wrote:
> >> On Tue, Jan 20, 2009 at 08:13, jerik <jerikm...@google​mail.com> wrote:
> >> > Hi,
>
> >> > OS: Windows
>
> >> > i wanted to make life easier and create a macro in word, which makes
> >> > it possible to lock the word file which is currently open. The macro
> >> > in word, calls:
> >> > c:\path\TortoiseProc.exe /command:lock /path:"c:\path\file.doc"
>
> >> > Full macro code:
> >> > Sub svn_lock()
> >> >    ' In the Environment varibale svn_cmd is the path to
> >> > TortoiseProc.exe stored!
> >> >    svn_cmd = Environ$("svn_cmd")
> >> >    svn_cmd_lock = svn_cmd & " /command:lock /path:" & Chr(34) &
> >> > ActiveDocument.FullName & Chr(34)
> >> >    Call Shell(svn_cmd_lock)
> >> > End Sub
>
> >> > I receive the following error message (translated from german):
> >> > An access violation has occured during the access of C:\path\file.doc
>
> >> > What should I do to avoid the Error message and get the macro to
> >> > work?
>
> >> > If I use the same macro with the /command:log, it works perfectly. I
> >> > think I have to free the document in a special way, but dont know
> >> > how.
>
> >> > btw: vba skills novice.
>
> >> With the file open, run that same command at the command-line. Same result?
>
> > Same result !
>
> >> Then, install the Subversion command-line client and try using that
> >> (the command-line client is meant to be scripted with no user
> >> interaction, the TSVN command-line not so much).
>
> > Currently not an option, cause I have no admin rights on the pc.
>
> No, it's still an option. You can download the command-line tools as a
> ZIP file and unpack to your home directory.
>
> --------------------​--------------------​--------------http://tortoisesvn.t​igris.org/ds/viewMes​sage.do?dsForumId=40​61&dsMess...
>
> To unsubscribe from this discussion, e-mail: [users-unsubscr...@t​ortoisesvn.tigris.or​g].

Re: Access violation, when using TortoiseProc.exe to lock a file.

Author kkolinko
Full name Konstantin Kolinko
Date 2009-01-20 07:14:04 PST
Message 2009/1/20 jerik <jerikmail@google​mail.com>:
> Hi,
>
> OS: Windows
>
> i wanted to make life easier and create a macro in word, which makes
> it possible to lock the word file which is currently open. The macro
> in word, calls:
> c:\path\TortoiseProc.exe /command:lock /path:"c:\path\file.doc"
>
> Full macro code:
> Sub svn_lock()
> ' In the Environment varibale svn_cmd is the path to
> TortoiseProc.exe stored!
> svn_cmd = Environ$("svn_cmd")
> svn_cmd_lock = svn_cmd & " /command:lock /path:" & Chr(34) &
> ActiveDocument.FullName & Chr(34)
> Call Shell(svn_cmd_lock)
> End Sub
>
> I receive the following error message (translated from german):
> An access violation has occured during the access of C:\path\file.doc
>
> What should I do to avoid the Error message and get the macro to
> work?
>
> If I use the same macro with the /command:log, it works perfectly. I
> think I have to free the document in a special way, but dont know
> how.
>
> btw: vba skills novice.
>
> Cheers -- Jerik
>

You cannot lock a file that is currently open. The reason is that
Subversion needs to change attributes of the file (remove the
read-only attribute), but it cannot access the file, because it is
already open by MS Word.

Thus the "Cannot access" message.

I think that this problem can be solved by closing and reopening the
document. I mean that the macro should do the following:

1. Get the path of the active document
2. Close the document
3. Run the lock command
4. Open the document

Also, the path to TortoiseProc can be read from the registry (look at
HKLM\Software\TortoiseSVN). Do not know about 64-bit versions, though.


Best regards,
Konstantin Kolinko

Re: Access violation, when using TortoiseProc.exe to lock a file.

Author Andy Levy <andy dot levy at gmail dot com>
Full name Andy Levy <andy dot levy at gmail dot com>
Date 2009-01-20 05:46:16 PST
Message On Tue, Jan 20, 2009 at 08:31, jerik <jerikmail@google​mail.com> wrote:
> hi,
>
> On 20 Jan., 14:22, Andy Levy <andy.l...@gmail.com> wrote:
>> On Tue, Jan 20, 2009 at 08:13, jerik <jerikm...@google​mail.com> wrote:
>> > Hi,
>>
>> > OS: Windows
>>
>> > i wanted to make life easier and create a macro in word, which makes
>> > it possible to lock the word file which is currently open. The macro
>> > in word, calls:
>> > c:\path\TortoiseProc.exe /command:lock /path:"c:\path\file.doc"
>>
>> > Full macro code:
>> > Sub svn_lock()
>> > ' In the Environment varibale svn_cmd is the path to
>> > TortoiseProc.exe stored!
>> > svn_cmd = Environ$("svn_cmd")
>> > svn_cmd_lock = svn_cmd & " /command:lock /path:" & Chr(34) &
>> > ActiveDocument.FullName & Chr(34)
>> > Call Shell(svn_cmd_lock)
>> > End Sub
>>
>> > I receive the following error message (translated from german):
>> > An access violation has occured during the access of C:\path\file.doc
>>
>> > What should I do to avoid the Error message and get the macro to
>> > work?
>>
>> > If I use the same macro with the /command:log, it works perfectly. I
>> > think I have to free the document in a special way, but dont know
>> > how.
>>
>> > btw: vba skills novice.
>>
>> With the file open, run that same command at the command-line. Same result?
>
> Same result !
>
>> Then, install the Subversion command-line client and try using that
>> (the command-line client is meant to be scripted with no user
>> interaction, the TSVN command-line not so much).
>
> Currently not an option, cause I have no admin rights on the pc.

No, it's still an option. You can download the command-line tools as a
ZIP file and unpack to your home directory.

Re: Access violation, when using TortoiseProc.exe to lock a file.

Author jerik <jerikmail at googlemail dot com>
Full name jerik <jerikmail at googlemail dot com>
Date 2009-01-20 05:31:35 PST
Message hi,

On 20 Jan., 14:22, Andy Levy <andy.l...@gmail.com> wrote:
> On Tue, Jan 20, 2009 at 08:13, jerik <jerikm...@google​mail.com> wrote:
> > Hi,
>
> > OS: Windows
>
> > i wanted to make life easier and create a macro in word, which makes
> > it possible to lock the word file which is currently open. The macro
> > in word, calls:
> > c:\path\TortoiseProc.exe /command:lock /path:"c:\path\file.doc"
>
> > Full macro code:
> > Sub svn_lock()
> >    ' In the Environment varibale svn_cmd is the path to
> > TortoiseProc.exe stored!
> >    svn_cmd = Environ$("svn_cmd")
> >    svn_cmd_lock = svn_cmd & " /command:lock /path:" & Chr(34) &
> > ActiveDocument.FullName & Chr(34)
> >    Call Shell(svn_cmd_lock)
> > End Sub
>
> > I receive the following error message (translated from german):
> > An access violation has occured during the access of C:\path\file.doc
>
> > What should I do to avoid the Error message and get the macro to
> > work?
>
> > If I use the same macro with the /command:log, it works perfectly. I
> > think I have to free the document in a special way, but dont know
> > how.
>
> > btw: vba skills novice.
>
> With the file open, run that same command at the command-line. Same result?

Same result !

> Then, install the Subversion command-line client and try using that
> (the command-line client is meant to be scripted with no user
> interaction, the TSVN command-line not so much).

Currently not an option, cause I have no admin rights on the pc.

Re: Access violation, when using TortoiseProc.exe to lock a file.

Author jonathh
Full name Jon H
Date 2009-01-20 05:29:46 PST
Message --- On Tue, 20/1/09, jerik <jerikmail@google​mail.com> wrote:

> From: jerik <jerikmail@google​mail.com>
> Subject: Access violation, when using TortoiseProc.exe to lock a file.
> To: users at tortoisesvn dot tigris dot org
> Date: Tuesday, 20 January, 2009, 1:13 PM
> Hi,
>
> OS: Windows
>
> i wanted to make life easier and create a macro in word,
> which makes
> it possible to lock the word file which is currently open.
> The macro
> in word, calls:
> c:\path\TortoiseProc.exe /command:lock
> /path:"c:\path\file.doc"
>
> Full macro code:
> Sub svn_lock()
> ' In the Environment varibale svn_cmd is the path
> to
> TortoiseProc.exe stored!
> svn_cmd = Environ$("svn_cmd")
> svn_cmd_lock = svn_cmd & " /command:lock
> /path:" & Chr(34) &
> ActiveDocument.FullName & Chr(34)
> Call Shell(svn_cmd_lock)
> End Sub
>
> I receive the following error message (translated from
> german):
> An access violation has occured during the access of
> C:\path\file.doc
>
> What should I do to avoid the Error message and get the
> macro to
> work?
>
> If I use the same macro with the /command:log, it works
> perfectly. I
> think I have to free the document in a special way, but
> dont know
> how.
>
> btw: vba skills novice.
>
> Cheers -- Jerik
>

Hi,

3 pence worth.. I am pretty sure i have stumbled on something that does a similar job. I think you can find it using 'svnword' in google.. i think it was a 'google summer of code' project...


-----------------------
N: Jon Hardcastle
E: Jon at eHardcastle dot com
'..Be fearful when others are greedy, and be greedy when others are fearful.'
-----------------------

Re: Access violation, when using TortoiseProc.exe to lock a file.

Author Kurt Pruenner <leak at gmx dot at>
Full name Kurt Pruenner <leak at gmx dot at>
Date 2009-01-20 05:24:37 PST
Message jerik wrote:
> I receive the following error message (translated from german):
> An access violation has occured during the access of C:\path\file.doc
>
> What should I do to avoid the Error message and get the macro to
> work?

I doubt there's much you can do - if you have a document open in Word
(unless it's open in read-only mode) it's opened exclusively, which
means that no other program (including TortoiseSVN) can access the file
until you close it in Word...

--
Kurt Bernhard Pruenner --- Haendelstrasse 17 --- 4020 Linz --- Austria
.......It might be written "Mindfuck", but it's spelt "L-A-I-N".......

Re: Access violation, when using TortoiseProc.exe to lock a file.

Author Andy Levy <andy dot levy at gmail dot com>
Full name Andy Levy <andy dot levy at gmail dot com>
Date 2009-01-20 05:22:40 PST
Message On Tue, Jan 20, 2009 at 08:13, jerik <jerikmail@google​mail.com> wrote:
> Hi,
>
> OS: Windows
>
> i wanted to make life easier and create a macro in word, which makes
> it possible to lock the word file which is currently open. The macro
> in word, calls:
> c:\path\TortoiseProc.exe /command:lock /path:"c:\path\file.doc"
>
> Full macro code:
> Sub svn_lock()
> ' In the Environment varibale svn_cmd is the path to
> TortoiseProc.exe stored!
> svn_cmd = Environ$("svn_cmd")
> svn_cmd_lock = svn_cmd & " /command:lock /path:" & Chr(34) &
> ActiveDocument.FullName & Chr(34)
> Call Shell(svn_cmd_lock)
> End Sub
>
> I receive the following error message (translated from german):
> An access violation has occured during the access of C:\path\file.doc
>
> What should I do to avoid the Error message and get the macro to
> work?
>
> If I use the same macro with the /command:log, it works perfectly. I
> think I have to free the document in a special way, but dont know
> how.
>
> btw: vba skills novice.

With the file open, run that same command at the command-line. Same result?

Then, install the Subversion command-line client and try using that
(the command-line client is meant to be scripted with no user
interaction, the TSVN command-line not so much).

Access violation, when using TortoiseProc.exe to lock a file.

Author jerik <jerikmail at googlemail dot com>
Full name jerik <jerikmail at googlemail dot com>
Date 2009-01-20 05:13:39 PST
Message Hi,

OS: Windows

i wanted to make life easier and create a macro in word, which makes
it possible to lock the word file which is currently open. The macro
in word, calls:
c:\path\TortoiseProc.exe /command:lock /path:"c:\path\file.doc"

Full macro code:
Sub svn_lock()
    ' In the Environment varibale svn_cmd is the path to
TortoiseProc.exe stored!
    svn_cmd = Environ$("svn_cmd")
    svn_cmd_lock = svn_cmd & " /command:lock /path:" & Chr(34) &
ActiveDocument.FullName & Chr(34)
    Call Shell(svn_cmd_lock)
End Sub

I receive the following error message (translated from german):
An access violation has occured during the access of C:\path\file.doc

What should I do to avoid the Error message and get the macro to
work?

If I use the same macro with the /command:log, it works perfectly. I
think I have to free the document in a special way, but dont know
how.

btw: vba skills novice.

Cheers -- Jerik
Messages per page: