Note that there are some explanatory texts on larger screens.

plurals
  1. POparameter is always NULL in delete-method, dont know why
    text
    copied!<p>i'm using telerik mvc 3.</p> <p>i've got a Grid which is bound to a ViewModel. </p> <pre><code>@(Html.Telerik().Grid&lt;SampleProject.ViewModels.Location.RoomViewModel&gt;() .Name("Grid") .ToolBar(cmd =&gt; cmd.Insert()) .DataKeys(keys =&gt; keys.Add(c =&gt; c.RoomId)) .DataBinding(dataBinding =&gt; dataBinding .Ajax() .Select("Selecting", "Location") .Insert("Inserting", "Location") .Update("Updating", "Location") .Delete("Deleting", "Location" ) ) .Columns(c =&gt; { c.Bound(o =&gt; o.RoomName); c.Bound(o =&gt; o.MaxSeats); c.Bound(o =&gt; o.HasScanner); c.Bound(o =&gt; o.HasPrinter); c.Bound(o =&gt; o.HasFlipchart); c.Bound(o =&gt; o.HasBeamer); c.Command(cmd =&gt; { cmd.Edit(); cmd.Delete(); }); }) ) </code></pre> <p>the "Inserting"-method works fine (i get RoomViewModel as Parameter). The "Selecting"-Method works too, but the "Deleting"-Method doesnt work. </p> <pre><code> #region GridActions [GridAction] public ActionResult Selecting() { return View(new GridModel(this._currentLocation.Rooms)); } [AcceptVerbs(HttpVerbs.Post)] [GridAction] public ActionResult Inserting(RoomViewModel rvm) { this._currentLocation.Rooms.Add(rvm); return View(new GridModel(this._currentLocation.Rooms)); } [AcceptVerbs(HttpVerbs.Post)] [GridAction] public ActionResult Deleting(RoomViewModel rvm) { this._currentLocation.Rooms.Remove(rvm); return View(new GridModel(this._currentLocation.Rooms)); } </code></pre> <p>i tried also:</p> <pre><code> public ActionResult Deleting(int rvm) --&gt; internal error 500 - doesnt hit the breakpoint public ActionResult Deleting(string rvm) public ActionResult Deleting(object rvm) </code></pre> <p>always "NULL", any idea???</p>
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload