locked
Bulk Update RRS feed

  • Question

  • Is there a way to do a bulf update in the ria services..

    For eg: i have datagrid with list of users and i want to Update age of all users to 25.

    Is there a way for this using ria..

    Tuesday, March 8, 2011 6:01 PM

All replies

  • Hi Ankit,

    I guess you'd better refer to ColinBlair's reply.  http://forums.silverlight.net/forums/p/213954/506351.aspx

    Best regards,

    Jonathan

    Thursday, March 10, 2011 4:56 AM
  • I was able to write a stored procedure call makes the bulk update..

    But now i am not able to send the notification from the service to client that the call is done..


    Any help on that..

    Thursday, March 17, 2011 1:27 PM
  • public bool Reschedule(DateTime Time)
            {
                bool m_Return = false;

                    if (this.ObjectContext.Connection.State != ConnectionState.Open)
                        this.ObjectContext.Connection.Open();

                    DbCommand cmd = this.ObjectContext.Connection.CreateCommand();
                    cmd.CommandText = "CustomerEntities.sp_Reschedule";
                    cmd.CommandType = CommandType.StoredProcedure;

                    DbParameter parm1 = cmd.CreateParameter();
                    parm1.ParameterName = "Time";
                    parm1.Direction = ParameterDirection.Input;
                    parm1.Value = Time;
                    parm1.DbType = DbType.DateTime;


    cmd.Parameters.Add(parm1);

    cmd.ExecuteScalar();
                 
                }


    Now if some how i can send some notification to the client after the execute ..

    Thursday, March 17, 2011 1:30 PM
  • You call use a WCF to call the procedure.  When it finishes, you can do something in its Completed event.


    Thursday, March 24, 2011 5:39 AM