Help please: Method not found: 'System.String System.String.TrimEnd(Char)

Help please: Method not found: 'System.String System.String.TrimEnd(Char)

NemaAgapeNemaAgape Posts: 2Questions: 1Answers: 0

Using EditorGenerator files.
Tried to test page. Received the following error:

System.MissingMethodException
HResult=0x80131513
Message=Method not found: 'System.String System.String.TrimEnd(Char)'.
Source=DataTables-Editor-Server
StackTrace:
at DataTables.DtRequest.HttpData(IEnumerable1 dataIn, String cultureStr) in /home/vagrant/DataTablesSrc/extensions/Editor-NET/DataTables-Editor-Server/DtRequest.cs:line 95 at DataTables.DtRequest._Build(IEnumerable1 rawHttp, String culture) in /home/vagrant/DataTablesSrc/extensions/Editor-NET/DataTables-Editor-Server/DtRequest.cs:line 270
at DataTables.DtRequest..ctor(IEnumerable1 rawHttp, String culture) in /home/vagrant/DataTablesSrc/extensions/Editor-NET/DataTables-Editor-Server/DtRequest.cs:line 223 at DataTables.Editor.Process(NameValueCollection data, String culture) in /home/vagrant/DataTablesSrc/extensions/Editor-NET/DataTables-Editor-Server/Editor.cs:line 933 at DataTables.Editor.Process(HttpRequest request, String culture) in /home/vagrant/DataTablesSrc/extensions/Editor-NET/DataTables-Editor-Server/Editor.cs:line 959 at EditorGenerator.Controllers.CERTLogsController.CERTLogs() in C:\Users\AmenK\source\repos\NewCERTLog\EditorGenerator\EditorGenerator\EditorGenerator\Controllers\CERTLogsController.cs:line 30 at System.Web.Http.Controllers.ReflectedHttpActionDescriptor.ActionExecutor.<>c__DisplayClass10.<GetExecutor>b__9(Object instance, Object[] methodParameters) at System.Web.Http.Controllers.ReflectedHttpActionDescriptor.ActionExecutor.Execute(Object instance, Object[] arguments) at System.Web.Http.Controllers.ReflectedHttpActionDescriptor.ExecuteAsync(HttpControllerContext controllerContext, IDictionary2 arguments, CancellationToken cancellationToken)

Don't know where to start looking.

Here's the controller:

        using System;
        using System.Collections.Generic;
        using System.Net.Http.Formatting;
        using System.Web;
        using System.Web.Http;
        using DataTables;
        using EditorGenerator.Models;

        namespace EditorGenerator.Controllers
        {
            public class CERTLogsController : ApiController
            {
                [Route("api/CERTLogs")]
                [HttpGet]
                [HttpPost]
                public IHttpActionResult CERTLogs()
                {
                    var request = HttpContext.Current.Request;
                    var settings = Properties.Settings.Default;

                    using (var db = new Database(settings.DbType, settings.DbConnection))
                    {


            var response = new Editor(db, "CERTLogsNew", "ID")
                .Model<CERTLogsModel>()
                 .Process(request)
    .Data();         //THIS IS THE SPOT WHERE THE ERROR SHOWS UP

            return Json(response);
        }
    }
}

}

This question has an accepted answers - jump to answer

Answers

  • allanallan Posts: 63,572Questions: 1Answers: 10,482 Site admin
    Answer ✓

    Hi,

    Apologies - we are going to do an Editor 1.9.4 which fixes this issue soon (this was the commit that fixes it).

    You can download that git repo and build new dlls if you need, or I can zip them up and send them over if you prefer.

    Allan

  • MikeZ**MikeZ** Posts: 9Questions: 2Answers: 0

    Same problem here - targeting .NET framework 4.7.2. Error occurs on my line:

    Dim dtReq As DataTables.DtRequest = New DataTables.DtRequest(myListOfHTTPRequestFormKeys)
    
  • NemaAgapeNemaAgape Posts: 2Questions: 1Answers: 0

    Thanks Allan.
    If you could email them to me that would be great.

    Thanks again.

  • MikeZ**MikeZ** Posts: 9Questions: 2Answers: 0

    Hi Allan - is there a way we can sign up to be alerted when new releases are available? I'd be keen to get 1.9.4 as soon as it's available.

  • MikeZ**MikeZ** Posts: 9Questions: 2Answers: 0

    Tried changing my target Framework to 4.6 and 4.8 as well as the original 4.7.2 - same problem in each.

  • allanallan Posts: 63,572Questions: 1Answers: 10,482 Site admin

    Editor 1.9.4 is now available with the fix. You can grab the latest from our download page or from Nuget.

    Allan

  • MikeZ**MikeZ** Posts: 9Questions: 2Answers: 0

    1.9.4 fixed the issue for me. Cheers!

  • jeremyleffjeremyleff Posts: 4Questions: 2Answers: 0

    I am currently using 2.0.6 installed through NuGet and having the same issue. Any advice?

  • allanallan Posts: 63,572Questions: 1Answers: 10,482 Site admin

    Exactly the same error for TrimEnd? I've just grep'd our source and the two instances of where it is being used uses the more compatible array of characters, per my commit above.

    What version of .NET Framework are you using?

    Allan

Sign In or Register to comment.