Options

insert record into Gen. Journal Line from cfront

gregusggregusg Member Posts: 8
Hi Everybody!

I cannot insert record into the Gen. Journal line from CFRONT (nav4)
I can insert into the Vendor, Customer, any other supplemental tables, but not into the Gen. Journal Line.

For example the following lines are working for any other table but not for the Gen. Journal Line Table.


CFP.OpenCompany("CRONUS Rt.");
hTabla=CFP.OpenTableByName("Gen. Journal Line");
int NewRecord = CFP.AllocRec(hTabla);
CFP.BWT();
for (int i=0; i<10;i++)
{
CFP.InitRec(hTabla,NewRecord);
CFP.AssignField.......
.....
CFP.InsertRec(hTabla,NewRecord);
}
CFP.EWT();

What is wrong? I filled in the keys: Template name, Batch name, Line No, but the records, but the recortds still not appear in the table.

Thanks,
Gabor
gregusg@freemail.hu

Comments

  • Options
    kinekine Member Posts: 12,562
    And is there some error?
    Kamil Sacek
    MVP - Dynamics NAV
    My BLOG
    NAVERTICA a.s.
  • Options
    gregusggregusg Member Posts: 8
    No, There are not any error messages. For example the cfront shows if I want to insert wrong values into the primary key in this table (eg. Line No) .

    But this time I tried to insert "good" values into the Template,LineNo,BatchName key fields.

    I tried the code without the iteration just to insert only one record. It still does not do anything. No error messages, nothing happens....

    Can you try it with jour licence? May be it is some undocumented licensing error

    Gabor,
Sign In or Register to comment.