Way to make button show up only if there is something there?

yuppicideyuppicide Member Posts: 410
edited 2011-10-11 in Navision Attain
Nav 3.10

On the Shipping tab of a Sales Order. Where it says Ship-to Code there's a box and an arrow. If you click that arrow it will open the shipping addresses (if that customer has any).

Maybe there's a way to make that arrow only show up if there are shipping addresses?

Some customers have the same billing and shipping address. Every order we open that arrow up to see if there are any additional shipping addresses. If there are none, not having that arrow would save a few clicks of not having to check.

Comments

  • jglathejglathe Member Posts: 639
    Hi,

    you could achieve a similar thing on dynamically enabling the control. I would do this on OnAfterGetRecord, maybe OnAfterGetCurrrecord also. The visible, enabled and editable properties can be changed dynamically, the lookup property not.

    with best regards

    Jens
  • SavatageSavatage Member Posts: 7,142
    How about a visible checkbox since you don't have a Dev License.

    Sales Header Table (Table 36)
    add a new field.
    50090 - Ship-To Exists -> Type Boolean
    View Properties
    FieldClass->Flowfield
    CalcFormula->Exist("Ship-to Address" WHERE (Customer No.=FIELD(Sell-to Customer No.)))

    Sales Order Header Form -> Tools -> Designer
    View->Field Menu
    Find the New field "Ship-To Exists" drop on the tab of your choice.

    Now when you enter the sell-to customer number of a new order this box will quickly tell you if they have any addresses listed in the "Ship-to address" table.
    Save->Compile->Enjoy!
  • David_SingletonDavid_Singleton Member Posts: 5,479
    Just copy the functionality from the comments button, it does 90% of what you want.
    David Singleton
Sign In or Register to comment.