Eratic code execution

N

Nick

I have a form with a subform. On the subform I have code behind a text box
to handle a double-click event. It's a simple OpenForm event that opens a
second form synchronized with the record on the subform that got the
double-click. Simple stuff. Done it a million times. Here's the code for
reference:


DoCmd.OpenForm "frmEditItem", acNormal, ,
"itemID=Forms!frmMain!frmCurrentListingsSub!itemID", acFormEdit,
acWindowNormal

Here's the problem. On my development machine I can't make the event work.
I move the .mdb to another machine and it works just fine. I've tested the
event "coded up" as a macro, too, and I get the same result. It utterly
fails on the dev machine, but works just fine when moved to a second box.
Incidentally, both machines are running Office 2003 Pro. Identical.

Any insights on what's going on here?

Thanks,
 
N

Nick

Sorry, but I don't fully understand the issue of "broken or missing
references on the dev machine." References at what level?

Thanks,




--------------------
| From: "Lynn Trapp" <[email protected]>
| References: <[email protected]>
| Subject: Re: Eratic code execution
| Date: Fri, 23 Apr 2004 13:22:07 -0500
| Lines: 36
| X-Priority: 3
| X-MSMail-Priority: Normal
| X-Newsreader: Microsoft Outlook Express 6.00.2800.1409
| X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2800.1409
| Message-ID: <[email protected]>
| Newsgroups: microsoft.public.access.formscoding
| NNTP-Posting-Host: 204.126.22.22
| Path:
cpmsftngxa10.phx.gbl!TK2MSFTFEED01.phx.gbl!TK2MSFTNGP08.phx.gbl!TK2MSFTNGP11
.phx.gbl
| Xref: cpmsftngxa10.phx.gbl microsoft.public.access.formscoding:229719
| X-Tomcat-NG: microsoft.public.access.formscoding
|
| Check to see if you have any broken or missing references on the dev
| machine.
|
| --
| Lynn Trapp
| MS Access MVP
| www.ltcomputerdesigns.com
| Access Security: www.ltcomputerdesigns.com/Security.htm
|
|
| | >
| > I have a form with a subform. On the subform I have code behind a text
box
| > to handle a double-click event. It's a simple OpenForm event that opens
a
| > second form synchronized with the record on the subform that got the
| > double-click. Simple stuff. Done it a million times. Here's the code for
| > reference:
| >
| >
| > DoCmd.OpenForm "frmEditItem", acNormal, ,
| > "itemID=Forms!frmMain!frmCurrentListingsSub!itemID", acFormEdit,
| > acWindowNormal
| >
| > Here's the problem. On my development machine I can't make the event
work.
| > I move the .mdb to another machine and it works just fine. I've tested
the
| > event "coded up" as a macro, too, and I get the same result. It utterly
| > fails on the dev machine, but works just fine when moved to a second
box.
| > Incidentally, both machines are running Office 2003 Pro. Identical.
| >
| > Any insights on what's going on here?
| >
| > Thanks,
| >
|
|
|
 
K

Kevin

