I made a forma nd placed a field there. Then I made a method that creates new record and placed a button that calls that method.
The problem is that when a record is created the field that should autoincrement gets set to 0, and only if I go to designer mode and then back I get field to autoincrement.
I used controller.newRecord() in a method.
What may I be doing wrong?
here is the method:
controller.newRecord();
that’s all I did.
If I create two after each other, they both get set to 0 until I go to designer mode and back, then they are set to right values.
I use latest evaluation version on Windows XP
Thank you
Johan, you are dealing with recent graduate girl, and I still don’t understand many things…
I assume you mean Primary Key by ‘pk’ and I don’t understand what you mean by database sequence.
I’m attaching a picture of how the data provider is set, hope it will help.
JobNumer is youre primary key.. But youre sequence type of that row (last column) is none. You have to set that to the sequence type you want and that is database sequence…
or else servoy doesn’t know that you are using a database sequence.
OK, then I have another question.
When I just create a new field I can set the database sequence, but if the field is already created I am not able to change it.
Can you tell me how to change it?