CodeLinePragma Constructors
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Initializes a new instance of the CodeLinePragma class.
Overloads
CodeLinePragma() |
Initializes a new instance of the CodeLinePragma class. |
CodeLinePragma(String, Int32) |
Initializes a new instance of the CodeLinePragma class. |
CodeLinePragma()
- Source:
- CodeLinePragma.cs
- Source:
- CodeLinePragma.cs
- Source:
- CodeLinePragma.cs
- Source:
- CodeLinePragma.cs
Initializes a new instance of the CodeLinePragma class.
public:
CodeLinePragma();
public CodeLinePragma ();
Public Sub New ()
Remarks
If you use this constructor you should also set the LineNumber and FileName properties.
Applies to
CodeLinePragma(String, Int32)
- Source:
- CodeLinePragma.cs
- Source:
- CodeLinePragma.cs
- Source:
- CodeLinePragma.cs
- Source:
- CodeLinePragma.cs
Initializes a new instance of the CodeLinePragma class.
public:
CodeLinePragma(System::String ^ fileName, int lineNumber);
public CodeLinePragma (string fileName, int lineNumber);
new System.CodeDom.CodeLinePragma : string * int -> System.CodeDom.CodeLinePragma
Public Sub New (fileName As String, lineNumber As Integer)
Parameters
- fileName
- String
The file name of the associated file.
- lineNumber
- Int32
The line number to store a reference to.
Examples
The following code example demonstrates the use of the CodeLinePragma class to reference a specific line of a source file.
// Creates a CodeLinePragma that references line 100 of the file "example.cs".
CodeLinePragma^ pragma = gcnew CodeLinePragma( "example.cs",100 );
// Creates a CodeLinePragma that references line 100 of the file "example.cs".
CodeLinePragma pragma = new CodeLinePragma("example.cs", 100);
' Creates a CodeLinePragma that references line 100 of the file "example.cs".
Dim pragma As New CodeLinePragma("example.cs", 100)
Applies to
.NET
피드백
https://aka.ms/ContentUserFeedback
출시 예정: 2024년 내내 콘텐츠에 대한 피드백 메커니즘으로 GitHub 문제를 단계적으로 폐지하고 이를 새로운 피드백 시스템으로 바꿀 예정입니다. 자세한 내용은 다음을 참조하세요.다음에 대한 사용자 의견 제출 및 보기