c# - this operation is not supported in the wcf test client because it uses type system.object[] error using WCF and Entity Framework -


i trying create wcf generic methods going received ilist of different objects, once ilist comes in string tell type of object, them method validate , call function accordingly.

when "build" wcf project, completes successfully. testing wcf built in wcf test client, cannot test because each method set published, showing "this operation not supported in wcf test client because uses type system.object[]" error

this contract code:

            namespace wcf_rentacar             {                     [servicecontract]                     public interface irentacar                     {                         [operationcontract]                         void insert(string tobjeto, ilist objet);                          [operationcontract]                         void update(string tobjet, int id, ilist objet);                     }              } 

then methods set way:

            namespace wcf_rentacar             {                     {                         rentacar_entities db = new rentacar_entities();                          public void insertar(string tobject, ilist object)                         {                                 string type = tobjet;                              if (type == "user")                                 {                                     try                                     {                                             tb_seg_users u= new tb_seg_users();                                          foreach (tb_seg_users item in object)                                             {                                                 string e = item.descripcion;                                                 u.descripcion = e;                                                  agregarestado(u);                                             }                                                 object.clear();                                     }                                     catch                                     {                                      }                                 }                         }                          public void update(string tobject, int id, ilist object)                         {                                 string type = tobject;                              if (type == "user")                                 {                                     try                                     {                                         tb_seg_users u= new tb_seg_users();                                          foreach (tb_seg_estados item in objeto)                                             {                                                 string e = item.descripcion;                                                 u.descripcion = e;                                                  agregarestado(est);                                             }                                             object.clear();                                     }                                     catch                                     {                                      }                                 }                         }                     } 

i have entity models in wcf project, , on dal layer

some 1 have idea should do

thank you


Comments

Popular posts from this blog

java - Static nested class instance -

c# - Bluetooth LE CanUpdate Characteristic property -

JavaScript - Replace variable from string in all occurrences -