I've got a .dot file on a pc here at the office that is used via Word (i.e.
File | New ) to create a document based upon some data in an access database
located on a network share that all PCs have a drive mapped to. The
original developer is no longer here and I'm trying to move that .dot file
to another PC so the user there can use it. So, I copied the .dot file to
the same templates folder on the other PC. When I run the code, I get an
error that the "Object doesn't support this property of method".

I click the debug button and an instance of the VB editor launches and I see
that the problem is in a call to WordBasic.Call. The problem is the first
parameter. It is referencing a procedure in a module in argument is in the
form of "mymod.someprocedure$". I know this is something that we coded
in-house because of the name of mymod and the context of the call (it's
calculating something specific to our business).

I assume the file, etc. that contains the code that WordBasic.Call is trying
to call is on the old PC, but I just don't know what I should be looking
for. So, what I'm trying to figure out is, in the VBA world, what form does
a "module" take and how is it referenced by the vba code and/or the .dot
file. Any help I could get to make this .dot work on the other PC would be
much appreciated.

Thanks!

Re: WordBasic.Call to function in a module? by Jonathan

Jonathan
Fri Jan 07 15:59:50 CST 2005

Hi epigram

I suspect that you have bitten off more than you can chew here. If you're
unfamiliar with VBA, unfamiliar with this specific application, and have
found it's broken, then its going to be a long hard job to put the pieces
back together again. We can try & help a bit with answers here, but
ultimately you may need to pay a professional to come in and sort things out
for you.

But to answer your specific question, if you open the template and then
press Alt-F11 to open the VBA editor, you will see the modules of the
project that is in the template. Click on any of the modules in the project
window in order to see the code. Unless of course the code is password
protected, in which case you are stuck unless you can find the password or a
password cracker.


--
Regards
Jonathan West - Word MVP
www.intelligentdocuments.co.uk
Please reply to the newsgroup


"epigram" <nospam@spammy.com> wrote in message
news:1105129855.52666a4f59da8845b44884674266b9b0@bubbanews...
> I've got a .dot file on a pc here at the office that is used via Word
> (i.e. File | New ) to create a document based upon some data in an access
> database located on a network share that all PCs have a drive mapped to.
> The original developer is no longer here and I'm trying to move that .dot
> file to another PC so the user there can use it. So, I copied the .dot
> file to the same templates folder on the other PC. When I run the code, I
> get an error that the "Object doesn't support this property of method".
>
> I click the debug button and an instance of the VB editor launches and I
> see that the problem is in a call to WordBasic.Call. The problem is the
> first parameter. It is referencing a procedure in a module in argument is
> in the form of "mymod.someprocedure$". I know this is something that we
> coded in-house because of the name of mymod and the context of the call
> (it's calculating something specific to our business).
>
> I assume the file, etc. that contains the code that WordBasic.Call is
> trying to call is on the old PC, but I just don't know what I should be
> looking for. So, what I'm trying to figure out is, in the VBA world, what
> form does a "module" take and how is it referenced by the vba code and/or
> the .dot file. Any help I could get to make this .dot work on the other
> PC would be much appreciated.
>
> Thanks!
>


Re: WordBasic.Call to function in a module? by Howard

Howard
Fri Jan 07 16:10:48 CST 2005

To help you with WordBasic to VBA perversion, ooops, I mean conversion, take
a look at

http://www.standards.com/index.html?WordBasic2VBA
http://www.standards.com/index.html?WordBasicBrokenInVBA

--
http://www.standards.com/; See Howard Kaikow's web site.
"epigram" <nospam@spammy.com> wrote in message
news:1105129855.52666a4f59da8845b44884674266b9b0@bubbanews...
> I've got a .dot file on a pc here at the office that is used via Word
(i.e.
> File | New ) to create a document based upon some data in an access
database
> located on a network share that all PCs have a drive mapped to. The
> original developer is no longer here and I'm trying to move that .dot file
> to another PC so the user there can use it. So, I copied the .dot file to
> the same templates folder on the other PC. When I run the code, I get an
> error that the "Object doesn't support this property of method".
>
> I click the debug button and an instance of the VB editor launches and I
see
> that the problem is in a call to WordBasic.Call. The problem is the first
> parameter. It is referencing a procedure in a module in argument is in
the
> form of "mymod.someprocedure$". I know this is something that we coded
> in-house because of the name of mymod and the context of the call (it's
> calculating something specific to our business).
>
> I assume the file, etc. that contains the code that WordBasic.Call is
trying
> to call is on the old PC, but I just don't know what I should be looking
> for. So, what I'm trying to figure out is, in the VBA world, what form
does
> a "module" take and how is it referenced by the vba code and/or the .dot
> file. Any help I could get to make this .dot work on the other PC would
be
> much appreciated.
>
> Thanks!
>
>



Re: WordBasic.Call to function in a module? by epigram

epigram
Sat Jan 08 13:22:50 CST 2005

Hi Jonathan,

Thanks for the reply. I followed your instructions to open the VBA editor.
This gives me the same view as I get when I go into debug after my app runs
into the problem I described earlier. There is only one module called
AutoNew. It has several functions including the line of code where the app
is failing. It also has several calls to WordBasic.Dialog.UserDialog().
Each of these calls references, what I assume are custom-created dialogs.
These calls are successful because the dialogs are appearing. (BTW, are
these dialogs part of the template too?) I can see how the code starts in
the function called MAIN, and then another sub is called that contains the
line that fails.

What I'm really trying to figure out is how can a call to WordBasic.Call be
resolved if the procedure being invoked is custom-written code? Like I said
earlier, the first param of the Call method is of the form
"mymod.someprocedure$". So, if I don't see this module in the VBA editor
then where could it be located? I know the person who wrote this would have
done it in VB/VBA.

I haven't tried opening the template on the PC it is working to see if there
are any other modules listed there that aren't being listed on my PC because
they can't be located. I also didn't look to see if there is a reference
listed by the VBA editor that isn't on my PC. I'll try that next. Any
other suggestions would be greatly appreciated.

Thanks!



"Jonathan West" <jwest@mvps.org> wrote in message
news:%23FGSORQ9EHA.1400@TK2MSFTNGP11.phx.gbl...
> Hi epigram
>
> I suspect that you have bitten off more than you can chew here. If you're
> unfamiliar with VBA, unfamiliar with this specific application, and have
> found it's broken, then its going to be a long hard job to put the pieces
> back together again. We can try & help a bit with answers here, but
> ultimately you may need to pay a professional to come in and sort things
out
> for you.
>
> But to answer your specific question, if you open the template and then
> press Alt-F11 to open the VBA editor, you will see the modules of the
> project that is in the template. Click on any of the modules in the
project
> window in order to see the code. Unless of course the code is password
> protected, in which case you are stuck unless you can find the password or
a
> password cracker.
>
>
> --
> Regards
> Jonathan West - Word MVP
> www.intelligentdocuments.co.uk
> Please reply to the newsgroup
>
>
> "epigram" <nospam@spammy.com> wrote in message
> news:1105129855.52666a4f59da8845b44884674266b9b0@bubbanews...
> > I've got a .dot file on a pc here at the office that is used via Word
> > (i.e. File | New ) to create a document based upon some data in an
access
> > database located on a network share that all PCs have a drive mapped to.
> > The original developer is no longer here and I'm trying to move that
.dot
> > file to another PC so the user there can use it. So, I copied the .dot
> > file to the same templates folder on the other PC. When I run the code,
I
> > get an error that the "Object doesn't support this property of method".
> >
> > I click the debug button and an instance of the VB editor launches and I
> > see that the problem is in a call to WordBasic.Call. The problem is the
> > first parameter. It is referencing a procedure in a module in argument
is
> > in the form of "mymod.someprocedure$". I know this is something that we
> > coded in-house because of the name of mymod and the context of the call
> > (it's calculating something specific to our business).
> >
> > I assume the file, etc. that contains the code that WordBasic.Call is
> > trying to call is on the old PC, but I just don't know what I should be
> > looking for. So, what I'm trying to figure out is, in the VBA world,
what
> > form does a "module" take and how is it referenced by the vba code
and/or
> > the .dot file. Any help I could get to make this .dot work on the other
> > PC would be much appreciated.
> >
> > Thanks!
> >
>



Re: WordBasic.Call to function in a module? by epigram

epigram
Mon Jan 10 19:06:35 CST 2005

OK. I opened the template file on the original PC and launched the VBA
editor. The project on this PC contains a folder under the Normal "node"
called Modules and there are two modules in it. I can open these two
modules and view their code.

There are also three more TemplateProject "nodes". The code that is failing
must be in one of these TemplateProjects because the name of one of them
corresponds to the WordBasic.Call method call that is failing. The odd
thing is when I try to expand any of these TemplateProject nodes I get a
dialog box that reads "Project is unviewable".

So, there are either some files and/or environment settings that are
different on this PC that I need to recreate on my PC. Any help would be
much appreciated.

Thanks!


"epigram" <nospam@nospammy.com> wrote in message
news:1105212170.a2d0cac675fe6196732ccc912c4cf190@bubbanews...
> Hi Jonathan,
>
> Thanks for the reply. I followed your instructions to open the VBA
> editor.
> This gives me the same view as I get when I go into debug after my app
> runs
> into the problem I described earlier. There is only one module called
> AutoNew. It has several functions including the line of code where the
> app
> is failing. It also has several calls to WordBasic.Dialog.UserDialog().
> Each of these calls references, what I assume are custom-created dialogs.
> These calls are successful because the dialogs are appearing. (BTW, are
> these dialogs part of the template too?) I can see how the code starts in
> the function called MAIN, and then another sub is called that contains the
> line that fails.
>
> What I'm really trying to figure out is how can a call to WordBasic.Call
> be
> resolved if the procedure being invoked is custom-written code? Like I
> said
> earlier, the first param of the Call method is of the form
> "mymod.someprocedure$". So, if I don't see this module in the VBA editor
> then where could it be located? I know the person who wrote this would
> have
> done it in VB/VBA.
>
> I haven't tried opening the template on the PC it is working to see if
> there
> are any other modules listed there that aren't being listed on my PC
> because
> they can't be located. I also didn't look to see if there is a reference
> listed by the VBA editor that isn't on my PC. I'll try that next. Any
> other suggestions would be greatly appreciated.
>
> Thanks!
>
>
>
> "Jonathan West" <jwest@mvps.org> wrote in message
> news:%23FGSORQ9EHA.1400@TK2MSFTNGP11.phx.gbl...
>> Hi epigram
>>
>> I suspect that you have bitten off more than you can chew here. If you're
>> unfamiliar with VBA, unfamiliar with this specific application, and have
>> found it's broken, then its going to be a long hard job to put the pieces
>> back together again. We can try & help a bit with answers here, but
>> ultimately you may need to pay a professional to come in and sort things
> out
>> for you.
>>
>> But to answer your specific question, if you open the template and then
>> press Alt-F11 to open the VBA editor, you will see the modules of the
>> project that is in the template. Click on any of the modules in the
> project
>> window in order to see the code. Unless of course the code is password
>> protected, in which case you are stuck unless you can find the password
>> or
> a
>> password cracker.
>>
>>
>> --
>> Regards
>> Jonathan West - Word MVP
>> www.intelligentdocuments.co.uk
>> Please reply to the newsgroup
>>
>>
>> "epigram" <nospam@spammy.com> wrote in message
>> news:1105129855.52666a4f59da8845b44884674266b9b0@bubbanews...
>> > I've got a .dot file on a pc here at the office that is used via Word
>> > (i.e. File | New ) to create a document based upon some data in an
> access
>> > database located on a network share that all PCs have a drive mapped
>> > to.
>> > The original developer is no longer here and I'm trying to move that
> .dot
>> > file to another PC so the user there can use it. So, I copied the .dot
>> > file to the same templates folder on the other PC. When I run the
>> > code,
> I
>> > get an error that the "Object doesn't support this property of method".
>> >
>> > I click the debug button and an instance of the VB editor launches and
>> > I
>> > see that the problem is in a call to WordBasic.Call. The problem is
>> > the
>> > first parameter. It is referencing a procedure in a module in argument
> is
>> > in the form of "mymod.someprocedure$". I know this is something that
>> > we
>> > coded in-house because of the name of mymod and the context of the call
>> > (it's calculating something specific to our business).
>> >
>> > I assume the file, etc. that contains the code that WordBasic.Call is
>> > trying to call is on the old PC, but I just don't know what I should be
>> > looking for. So, what I'm trying to figure out is, in the VBA world,
> what
>> > form does a "module" take and how is it referenced by the vba code
> and/or
>> > the .dot file. Any help I could get to make this .dot work on the
>> > other
>> > PC would be much appreciated.
>> >
>> > Thanks!
>> >
>>
>
>