This commit is contained in:
SchreiberM
2016-04-19 11:10:28 +02:00
10 changed files with 378 additions and 315 deletions

View File

@@ -13,8 +13,8 @@ Public Class ClassControlValues
Return True
End If
Case GetType(ComboBox)
Dim combobox As ComboBox = DirectCast(control, ComboBox)
Case GetType(CustomComboBox)
Dim combobox As CustomComboBox = DirectCast(control, CustomComboBox)
If combobox.Text.Trim() = String.Empty Then
Return False
Else
@@ -236,8 +236,8 @@ Public Class ClassControlValues
Dim label As Label = DirectCast(control, Label)
ControlLoader.Label.LoadValue(label, recordId, parentRecordId, value, entity_ID)
Case GetType(ComboBox)
Dim combobox As ComboBox = DirectCast(control, ComboBox)
Case GetType(CustomComboBox)
Dim combobox As CustomComboBox = DirectCast(control, CustomComboBox)
ControlLoader.Combobox.LoadValue(combobox, recordId, parentRecordId, value)
Case GetType(CheckBox)
@@ -317,8 +317,8 @@ Public Class ClassControlValues
Dim sqlcommand As String = row.Item("SQL")
Dim ConnID = row.Item("CONTROL_CONNID_1")
Select Case Ctrl.GetType()
Case GetType(ComboBox)
Dim combobox = DirectCast(Ctrl, ComboBox)
Case GetType(CustomComboBox)
Dim combobox = DirectCast(Ctrl, CustomComboBox)
ControlLoader.Combobox.LoadList(combobox, FormID, ConnID, sqlcommand)
Case GetType(DevExpress.XtraEditors.ListBoxControl)
@@ -377,8 +377,8 @@ Public Class ClassControlValues
sqlcommand = ReplaceSqlCommandPlaceholders(sqlcommand, RecordId, ParentRecordId, entity_ID)
Select Case Ctrl.GetType()
Case GetType(ComboBox)
Dim combobox = DirectCast(Ctrl, ComboBox)
Case GetType(CustomComboBox)
Dim combobox = DirectCast(Ctrl, CustomComboBox)
ControlLoader.Combobox.LoadList(combobox, FormId, connID, sqlcommand)
Case GetType(DevExpress.XtraEditors.ListBoxControl)
@@ -412,8 +412,8 @@ Public Class ClassControlValues
Public Shared Sub UnloadControlValuesList(RecordID As Integer, FormID As Integer, controls As Control.ControlCollection)
For Each C As Control In controls
If TypeOf C Is ComboBox Then
Dim Combobox = DirectCast(C, ComboBox)
If TypeOf C Is CustomComboBox Then
Dim Combobox = DirectCast(C, CustomComboBox)
Dim currentValue As String = Combobox.Text
Combobox.DataSource = Nothing
Combobox.Text = currentValue
@@ -451,8 +451,8 @@ Public Class ClassControlValues
Case GetType(TextBox)
DirectCast(control, TextBox).Text = String.Empty
Case GetType(ComboBox)
Dim combo As ComboBox = DirectCast(control, ComboBox)
Case GetType(CustomComboBox)
Dim combo As CustomComboBox = DirectCast(control, CustomComboBox)
combo.SelectedIndex = -1
combo.Text = String.Empty
@@ -550,8 +550,8 @@ Public Class ClassControlValues
Dim radio As RadioButton = DirectCast(control, RadioButton)
radio.Checked = StrToBool(autoValue)
Case GetType(ComboBox)
Dim combobox As ComboBox = DirectCast(control, ComboBox)
Case GetType(CustomComboBox)
Dim combobox As CustomComboBox = DirectCast(control, CustomComboBox)
If IsDBNull(autoValue) Then
combobox.SelectedIndex = -1
Else