Field Permission 3.10

SeaMaster
Member Posts: 5
Hi, I have a problem.
My customer want's to have a insert/modify permission for a field in a specific table.
So I created a new table called "Field Permission", that look's like this:
Enabled Field No. Field Name Data Type Length Description
Da 10 Table ID Integer
Da 20 Field ID Integer
Da 30 User ID Code 20 Enabled Field
First table in the list is "Item".
So I inserted the record "27", "9", "SA" in the "Field Permission" table.
Then I went to modify the "Item" table code.
OnModify trigger in "Item" table looks like this:
FieldPermission.RESET;
FieldPermission.SETRANGE ("Table ID", 27);
FieldPermission.SETRANGE ("User ID", USERID);
IF FieldPermission.FIND ('-') THEN
REPEAT
..... this is the problem
..... I don't know how to
..... check the diference
..... between the old and
..... the new value of filed
..... specified in the FieldPermission table
UNTIL FieldPermission.NEXT = 0;
The Navision is 3.10
Thank's in advance.
My customer want's to have a insert/modify permission for a field in a specific table.
So I created a new table called "Field Permission", that look's like this:
Enabled Field No. Field Name Data Type Length Description
Da 10 Table ID Integer
Da 20 Field ID Integer
Da 30 User ID Code 20 Enabled Field
First table in the list is "Item".
So I inserted the record "27", "9", "SA" in the "Field Permission" table.
Then I went to modify the "Item" table code.
OnModify trigger in "Item" table looks like this:
FieldPermission.RESET;
FieldPermission.SETRANGE ("Table ID", 27);
FieldPermission.SETRANGE ("User ID", USERID);
IF FieldPermission.FIND ('-') THEN
REPEAT
..... this is the problem
..... I don't know how to
..... check the diference
..... between the old and
..... the new value of filed
..... specified in the FieldPermission table
UNTIL FieldPermission.NEXT = 0;
The Navision is 3.10
Thank's in advance.
0
Comments
-
IF Rec.Myfield <> xRec.MyField THEN BEGIN // field has been changed END ELSE BEGIN // field has not been changed END;
check the help about xrec and rec. Also help for OnModify trigger®obi
¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯0
Categories
- All Categories
- 73 General
- 73 Announcements
- 66.6K Microsoft Dynamics NAV
- 18.7K NAV Three Tier
- 38.4K NAV/Navision Classic Client
- 3.6K Navision Attain
- 2.4K Navision Financials
- 116 Navision DOS
- 851 Navision e-Commerce
- 1K NAV Tips & Tricks
- 772 NAV Dutch speaking only
- 617 NAV Courses, Exams & Certification
- 2K Microsoft Dynamics-Other
- 1.5K Dynamics AX
- 320 Dynamics CRM
- 111 Dynamics GP
- 10 Dynamics SL
- 1.5K Other
- 990 SQL General
- 383 SQL Performance
- 34 SQL Tips & Tricks
- 35 Design Patterns (General & Best Practices)
- 1 Architectural Patterns
- 10 Design Patterns
- 5 Implementation Patterns
- 53 3rd Party Products, Services & Events
- 1.6K General
- 1.1K General Chat
- 1.6K Website
- 83 Testing
- 1.2K Download section
- 23 How Tos section
- 252 Feedback
- 12 NAV TechDays 2013 Sessions
- 13 NAV TechDays 2012 Sessions