Vault Data Standard help with on selection change

Vault Data Standard help with on selection change

adam_butcher
Enthusiast Enthusiast
284 Views
0 Replies
Message 1 of 1

Vault Data Standard help with on selection change

adam_butcher
Enthusiast
Enthusiast

Hi Guys

I have a Property called group with a value of TEST 1 TEST 2 and TEST 3, Once test 1 is selected properties QIS 1 to QIS 8 must display information, if TEST 2 is selected QIS 1 to QIS 8 must display different values. This work when i change the category but i want it to work with the group property. Please see below.

 

Thanks

Adam.

 

 

function InitializeWindow{


#begin rules applying commonly
$dsWindow.Title = SetWindowTitle

InitializeCategory
InitializeNumSchm
InitializeBreadCrumb
InitializeFileNameValidation
mGetProjectFolderPropToCADFile -mFolderSourcePropertyName "Name" -mCadFileTargetPropertyName "Project"

#end rules applying commonly

$mWindowName = $dsWindow.Name
switch($mWindowName)
{
"InventorWindow"
{

$Prop["Group"].add_PropertyChanged({
if ($_.PropertyName -eq "Value")
FilterQISProperties
})
}

 

function FilterQISProperties
{

$global:propDefs = $vault.PropertyService.GetPropertyDefinitionsByEntityClassId("FLDR")
if($Prop["Group"].Value -eq "TEST 1")
{
$Prop["QIS 1"].ListValues = @("-","1","2")
$Prop["QIS 2"].ListValues = @("-","1","2")
$Prop["QIS 3"].ListValues = @("-","1","2")
$Prop["QIS 4"].ListValues = @("-","1","2")
$Prop["QIS 5"].ListValues = @("-","1","2")
$Prop["QIS 6"].ListValues = @("-","1","2")
$Prop["QIS 7"].ListValues = @("-","1","2")
$Prop["QIS 8"].ListValues = @("-","1","2")
}
elseif($Prop["Group"].Value -eq "TEST 2")
{
$Prop["QIS 1"].ListValues = @("-","3","4")
$Prop["QIS 2"].ListValues = @("-","3","4")
$Prop["QIS 3"].ListValues = @("-","3","4")
$Prop["QIS 4"].ListValues = @("-","3","4")
$Prop["QIS 5"].ListValues = @("-","3","4")
$Prop["QIS 6"].ListValues = @("-","3","4")
$Prop["QIS 7"].ListValues = @("-","3","4")
$Prop["QIS 8"].ListValues = @("-","3","4")
}
elseif($Prop["Group"].Value -eq "TEST 3")
{
$Prop["QIS 1"].ListValues = @("-","5","6")
$Prop["QIS 2"].ListValues = @("-","5","6")
$Prop["QIS 3"].ListValues = @("-","5","6")
$Prop["QIS 4"].ListValues = @("-","5","6")
$Prop["QIS 5"].ListValues = @("-","5","6")
$Prop["QIS 6"].ListValues = @("-","5","6")
$Prop["QIS 7"].ListValues = @("-","5","6")
$Prop["QIS 8"].ListValues = @("-","5","6")
}
return $properties
}

0 Likes
285 Views
0 Replies
Replies (0)