|
using System;
using System.ComponentModel;
using System.ComponentModel.Design;
using System.Collections;
using System.Drawing;
using System.Workflow.ComponentModel;
using System.Workflow.ComponentModel.Design;
using System.Workflow.ComponentModel.Compiler;
using System.Workflow.ComponentModel.Serialization;
using System.Workflow.Runtime;
using System.Workflow.Activities;
using System.Workflow.Activities.Rules;
using DashboardDataAccess;
namespace DashboardBusiness.Activities
{
public partial class DeleteWidgetInstanceActivity : System.Workflow.ComponentModel.Activity
{
public DeleteWidgetInstanceActivity()
{
InitializeComponent();
}
private static DependencyProperty WidgetInstanceIdProperty = DependencyProperty.Register("WidgetInstanceId", typeof(int), typeof(DeleteWidgetInstanceActivity));
public int WidgetInstanceId
{
get { return (int)base.GetValue(WidgetInstanceIdProperty); }
set { base.SetValue(WidgetInstanceIdProperty, value); }
}
protected override ActivityExecutionStatus Execute(ActivityExecutionContext executionContext)
{
DatabaseHelper.Delete<WidgetInstance>(delegate( WidgetInstance template )
{
template.Id = this.WidgetInstanceId;
});
return ActivityExecutionStatus.Closed;
}
}
}
|
By viewing downloads associated with this article you agree to the Terms of Service and the article's licence.
If a file you wish to view isn't highlighted, and is a text file (not binary), please
let us know and we'll add colourisation support for it.