Index: /branches/WebApplication/MVC2/HLWebOKBQueryPlugin/Controllers/FilterController.cs
===================================================================
--- /branches/WebApplication/MVC2/HLWebOKBQueryPlugin/Controllers/FilterController.cs	(revision 6162)
+++ /branches/WebApplication/MVC2/HLWebOKBQueryPlugin/Controllers/FilterController.cs	(revision 6163)
@@ -26,4 +26,6 @@
 
             QueryServiceClient client = Query.GetClientFactory("okbtester", "okbtester");
+            
+
            long[] ids =  client.GetRunIds(qm.Content);
 
@@ -49,4 +51,6 @@
         public ActionResult AddFilterAnd(FormCollection collection)
         {
+            Response.Write("AddFilterAnd");
+
             CombinedFilter content = (CombinedFilter)Session["Content"];
             FilterModel fm = new FilterModel(content);
@@ -150,4 +154,6 @@
             // Add the new filter
             filterList.Add(filter);
+            Response.Write("addx:" + filter.Id);  
+
             parent.Filters = filterList.ToArray<Filter>();
 
@@ -157,4 +163,9 @@
             content.Filters = orFilters.ToArray<Filter>();
 
+
+
+            Response.Write("content add:" + content.Filters[0].Id);
+
+
             // Set Content
             Session["Content"] = content;
@@ -163,4 +174,54 @@
 
             return View("Index", fm);
+        }
+
+
+        public ActionResult DeleteFilter(Guid id)
+        {
+            //Response.Write("Delete id:" + id);
+
+            CombinedFilter masterFilter = (CombinedFilter)Session["Content"];
+
+            Response.Write("content del:" + masterFilter.Filters[0].Id);
+
+            FilterModel fm = new FilterModel(masterFilter);  
+            RemoveFilterFromFilterModel(fm, id);
+                 
+            masterFilter.Filters = ((CombinedFilter)fm.Content).Filters.ToArray<Filter>();
+            
+            // Set Content
+            Session["Content"] = masterFilter;
+
+         //   Response.Write("Delete id3:" + masterFilter.Filters.Length);
+           
+            return View("Index", fm);
+        }
+
+
+        private Filter GetFilterForId(Filter [] activeFilters, Guid id)
+        {
+            foreach (Filter f in activeFilters)
+            {
+                Response.Write(f.Id + " " + id);
+
+                if (f.Id.Equals(id))
+                {
+                    return f;
+                }
+            }
+            return null;
+        }
+
+        private FilterModel RemoveFilterFromFilterModel(FilterModel fm, Guid id)
+        {
+            Response.Write("content :" + fm.Content.Id);
+            Filter filterToRemove = GetFilterForId(fm.Content.Filters, id);
+            if (filterToRemove != null)
+            {
+                Response.Write("rrrrr:" + id);
+                fm.Filters.Remove(filterToRemove);
+            }
+
+            return fm;
         }
 
Index: /branches/WebApplication/MVC2/HLWebOKBQueryPlugin/ViewModels/FilterModel.cs
===================================================================
--- /branches/WebApplication/MVC2/HLWebOKBQueryPlugin/ViewModels/FilterModel.cs	(revision 6162)
+++ /branches/WebApplication/MVC2/HLWebOKBQueryPlugin/ViewModels/FilterModel.cs	(revision 6163)
@@ -15,4 +15,5 @@
     public class FilterModel
     {
+        private  List<bool> boolStates;
 
         private List<Filter> _filters;
@@ -46,4 +47,16 @@
         }
 
+
+        public List<Boolean> GetBoolStates()
+        {
+            if (boolStates == null)
+            {
+                boolStates = new List<Boolean>();
+                boolStates.Add(true);
+                boolStates.Add(false);
+            }
+            return boolStates;
+        }
+
     }
 }
Index: /branches/WebApplication/MVC2/HLWebOKBQueryPlugin/Views/Filter/Filters.ascx
===================================================================
--- /branches/WebApplication/MVC2/HLWebOKBQueryPlugin/Views/Filter/Filters.ascx	(revision 6162)
+++ /branches/WebApplication/MVC2/HLWebOKBQueryPlugin/Views/Filter/Filters.ascx	(revision 6163)
@@ -33,18 +33,94 @@
     <%
            
-// If type is StringComparisonFilter build thes controls
+
 if ("StringComparisonFilter".Equals(f.GetType().Name))
 {  %>
-    <%: Html.TextBox(f.Id + ".valueTextbox", ((StringComparisonFilter)f).Value)%>
-    <%: Html.Label(f.GetType().Name)%>
+    <% StringComparisonFilter filter = ((StringComparisonFilter)f); %>
+
+    <%: Html.Label(filter.Label)%>
+    <%: Html.Label("=") %>
+    <%: Html.TextBox(f.Id + ".valueTextbox", (filter.Value))%>
+    <%: Html.ActionLink("-","DeleteFilter",  f.Id )%>
     <% }
