Skip to content

Public Property ... End Function #10

Open
@Cease

Description

@Cease

Several Property Get end win End Function instead of End Property.

This is one such example. VBA does not complain but VBA-addins that cormat code does get confused.

'Returns whether the process is critical or not
'@returns {Boolean} True if the process is critical, false otherwise
Public Property Get isCritical() As Boolean
'Note: IsProcessCritical can return a weird boolean where bool and Not bool both result in True, which is nonsense...
'for this reason we explicitely cast to a long here...
If CLng(IsProcessCritical(pQueryInfoHandle, isCritical)) = 0 Then
Err.Raise 1, "stdProcess.isCritical", "Cannot get critical status of process. Error code 0x" & Hex(Err.LastDllError)
End If
End Function

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions