Source.CreateErrorTaskItem Method (TextSpan, String, String, TaskPriority, TaskCategory, MARKERTYPE, TaskErrorCategory)
Creates a new error task item for the Error List, for the supplied text, file name, message, priority, category, marker type, and error type.
Namespace: Microsoft.VisualStudio.Package
Assemblies: Microsoft.VisualStudio.Package.LanguageService.9.0 (in Microsoft.VisualStudio.Package.LanguageService.9.0.dll)
Microsoft.VisualStudio.Package.LanguageService (in Microsoft.VisualStudio.Package.LanguageService.dll)
Microsoft.VisualStudio.Package.LanguageService.10.0 (in Microsoft.VisualStudio.Package.LanguageService.10.0.dll)
Syntax
‘선언
Public Overridable Function CreateErrorTaskItem ( _
span As TextSpan, _
filename As String, _
message As String, _
priority As TaskPriority, _
category As TaskCategory, _
markerType As MARKERTYPE, _
errorCategory As TaskErrorCategory _
) As DocumentTask
‘사용 방법
Dim instance As Source
Dim span As TextSpan
Dim filename As String
Dim message As String
Dim priority As TaskPriority
Dim category As TaskCategory
Dim markerType As MARKERTYPE
Dim errorCategory As TaskErrorCategory
Dim returnValue As DocumentTask
returnValue = instance.CreateErrorTaskItem(span, _
filename, message, priority, category, _
markerType, errorCategory)
public virtual DocumentTask CreateErrorTaskItem(
TextSpan span,
string filename,
string message,
TaskPriority priority,
TaskCategory category,
MARKERTYPE markerType,
TaskErrorCategory errorCategory
)
public:
virtual DocumentTask^ CreateErrorTaskItem(
TextSpan span,
String^ filename,
String^ message,
TaskPriority priority,
TaskCategory category,
MARKERTYPE markerType,
TaskErrorCategory errorCategory
)
abstract CreateErrorTaskItem :
span:TextSpan *
filename:string *
message:string *
priority:TaskPriority *
category:TaskCategory *
markerType:MARKERTYPE *
errorCategory:TaskErrorCategory -> DocumentTask
override CreateErrorTaskItem :
span:TextSpan *
filename:string *
message:string *
priority:TaskPriority *
category:TaskCategory *
markerType:MARKERTYPE *
errorCategory:TaskErrorCategory -> DocumentTask
public function CreateErrorTaskItem(
span : TextSpan,
filename : String,
message : String,
priority : TaskPriority,
category : TaskCategory,
markerType : MARKERTYPE,
errorCategory : TaskErrorCategory
) : DocumentTask
Parameters
- span
Type: Microsoft.VisualStudio.TextManager.Interop.TextSpan
A TextSpan structure, which defines a block of text.
- filename
Type: System.String
The name of the file.
- message
Type: System.String
The error message.
- priority
Type: Microsoft.VisualStudio.Shell.TaskPriority
A member of the TaskPriority enumeration.
- category
Type: Microsoft.VisualStudio.Shell.TaskCategory
A member of the TaskCategory enumeration.
- markerType
Type: Microsoft.VisualStudio.TextManager.Interop.MARKERTYPE
A member of the MARKERTYPE enumeration.
- errorCategory
Type: Microsoft.VisualStudio.Shell.TaskErrorCategory
A member of the ErrorCategory enumeration, which defines the level of error.
Return Value
Type: Microsoft.VisualStudio.Package.DocumentTask
A new instance of DocumentTask.
.NET Framework Security
- Full trust for the immediate caller. This member cannot be used by partially trusted code. For more information, see Using Libraries from Partially Trusted Code.