I have created a DocType, says LOB to record my lines of business, further is used as an “Accounting Dimension”, after deleting it (the doctype) and dimension, and even deleting all the purchase invoices tagged to it.
It’s throwing the below error while just clicking on the Purchase Order button in Buying.
It is possible that you still have some references to Doctype “LOB” on Purchase Order and that is why this error is thrown when you try to open Purchase Order.
Please check via Customize Form.
Also check Customize Doctype, however it is recommended to avoid customising Core Doctype like Purchase Order via Customize Doctype.