Lynn was refering to the reference libraries access uses.
With any VBA code page open, chose References from the
Tools menu. If any references are missing, it will
say "MISSING" next to the appropriate reference. Look at
the list on both machines as well. If the dev machine does
not have one that the other one does, locate the file. You
should see the file path in the reference window(At the
bottom you should see Location. It will give you the full
file path. Find the file on the working machine and copy
it to the same location on the dev machine. Restart Access
after your done. If that's the problem, that should work.
 
N

Nick

Thanks for the feedback, Kevin (and sorry for the slow response).
Unfortunately, references was not the issue. Still investigating why code
executes on one machine and not another.


--------------------
| Content-Class: urn:content-classes:message
| From: "Kevin" <[email protected]>
| Sender: "Kevin" <[email protected]>
| References: <[email protected]>
<[email protected]>
<#[email protected]>
| Subject: Re: Eratic code execution
| Date: Fri, 23 Apr 2004 12:22:11 -0700
| Lines: 98
| Message-ID: <[email protected]>
| MIME-Version: 1.0
| Content-Type: text/plain;
| charset="iso-8859-1"
| Content-Transfer-Encoding: 7bit
| X-Newsreader: Microsoft CDO for Windows 2000
| thread-index: AcQpaEavJn003dR+TcCkWkdDpbwrzg==
| X-MimeOLE: Produced By Microsoft MimeOLE V5.50.4910.0300
| Newsgroups: microsoft.public.access.formscoding
| Path: cpmsftngxa10.phx.gbl
| Xref: cpmsftngxa10.phx.gbl microsoft.public.access.formscoding:229730
| NNTP-Posting-Host: tk2msftngxa14.phx.gbl 10.40.1.166
| X-Tomcat-NG: microsoft.public.access.formscoding
|
| Lynn was refering to the reference libraries access uses.
| With any VBA code page open, chose References from the
| Tools menu. If any references are missing, it will
| say "MISSING" next to the appropriate reference. Look at
| the list on both machines as well. If the dev machine does
| not have one that the other one does, locate the file. You
| should see the file path in the reference window(At the
| bottom you should see Location. It will give you the full
| file path. Find the file on the working machine and copy
| it to the same location on the dev machine. Restart Access
| after your done. If that's the problem, that should work.
| >-----Original Message-----
| >Sorry, but I don't fully understand the issue of "broken
| or missing
| >references on the dev machine." References at what level?
| >
| >Thanks,
| >
| >
| >
| >
| >--------------------
| >| From: "Lynn Trapp" <[email protected]>
| >| References: <[email protected]>
| >| Subject: Re: Eratic code execution
| >| Date: Fri, 23 Apr 2004 13:22:07 -0500
| >| Lines: 36
| >| X-Priority: 3
| >| X-MSMail-Priority: Normal
| >| X-Newsreader: Microsoft Outlook Express 6.00.2800.1409
| >| X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2800.1409
| >| Message-ID: <[email protected]>
| >| Newsgroups: microsoft.public.access.formscoding
| >| NNTP-Posting-Host: 204.126.22.22
| >| Path:
| >cpmsftngxa10.phx.gbl!TK2MSFTFEED01.phx.gbl!
| TK2MSFTNGP08.phx.gbl!TK2MSFTNGP11
| >.phx.gbl
| >| Xref: cpmsftngxa10.phx.gbl
| microsoft.public.access.formscoding:229719
| >| X-Tomcat-NG: microsoft.public.access.formscoding
| >|
| >| Check to see if you have any broken or missing
| references on the dev
| >| machine.
| >|
| >| --
| >| Lynn Trapp
| >| MS Access MVP
| >| www.ltcomputerdesigns.com
| >| Access Security: www.ltcomputerdesigns.com/Security.htm
| >|
| >|
| >| | >| >
| >| > I have a form with a subform. On the subform I have
| code behind a text
| >box
| >| > to handle a double-click event. It's a simple
| OpenForm event that opens
| >a
| >| > second form synchronized with the record on the
| subform that got the
| >| > double-click. Simple stuff. Done it a million times.
| Here's the code for
| >| > reference:
| >| >
| >| >
| >| > DoCmd.OpenForm "frmEditItem", acNormal, ,
| >| > "itemID=Forms!frmMain!frmCurrentListingsSub!itemID",
| acFormEdit,
| >| > acWindowNormal
| >| >
| >| > Here's the problem. On my development machine I can't
| make the event
| >work.
| >| > I move the .mdb to another machine and it works just
| fine. I've tested
| >the
| >| > event "coded up" as a macro, too, and I get the same
| result. It utterly
| >| > fails on the dev machine, but works just fine when
| moved to a second
| >box.
| >| > Incidentally, both machines are running Office 2003
| Pro. Identical.
| >| >
| >| > Any insights on what's going on here?
| >| >
| >| > Thanks,
| >| >
| >|
| >|
| >|
| >
| >.
| >
|
 

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. After that, you can post your question and our members will help you out.

Ask a Question

Top