Opc.Ua.Configuration.AccessRuleListDlg.ShowDialog C# (CSharp) Method

ShowDialog() public method

Displays the dialog.
public ShowDialog ( IList objectTypes, IList objectPaths ) : bool
objectTypes IList
objectPaths IList
return bool
        public bool ShowDialog(IList<SecuredObject> objectTypes, IList<string> objectPaths)
        {
            ObjectTypeCB.Items.Clear();
            m_objectPaths = new List<string>();

            if (objectTypes != null && objectPaths != null)
            {
                for (int ii = 0; ii < objectTypes.Count; ii++)
                {
                    if (ii < objectPaths.Count && !String.IsNullOrEmpty(objectPaths[ii]))
                    {
                        ObjectTypeCB.Items.Add(objectTypes[ii]);
                        m_objectPaths.Add(objectPaths[ii]);
                    }
                }
            }

            if (ObjectTypeCB.Items.Count > 0)
            {
                ObjectTypeCB.SelectedIndex = 0;
            }

            if (ShowDialog() != DialogResult.OK)
            {
                return false;
            }

            return true;
        }