?
Solved

Run-time error 2683

Posted on 2006-11-14
12
Medium Priority
?
2,582 Views
Last Modified: 2008-02-26
I have an Access 97 polling database that I split and made changes to.  It all seems to work fine from my PC which has the entire access package loaded.  However any pc with the run-time version is giving me the following errors when I try to poll.  I can view things and run reports, just not poll on the run-time PC's.  Any suggestions?
Run-time error 2683
Execution of this application has stopped due to run-time error
Field lock Trans.Patron can't be zero length string.
Index on primary key can't contain null value.
0
Comment
Question by:BobRosas
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 6
  • 2
  • 2
  • +1
12 Comments
 
LVL 7

Expert Comment

by:Imoutwest
ID: 17939225
Error 2683 - There is no object in this control.

Seems that you have created an index on a field/control that has empty data in that control.

Open your backend and look at your table and see if this is true and correct the Null values.
0
 

Author Comment

by:BobRosas
ID: 17939401
I only changed two tables and can't find a problem in either one but I'll keep looking.  However, I forgot something else important.  The database I split was polling and working daily before I split it.  After I split it I added my front end with the new code to the old backend with the current data.  Because of that I noticed that the references didn't match so I fixed that but I'm still getting the same errors.

I did add several new fields in my code but I also updated the split backend with those fields and populated them with zeros.
0
 
LVL 7

Expert Comment

by:Imoutwest
ID: 17939487
Front-End is your queries, forms, reports, etc.?
Back_End is just your tables?

Is it possible that the tables are not linked correctly between the backend and front end? Re-Link or delete the linked table in your front-end and then re-link the table from scratch. Other than that this is beyond my experience, hopefully one-of the experts will jump in. Sorry I couldn't help more, Imoutwest
0
Get your Disaster Recovery as a Service basics

Disaster Recovery as a Service is one go-to solution that revolutionizes DR planning. Implementing DRaaS could be an efficient process, easily accessible to non-DR experts. Learn about monitoring, testing, executing failovers and failbacks to ensure a "healthy" DR environment.

 
LVL 65

Expert Comment

by:rockiroads
ID: 17939488
to me this message

Field lock Trans.Patron can't be zero length string.

is saying that the field Patron in the table  lock Trans  has the setting of Allow Zero Length to False (open up table in design view in backend)
If u set this to True, what happens?

this is also what Imoutwest has said
0
 
LVL 65

Expert Comment

by:rockiroads
ID: 17939496
If u change the table definition, check the frontend, though u cant make changes u can see the field properties. U may need to relink this table
0
 
LVL 54

Accepted Solution

by:
nico5038 earned 2000 total points
ID: 17939551
Hmm, did you check the references on those other PC's ?

Add this (slightly modified) function cactus_data wrote and activate it from e.g. an additional button:

Public Function ReferencesClean() As Boolean

' Remove all missing references.
' Return True if no reference was broken.
'
' 2001-08-20. Cactus Data ApS, CPH.

  Dim ref         As Reference
  Dim lngItem     As Long
  Dim booMissing  As Boolean
 
  With References
    For lngItem = .Count To 1 Step -1
      Set ref = .Item(lngItem)
      If ref.BuiltIn = True Then
        ' No need to check built in reference.
      ElseIf ref.IsBroken Then
         MsgBox "Missing ref: " & ref.Name
      End If
    Next
  End With
 
  Set ref = Nothing
 
  ReferencesClean = Not booMissing
 
End Function


Also make sure no code is executed before this.

Nic;o)
0
 

Author Comment

by:BobRosas
ID: 17939705
The code did not find any missing references.  

I would like to add that I was mistaken in saying all the full versions work.  It appears only mine is working.  When I tried the code on another full version machine I got...
Run-time error '-2147024890(80070006)' Method 'WriteString' of object 'lPortCtl' failed
Debug goes to the code
Sub SendMsg(PXstr As String)
    InfoMsg "Send: " & StrDump(PXstr)
      PortObj.WriteString PXstr
End Sub
FYI - This is not my program.  I've only made a few changes.  I'm trying to go thru the code now and figure out where 'WriteString' comes from.
0
 

Author Comment

by:BobRosas
ID: 17939760
rockiroads
I didn't see your comments earlier.  I am checking that out as well.
Thanks
0
 

Author Comment

by:BobRosas
ID: 17940302
rockiroads
I tried changing Allow zero Length to true and it didn't make any difference.
I also tried re-linking all the tables, nothing there either.
followed by
Run-time error '-2147024890(80070006)' Method 'WriteString' of object 'lPortCtl' failed
Debug goes to the code
Sub SendMsg(PXstr As String)
    InfoMsg "Send: " & StrDump(PXstr)
      PortObj.WriteString PXstr
End Sub
0
 

Author Comment

by:BobRosas
ID: 17940801
I just found that in the above code PXstr = AT&F in both machines but in my machine it is followed with a box for the carriage and in one of the PC's not working it's a vertical solid bar.  Could that be the problem?   Is there a way to change the bar to a box?
0
 

Author Comment

by:BobRosas
ID: 17941804
I think the references fixed it.  What happened is the software for the modem on the machine I was testing wasn't working.  The other run-time machines work fine now.
Thanks
0
 
LVL 54

Expert Comment

by:nico5038
ID: 17941985
Glad it's solved, success with the application !

Nic;o)
0

Featured Post

Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Access custom database properties are useful for storing miscellaneous bits of information in a format that persists through database closing and reopening.  This article shows how to create and use them.
Traditionally, the method to display pictures in Access forms and reports is to first download them from URLs to a folder, record the path in a table and then let the form or report pull the pictures from that folder. But why not let Windows retr…
Get people started with the utilization of class modules. Class modules can be a powerful tool in Microsoft Access. They allow you to create self-contained objects that encapsulate functionality. They can easily hide the complexity of a process from…
In Microsoft Access, when working with VBA, learn some techniques for writing readable and easily maintained code.
Suggested Courses

762 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question