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
Solved

Run-time error 2683

Posted on 2006-11-14
12
2,576 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
  • 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
Simplifying Server Workload Migrations

This use case outlines the migration challenges that organizations face and how the Acronis AnyData Engine supports physical-to-physical (P2P), physical-to-virtual (P2V), virtual to physical (V2P), and cross-virtual (V2V) migration scenarios to address these challenges.

 
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 500 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

Comprehensive Backup Solutions for Microsoft

Acronis protects the complete Microsoft technology stack: Windows Server, Windows PC, laptop and Surface data; Microsoft business applications; Microsoft Hyper-V; Azure VMs; Microsoft Windows Server 2016; Microsoft Exchange 2016 and SQL Server 2016.

Question has a verified solution.

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

Regardless of which version on MS Access you are using, one of the harder data-entry forms to create is one where most data from previous entries needs to be appended to new records, especially when there are numerous fields and records involved.  W…
Phishing attempts can come in all forms, shapes and sizes. No matter how familiar you think you are with them, always remember to take extra precaution when opening an email with attachments or links.
In Microsoft Access, learn the trick to repeating sub-report headings at the top of each page. The problem with sub-reports and headings: Add a dummy group to the sub report using the expression =1: Set the “Repeat Section” property of the dummy…
In Microsoft Access, when working with VBA, learn some techniques for writing readable and easily maintained code.

828 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