14.06.12 Navision Navision

By: Peter Karsten

Missing buttons "ok" and "cancel" in Forms

If you wondered about missing buttons "ok" and "cancel" after run a form, perhaps this help you...

If we take the Table 225("Post code"), this table has the property LookupForm = "Post Codes", Post Codes is the Form 367. When we have an order, and press F6 in the Field "Post Code", the Form will opened , and we can see a list with all Post Codes avaible. In the bottom of the form, we can see too all the buttons: "ok", "cancel", "help", and the MenuButton: "Post Code".

After Lookup on the Field Post-Code, all buttons are visible

A click on "Post Code"-> Ranges say us that we don't need this function (Not supported function for local version 49), by reason of this, we would hidden this button, because we don't wan't an additional click for the users (2 clicks are 1 click too much, words of my teacher years ago).

With CTRL+F2 we changed in the designer, and we go to the propertys of the MenuButton, this gone, we set the property "Visible = No", now we would make sure the button is hidden, and we press CTRL+R for run the form, we see the MenuButton "Post Code" is hidden, but we see too that the other Buttons are hidden too, why?

no buttons here ...

The Reason is simple: the buttons are only visible when the form opened with Lookup from a field, e.g. on the field "Post Code" in an order. In the Designer, we run directly the form, when we do this the Lookup is missed, and then the buttons are hidden automatically. We can get more infos in the propertys of the buttons, the property PushAction in a button ("ok" or "cancel") say us we can have the property: "LookupOK" and "LookupCancel".

If we click "OK" after run the form(after Lookup) , dynamics Nav gets the value from form (e.g. the post code in an order), otherwise we click "cancel" no value will taken and the form closes.

So, it's not a mystery, perhaps anybody know about this ;-) But sometimes men is standing on the pipe and wondering because it doesn't give water, perhaps this helps the one or other so the dry time is more short.

(PS: Sorry my bad english)

After Lookup on the Post Code field in an order, the not needed button is hidden, and all others stay here again :)


Submitting your vote...
Rating: 5.0 of 5. 2 vote(s).
Click the rating bar to rate this item.

Comments: