Returns the type of an input record field.
HRESULT STDMETHODCALLTYPE GetFieldType(IN DWORD fIndex, OUT DWORD *pnFieldType);
fieldType = GetFieldType(fIndex);
C++ example:
HRESULT CProcessesInputContext::GetFieldType(IN DWORD fIndex, OUT DWORD *pnFieldType) { switch(fIndex) { case 0: { // ImageName *pnFieldType = ILogParserInputContext::String; break; } case 1: { // PID *pnFieldType = ILogParserInputContext::Integer; break; } case 2: { // ParentPID *pnFieldType = ILogParserInputContext::Integer; break; } case 3: { // Threads *pnFieldType = ILogParserInputContext::Integer; break; } } return S_OK; }VBScript example:
Function GetFieldType(nFieldIndex) Select Case nFieldIndex Case 0 ' String GetFieldType = 3 Case 1 ' String GetFieldType = 3 Case 2 ' Timestamp GetFieldType = 4 Case 3 ' String GetFieldType = 3 Case 4 ' String GetFieldType = 3 Case 5 ' String GetFieldType = 3 End Select End Function
© 2004 Microsoft Corporation. All rights reserved.