This commit is contained in:
@@ -1346,7 +1346,6 @@ Public Class Compo
|
||||
sErrorList = ConcatErrorString(sErrorList, String.Format(EgtMsg(50147), NewCompoParam.Name, sItems(2)))
|
||||
Return False
|
||||
End Select
|
||||
|
||||
NewCompoParam = New TextBoxOnOffParam(sDDFName, sName, Me, sDefaultValue, Nothing, Nothing, sTypeValue, sHelpParam)
|
||||
Return True
|
||||
'If StringToDouble(sItems(2), dDefaultValue) AndAlso dDefaultValue < dHeight Then
|
||||
|
||||
@@ -675,8 +675,16 @@ Public Class Hardware
|
||||
EgtUILib.GetPrivateProfileString(S_CHAPTER & ChapterIndex, "HelpParam" & ParamIndex, "", sHelpParam, m_StdTemplate)
|
||||
' leggo il tipo di parametro, se la lettura va a buon fine la carico
|
||||
If Chapter.ReadParamHardware(sParam, sHelpParam, NewParam, ErrorReading) Then Chapter.CompoParamList.Add(NewParam)
|
||||
If TypeOf NewParam Is TextBoxOnOffParam Then
|
||||
Dim Param = DirectCast(NewParam, TextBoxOnOffParam)
|
||||
Param.IsActive = False
|
||||
ElseIf TypeOf Newparam Is ComboBoxOnOffParam Then
|
||||
Dim Param = DirectCast(NewParam, ComboBoxOnOffParam)
|
||||
Param.IsActive = False
|
||||
End If
|
||||
|
||||
End If
|
||||
ParamIndex += 1
|
||||
ParamIndex += 1
|
||||
End While ' termina lettura del capitolo
|
||||
GroupChapters.Add(Chapter)
|
||||
ParamIndex = 1
|
||||
@@ -892,6 +900,26 @@ Public Class Hardware
|
||||
Dim Text As TextBoxLuaParam = DirectCast(m_GroupChapters(IndexGroupChapters).CompoParamList(IndexChapter), TextBoxLuaParam)
|
||||
Text.SetValue(Trim(Utility.DeleteSuperScript(sValue)))
|
||||
|
||||
ElseIf TypeOf m_GroupChapters(IndexGroupChapters).CompoParamList(IndexChapter) Is TextBoxOnOffParam Then
|
||||
Dim Text As TextBoxOnOffParam = DirectCast(m_GroupChapters(IndexGroupChapters).CompoParamList(IndexChapter), TextBoxOnOffParam)
|
||||
Text.IsActive = True
|
||||
' se testo numerico, eseguo opportunbe conversioni per H,W e T
|
||||
sValue = ConvertToDGD(Text.TypeVar, sValue)
|
||||
' controllo il tipo di dato che si aspetta
|
||||
Select Case Text.TypeVar
|
||||
Case ConstGen.INCHES
|
||||
Dim sLen As String = Trim(Utility.GetMeasure(sValue))
|
||||
Text.SetValue(sLen)
|
||||
Case ConstGen.MM
|
||||
Dim sLen As String = Trim(Utility.GetMeasure(sValue))
|
||||
Text.SetValue(sLen)
|
||||
Case ConstGen.VAL_DOUBLE
|
||||
Dim dVal As Double = 0.0
|
||||
If StringToDouble(sValue, dVal) Then Text.SetValue(sValue) Else Text.SetValue("0.000")
|
||||
Case ConstGen.VAL_STRING
|
||||
Text.SetValue(Trim(Utility.DeleteSuperScript(sValue)))
|
||||
End Select
|
||||
|
||||
ElseIf TypeOf m_GroupChapters(IndexGroupChapters).CompoParamList(IndexChapter) Is TextBoxParam Then
|
||||
Dim Text As TextBoxParam = DirectCast(m_GroupChapters(IndexGroupChapters).CompoParamList(IndexChapter), TextBoxParam)
|
||||
' se testo numerico, eseguo opportunbe conversioni per H,W e T
|
||||
@@ -922,6 +950,15 @@ Public Class Hardware
|
||||
For IndexCombo As Integer = 0 To Text.ItemListDDF.Count - 1
|
||||
If Trim(Utility.DeleteSuperScript(Text.ItemListDDF(IndexCombo))) = Trim(Utility.DeleteSuperScript(sValue)) Then Text.SetSelItem(Text.ItemList(IndexCombo))
|
||||
Next
|
||||
|
||||
ElseIf TypeOf m_GroupChapters(IndexGroupChapters).CompoParamList(IndexChapter) Is ComboBoxOnOffParam Then
|
||||
Dim Text As ComboBoxOnOffParam = DirectCast(m_GroupChapters(IndexGroupChapters).CompoParamList(IndexChapter), ComboBoxOnOffParam)
|
||||
Text.IsActive = True
|
||||
Text.SetSelItem(Text.ItemList(0))
|
||||
For IndexCombo As Integer = 0 To Text.ItemListDDF.Count - 1
|
||||
If Trim(Utility.DeleteSuperScript(Text.ItemListDDF(IndexCombo))) = Trim(Utility.DeleteSuperScript(sValue)) Then Text.SetSelItem(Text.ItemList(IndexCombo))
|
||||
Next
|
||||
|
||||
ElseIf TypeOf m_GroupChapters(IndexGroupChapters).CompoParamList(IndexChapter) Is ComboBoxParam Then
|
||||
Dim Text As ComboBoxParam = DirectCast(m_GroupChapters(IndexGroupChapters).CompoParamList(IndexChapter), ComboBoxParam)
|
||||
Text.SetSelItem(Text.ItemList(0))
|
||||
|
||||
@@ -172,13 +172,13 @@
|
||||
</Grid.ColumnDefinitions>
|
||||
<CheckBox Name="ChBxBox" IsChecked="{Binding IsActive}"
|
||||
Style="{StaticResource DoorParamsChBx}"
|
||||
VerticalAlignment="Top"/>
|
||||
Margin="0,-2,0,2"/>
|
||||
<TextBlock Text="{Binding Name}" Grid.Column="1"
|
||||
Style="{StaticResource DoorParamsTxBl}"
|
||||
Margin="0,2,0,2"/>
|
||||
Margin="0,0,0,2"/>
|
||||
</Grid>
|
||||
<ComboBox ItemsSource="{Binding ItemList}" Grid.Column="2"
|
||||
Margin="0,2,0,2"
|
||||
Margin="0,0,0,2"
|
||||
SelectedItem="{Binding SelItem}"
|
||||
Style="{StaticResource DoorParamsCmBx}"
|
||||
IsEnabled="{Binding IsChecked, ElementName=ChBxBox}"/>
|
||||
@@ -362,7 +362,7 @@
|
||||
|
||||
<CheckBox Name="ChBx" IsChecked="{Binding IsActive}"
|
||||
Style="{StaticResource DoorParamsChBx}"
|
||||
VerticalAlignment="Top"/>
|
||||
Margin="0,-2,0,2"/>
|
||||
<TextBlock Text="{Binding Name}" Grid.Column="1"
|
||||
Style="{StaticResource DoorParamsTxBl}"
|
||||
Margin="0,2,0,2"/>
|
||||
@@ -609,16 +609,16 @@
|
||||
</Grid.ColumnDefinitions>
|
||||
|
||||
<CheckBox Name="ChBx" IsChecked="{Binding IsActive}"
|
||||
Style="{StaticResource DoorParamsChBx}"
|
||||
VerticalAlignment="Top"/>
|
||||
Style="{StaticResource DoorParamsChBx}"
|
||||
VerticalAlignment="Center"/>
|
||||
<TextBlock Text="{Binding Name}" Grid.Column="1"
|
||||
Style="{StaticResource DoorParamsTxBl}"
|
||||
Margin="0,2,0,2"/>
|
||||
Margin="0,0,0,2"/>
|
||||
</Grid>
|
||||
<TextBox Text="{Binding Value,UpdateSourceTrigger=PropertyChanged}" Grid.Column="2"
|
||||
Style="{StaticResource DoorParamsTxBx}"
|
||||
IsEnabled="{Binding IsChecked, ElementName=ChBx}"
|
||||
Margin="0,2,0,2"
|
||||
Margin="0,0,0,2"
|
||||
ToolTip="{Binding ToolTipValue,UpdateSourceTrigger=PropertyChanged}"/>
|
||||
</Grid>
|
||||
</DataTemplate>
|
||||
|
||||
Reference in New Issue
Block a user