-// If type is NameStringComparisonFilter build thes controls
 else if ("NameStringComparisonFilter".Equals(f.GetType().Name))
 { %>
-    <%: Html.TextBox(f.Id + ".valueTextbox" + f.Id, new{((NameStringComparisonFilter)f).Value})%>
-    <%: Html.Label(f.GetType().Name)%>
+    <% NameStringComparisonFilter filter = ((NameStringComparisonFilter)f); %>
+    <%: Html.Label(filter.Label)%>
+    <%: Html.Label("= xxx" + f.Id)%>
+    <%: Html.TextBox(f.Id + ".valueTextbox" + f.Id,  filter.Value )%>
+    <%: Html.ActionLink("-", "DeleteFilter", new { f.Id })%>
     <% }
+else if ("StringComparisonAvailableValuesFilter".Equals(f.GetType().Name))
+{ %>
+    <% StringComparisonAvailableValuesFilter filter = ((StringComparisonAvailableValuesFilter)f); %>
+    <%: Html.Label(filter.Label)%>
+    <%: Html.Label("=")%> 
+    <%: Html.DropDownList(f.Id + ".valueDropDownList", new SelectList(filter.AvailableValues,filter.Value))%>
+    <%: Html.ActionLink("-","DeleteFilter",  f.Id )%>
+<% }
+else if ("NameEqualityComparisonByteArrayFilter".Equals(f.GetType().Name))
+{ %>
+    <% NameEqualityComparisonByteArrayFilter filter = ((NameEqualityComparisonByteArrayFilter)f); %>
+    <%: Html.Label(filter.Label)%>   
+    <%: Html.ActionLink("-","DeleteFilter",  f.Id )%>
+<% }  
+else if ("NameEqualityComparisonBoolFilter".Equals(f.GetType().Name))
+{ %>
+    <% NameEqualityComparisonBoolFilter filter = ((NameEqualityComparisonBoolFilter)f);
+    %>
+    <%: Html.Label(filter.Label)%>
+    <%: Html.Label("is")%> 
+    <%: Html.DropDownList(f.Id + ".valueDropDownList", new SelectList(((FilterModel)Model).GetBoolStates(),filter.Value)) %>
+    <%: Html.ActionLink("-","DeleteFilter",  f.Id )%>
+<% }
+else if ("NameOrdinalComparisonIntFilter".Equals(f.GetType().Name))
+{ %>
+    <% NameOrdinalComparisonIntFilter filter = ((NameOrdinalComparisonIntFilter)f);   %>
+    <%: Html.Label(filter.Label)%>
+    <%: Html.Label("is")%>    
 
-
+    <%: Html.ActionLink("-","DeleteFilter",  f.Id )%>
+<% }
+else if ("NameStringComparisonAvailableValuesFilter".Equals(f.GetType().Name))
+{ %>
+    <% NameStringComparisonAvailableValuesFilter filter = ((NameStringComparisonAvailableValuesFilter)f);   %>
+    <%: Html.Label(filter.Label)%>
+    <%: Html.Label("=")%> 
+    <%: Html.DropDownList(f.Id + ".valueDropDownList", new SelectList(filter.AvailableValues,filter.Value))%>   
+    <%: Html.ActionLink("-","DeleteFilter",  f.Id )%> 
+<% }
+else if ("NameOrdinalComparisonDoubleFilter".Equals(f.GetType().Name))
+{ %>
+    <% NameOrdinalComparisonDoubleFilter filter = ((NameOrdinalComparisonDoubleFilter)f);   %>
+    <%: Html.Label(filter.Label)%>
+    <%: Html.Label("=")%> 
+    <%: Html.TextBox(f.Id + ".valueTextbox" + f.Id,  filter.Value )%>   
+    <%: Html.ActionLink("-","DeleteFilter",  f.Id )%>
+<% }
+else if ("NameOrdinalComparisonFloatFilter".Equals(f.GetType().Name))
+{ %>
+    <% NameOrdinalComparisonFloatFilter filter = ((NameOrdinalComparisonFloatFilter)f);   %>
+    <%: Html.Label(filter.Label)%>
+    <%: Html.Label("=")%> 
+    <%: Html.TextBox(f.Id + ".valueTextbox" + f.Id,  filter.Value )%>   
+    <%: Html.ActionLink("-","DeleteFilter",  f.Id )%>
+<% }  
+    else if ("NameOrdinalComparisonFloatFilter".Equals(f.GetType().Name))
+{ %>
+    <% NameOrdinalComparisonLongFilter filter = ((NameOrdinalComparisonLongFilter)f);   %>
+    <%: Html.Label(filter.Label)%>
+    <%: Html.Label("=")%> 
+    <%: Html.TextBox(f.Id + ".valueTextbox" + f.Id,  filter.Value )%> 
+    <%: Html.ActionLink("-","DeleteFilter",  f.Id )%>  
+<% }                 
+                  
+       
+    
+    
+     
+    
+    
+    
+    
 else
 { %>
