////////// VB 코드 //////////////
<!--CodeS-->
If Not TypeOf m_pCurrentLayer Is IGeoFeatureLayer Then Exit Sub
<!--CodeE-->
위 코드가 m_pCurrentLayer 라는 변수가 IGeoFeatureLayer 인지
체크하는 구문이라는건 알겠는데... 이걸 델파이 코드로 변환하지를 못하겠네요
IGeoFeatureLayer 이것은
<!--CodeS-->
// *********************************************************************//
// Interface: IGeoFeatureLayer
// Flags: (256) OleAutomation
// GUID: {E156D7E5-22AF-11D3-9F99-00C04F6BC78E}
// *********************************************************************//
IGeoFeatureLayer = interface(IFeatureLayer)
['{E156D7E5-22AF-11D3-9F99-00C04F6BC78E}']
function Get_Renderer(out Renderer: IFeatureRenderer): HResult; stdcall;
function _Set_Renderer(const Renderer: IFeatureRenderer): HResult; stdcall;
function Get_RendererPropertyPageClassID(out clsid: IUID): HResult; stdcall;
function Set_RendererPropertyPageClassID(const clsid: IUID): HResult; stdcall;
function Get_DisplayAnnotation(out Value: WordBool): HResult; stdcall;
function Set_DisplayAnnotation(Value: WordBool): HResult; stdcall;
function Get_AnnotationPropertiesID(out uid: IUID): HResult; stdcall;
function _Set_AnnotationPropertiesID(const uid: IUID): HResult; stdcall;
function Get_AnnotationProperties(out props: IAnnotateLayerPropertiesCollection): HResult; stdcall;
function Set_AnnotationProperties(const props: IAnnotateLayerPropertiesCollection): HResult; stdcall;
function Set_CurrentMapLevel(Param1: Integer): HResult; stdcall;
function Get_ExclusionSet(out fids: IFeatureIDSet): HResult; stdcall;
function _Set_ExclusionSet(const fids: IFeatureIDSet): HResult; stdcall;
function Get_DisplayFeatureClass(out fclass: IObjectClass): HResult; stdcall;
function SearchDisplayFeatures(const queryFilter: IQueryFilter; recycling: WordBool;
out cursor: IFeatureCursor): HResult; stdcall;
end;
<!--CodeE-->
위와 같은 인터페이스인데요..
답변 부탁드립니다. 그럼 좋은하루되세요..
아래와 같이 하시면 될겁니다.
<!--CodeS-->
If not m_pCurrentLayer is IGeoFeatureLayer then
Exit;
<!--CodeE-->
^^ 항상 즐코하세요...