private void buttonOK_Click(object sender, EventArgs e) { attributeFormResponse = new AttributeFormResponse(); attributeFormResponse.CurrentPowerQueryAttribute = attributeFormMessage.CurrentPowerQueryAttribute; attributeFormResponse.CurrentPowerQueryAttribute.DisplayName = textBoxDisplayName.Name; if (checkBoxAddLookupGuid.Checked) { PowerQueryAttribute guidAttribute = FetchXmlQueryHelper.LookupGuidPowerQueryAttribute(attributeFormMessage.CurrentPowerQueryAttribute);// new PowerQueryAttribute(); attributeFormResponse.NewFields.Add(guidAttribute); } if (checkBoxAddEntityLogicalName.Checked) { PowerQueryAttribute guidAttribute = FetchXmlQueryHelper.LogicalLookupPowerQueryAttribute(attributeFormMessage.CurrentPowerQueryAttribute);// new PowerQueryAttribute(); attributeFormResponse.NewFields.Add(guidAttribute); } if (checkBoxAddFormattedValue.Checked) { PowerQueryAttribute formattedAttribute = FetchXmlQueryHelper.FormattedPowerQueryAttribute(attributeFormMessage.CurrentPowerQueryAttribute); //guidAttribute.Name = $"_{attributeFormMessage.CurrentPowerQueryAttribute.Name}[email protected]"; // $"_{attributeFormMessage.AttributeLogicName}_value"; //guidAttribute.DisplayName = textBoxDisplayName.Text + " Enity Logical Name"; //guidAttribute.Type = "EnityLogicalName"; attributeFormResponse.NewFields.Add(formattedAttribute); } this.DialogResult = DialogResult.OK; this.Close(); }
private void buttonOK_Click(object sender, EventArgs e) { attributeFormResponse = new AttributeFormResponse(); attributeFormResponse.CurrentPowerQueryAttribute = attributeFormMessage.CurrentPowerQueryAttribute; attributeFormResponse.CurrentPowerQueryAttribute.DisplayName = textBoxDisplayName.Text; if (checkBoxAddFormattedValue.Checked) { attributeFormResponse.NewFields.Add(FetchXmlQueryHelper.FormattedPowerQueryAttribute(attributeFormResponse.CurrentPowerQueryAttribute)); } this.DialogResult = DialogResult.OK; this.Close(); }