Hi,
I have a sub form (Interaction log entries) attached to the front of another form (Contact Card) as a sub form, I want to be able to create a button within the subform that opens up a 3rd form showing the comments for the selected interaction log entry, when I try to do this I get the error.
Microsoft Dynamics NAV
The two fields below must have the same type:
Field: Entry No. <-- No.
Table: Inter. Log Entry Comment Line <-- Contact
Type: Integer <-- Code20
Which tells me that it's taking the No. field from the contact table and not the Entry_No. field from the Interaction table like I asked it to!
Navision obviously thinks its in the contact card even though I'm clicking a button with the subform.
I've been advised by our developers that I would need to add code in the button to do this but we don't have the relevant licence.
Is there any other way around this - I don't have the relevant field in the main form/table - I have to take it from the sub form from the row selected.
Thanks in advance for any help.
0
Comments
AP Commerce, Inc. = where I work
Getting Started with Dynamics NAV 2013 Application Development = my book
Implementing Microsoft Dynamics NAV - 3rd Edition = my 2nd book
Wouldn't it be simpler, faster and in the long run cheaper just to pay your Navision Partner to write the code? :-k
There are a couple of issues here:
1. If what you want to show the comments from the Interaction Log Entry form, there already is a button - actually it's a button and a menu option. Click on "Entry" then choose "Comments".
2. That being said, you could create a new button just for "Comments". You can copy the RunObject from the other button, but the important pieces are:
Action: Runobject
Runobject: Form Inter. Log Entry Comment Sheet
RunFormLink: Entry No.=FIELD(Entry No.)
RunFormLinkType: OnUpdate
It appears that it's the RunFormLink that isn't set up on your button correctly. Go to the object properties, cursor/click on the RunFormLink line and press F6. The values you need are:
Field: Entry No.
Type: FIELD
Value: Entry No.
What this is saying is that the value of the "Entry No." field on the Interaction Log Entry table is used as the key into the Interaction Log Entry Comment table. Only the comment lines with the same value of Entry No. will be displayed.
Hope this helps.
Anyone can tell me how to solve it?
Thx all!
It works as expected... More or Less...
2 lines of code and I solved it.
It works as expected... More or Less...
I am getting an error while posting my Gate entry inward Form.
"The Two fields below must have the same type"
Field arty Type<-- Party Code
Table : posted gate entry header<---gate entry header
Type : Option <--Code20.
Please suggest possible reason for this error..how to correct it..
party type is option with string vendor & customer.
party code is code of 20 displays party no.
the same is in posted gate entry header table..
thanks...