-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathNewLineConstant.vb
51 lines (50 loc) · 1.5 KB
/
NewLineConstant.vb
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
#Region "#usings"
Imports DevExpress.XtraReports.Expressions
Imports System
#End Region
Namespace CustomFunctionForExpressionEditorExample
#Region "#NewLineConstant"
Public Class NewLineConstant
Inherits ReportCustomFunctionOperatorBase
Public Overrides ReadOnly Property FunctionCategory() As String
Get
Return "String"
End Get
End Property
Public Overrides ReadOnly Property Description() As String
Get
Return "NewLineConstant()" & ControlChars.CrLf & "Inserts a new line."
End Get
End Property
Public Overrides Function IsValidOperandCount(ByVal count As Integer) As Boolean
Return count = 0
End Function
Public Overrides Function IsValidOperandType(ByVal operandIndex As Integer,
ByVal operandCount As Integer,
ByVal type As Type) As Boolean
Return True
End Function
Public Overrides ReadOnly Property MaxOperandCount() As Integer
Get
Return 0
End Get
End Property
Public Overrides ReadOnly Property MinOperandCount() As Integer
Get
Return -1
End Get
End Property
Public Overrides Function Evaluate(ParamArray ByVal operands() As Object) As Object
Return Environment.NewLine
End Function
Public Overrides ReadOnly Property Name() As String
Get
Return "NewLineConstant"
End Get
End Property
Public Overrides Function ResultType(ParamArray ByVal operands() As Type) As Type
Return GetType(String)
End Function
End Class
#End Region
End Namespace