protected override ActivityExecutionStatus Execute(ActivityExecutionContext executionContext)
        {
            _ipHelper = new IPAccessHelper(__Context);

            try
            {
                _ipHelper.LoadForm();
            }
            catch (Exception e)
            {
                Exception we = Common.WrapWithFriedlyException(e, "Error loading form data file. Likely causes: this file is not a valid InfoPath Form!");

                Common.LogExceptionToWorkflowHistory(we, executionContext, this.WorkflowInstanceId);

                throw we;

            }

            try
            {

                    this.PropertyValue = this._ipHelper.GetFormValueInnerXml(this.PropertyPath);
            }
            catch (Exception e)
            {
                Exception we = Common.WrapWithFriedlyException(e, string.Format("Error getting form value where path = {0}", this.PropertyPath));

                Common.LogExceptionToWorkflowHistory(we, executionContext, this.WorkflowInstanceId);

                throw we;

            }

            return ActivityExecutionStatus.Closed;
        }
        protected override ActivityExecutionStatus Execute(ActivityExecutionContext executionContext)
        {
            _ipHelper = new IPAccessHelper(__Context);

            try
            {
                _ipHelper.LoadForm();
            }
            catch (Exception e)
            {
                Exception we = Common.WrapWithFriedlyException(e, "Error loading form data file. Likely causes: this file is not a valid InfoPath Form!");

                Common.LogExceptionToWorkflowHistory(we, executionContext, this.WorkflowInstanceId);

                throw we;

            }

                FormSetFieldValueRequest myRequest = new Hypertek.IOffice.Workflow.Core.Activities.DP.InfoPath.FormSetFieldValueRequest();

                myRequest.IPAccessHelper = this._ipHelper;

                myRequest.PropertyPath = this.PropertyPath;

                myRequest.PropertyValue = this.PropertyValue;

                myRequest.SetValueType = FormSetValueType.InnerXml;

                WorkflowEnvironment.WorkBatch.Add(IPAccessService.Instance, myRequest);

            return ActivityExecutionStatus.Closed;
        }