Options

Refreshing data form C/AL

dbdb Member Posts: 82
edited 2000-01-27 in Navision Financials
I'm using two applicatins (Cfront and NF).
Cfront pushing data to one table, NF runing cycle (read/modify/delete) on this table.
Then Nf runing & CFront puched data, NF don't see new data on some PC, On some PC couse error 1262 in module 19.
Tried all combinations in CF & in C/AL of TableLock and SelectLatestVersion.
Then PC don't see data, help only restarting NF program. Then I stoping cycle & looking in table using forms or Shift+F12 I don't see data too.

Any suggestions?

[This message has been edited by db (edited 18-01-2000).]

Comments

  • Options
    Tarek_DemiatiTarek_Demiati Member Posts: 112
    Have you tried using the ReleaseAllObjects method before
    opening the database ?

    Have you managed to trap when 1262 in module 19 error occur
    in your code ?



    _______________________
    Tarek Demiati

    tarekd@globalnet.co.uk
    _______________________
  • Options
    dbdb Member Posts: 82
    No I don't use ReleaseAllObjects. I can't find any info about this func in any manual, but in cfront.dll I founded it. That for is used this func ?
    Error coused then C/AL trying to lock tables then tables are locked by CF. On some PC looks like CF table locking not working. It's happens on win98 and NT too. But on some win98 and NT Locking OK, but in this case NF popups message that rec nnnnnn was changed before with another API ??? Now I was stoped at variant:

    begin of cycle
    SELECTLATESTVERSION
    LOCKTABLE
    ...operations...
    COMMIT
    end of cycle

    Now are less errors, but are.
  • Options
    Tarek_DemiatiTarek_Demiati Member Posts: 112
    Check the CFRONT online help (cfront.hlp file)

    Releases all allocated resources.

    Category
    Database


    Sub ReleaseAllObjects


    Comments
    This method is used to release all resources that have been allocated, that is: open tables are closed and records are released.

    The intended use is after an error has occurred, and you want to clean-up before continuing execution. The current database is not closed, neither is an open company.

    Remember that all resources must be released before calling OpenDatabase and CloseDatabase.


    _______________________
    Tarek Demiati

    tarekd@globalnet.co.uk
    _______________________
  • Options
    dbdb Member Posts: 82
    Looks like ReleaseAllObjects work, but I reached same result by using logoff after N min. then transactions ends. But there I meet another problems. I can't wait until all transactions ends. There are processes that writes to another tables & it can take a lot of time until I can issue logoff or ReleaseAllObjects.
    In table locks I can reach succsses too. I founded that all erorrs are issued then:
    1.CF locks table
    2.C/AL stops at unlock waiting
    3.CF unlocks
    4.C/AL entering to proccessing code
    5.CF Locking again, but C/AL still processing
    there C/AL cousing error "rec changed" or "database crashed...", but CF works fine: table locked & writing correct.
Sign In or Register to comment.