ITK build Error in itk::ShapedNeighborhoodIterator

Hello all,

We have created a DLL project to perform pre-processing operation and morphological operation on dicom data.
After that, we wrote an application project to use this generated DLL to perform all operations. In that process, I am getting below error.
Error C2516 ‘itk::ShapedNeighborhoodIterator<TImage,TBoundaryCondition>::ConstIterator’: is not a legal base class

I build ITK5.3.0 with visual studio 2019. Can you please suggest, how to resolve this issue.

You will need to provide the code fragment which triggers the error.