jj_27_01_16

This commit is contained in:
JenneJ
2016-01-27 15:23:23 +01:00
parent 2887aea532
commit 91708d16d3
7 changed files with 84 additions and 25 deletions

View File

@@ -11,6 +11,14 @@
Empty = 1
End Enum
Public Function NotNull(Of T)(ByVal value As T, ByVal defaultValue As T) As T
If value Is Nothing OrElse String.IsNullOrEmpty(value.ToString) OrElse IsDBNull(value) Then
Return defaultValue
Else
Return value
End If
End Function
Public Function BoolToInt(bool As Boolean) As Integer
' Wandelt einen Boolean Wert in einen Int um
Return IIf(bool, 1, 0)