How to delete values of subsection depending on linked question

I have a categorical variable ; type of activity-manufacturing/ trading

If someone chooses manufacturing, sub-section-3.1 has to be filled up
If someone chooses trading, sub-section-3.2 has to be filled up

suppose, someone mistakenly chooses manufacturing and fills up block-3.1. then he chooses trading and fills up block-3.2. but the data in 3.1 remains. how to delete them.

These values will not appear in the exported data, so no need to do anything special about them.

The reason why they are retained is that the interviewer (e.g. accidentally when scrolling or by mistake) can switch the type of the enterprise (your categorical variable) and it would be very unfortunate to have all the values immediately deleted.

Regards, Sergiy