Quantcast
Channel: Microsoft Dynamics SL
Viewing all articles
Browse latest Browse all 14968

Forum Post: RE: Disable Unit Price at OM Shippers Screen

$
0
0

Hello Peter,

Usually you can disable a field on a screen using customize mode.   To do this:

1 - Open the screen

2 - Go into customize mode

3 - Find the field you want to disable

4 - Right click on it and open the properties window

5 - Find the enabled property and set it to false

6 - save and close the screen.

Sometimes this doesn't appear to work through, usually because there is other code on the screen that just re-enables the field you just disabled.   So you would then need to add additional code to override this.   For example, on the shippers screen you could add the following to the VBA editor in customization mode:

Private Sub cinvtid_1_Chk(ChkStrg As String, retval As Integer)

Call MSetProp("ccuryslsprice_1", PROP_ENABLED, False)

End Sub

Private Sub Spread1_LineGotFocus(maintflg As Integer, retval As Integer)

Call MSetProp("ccuryslsprice_1", PROP_ENABLED, False)

End Sub

This code resets the enabled property to false when users click into the grid, and then again on the inventory ID check event.   Similar code can be used for other fields and in the other screen.  Hopefully this code will help you to develop the rest of the code you need.

Thanks


Viewing all articles
Browse latest Browse all 14968

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>