View Single Post
  #1 (permalink)  
Old 07-09-2009, 09:30 AM
ersecchio ersecchio is offline
Junior Member
 
Posts: 5
Default create a new filter via zimlet (ZmFilterRule)?

hi,
I'm developing an zimlet for creating a FILTER

i' use this code:

Code:
this._filter = new ZmFilterRule("name filter ",true);
this._filter.setName("test");
this._condition = new ZmCondition(ZmFilterRule.C_FROM,ZmFilterRule.OP_MATCHES,"myserver@sever.net");
this._action = new ZmAction(ZmFilterRule.A_FOLDER,"myfolder");
this._filter.addCondition(this._condition);
this._filter.addAction(this._action);
this._filterRule = new ZmFilterRules(this._appCtxt);
this._filterRule.addRule(this._filter);

but this code clear the the old filter and create only the filter "name filter"...

how can I create a new filter without removing the old filter?

Tnx
Reply With Quote