troubleshooting Question

mvc webapi with jquery ajax

Avatar of ITsolutionWizard
ITsolutionWizardFlag for United States of America asked on
2 Comments2 Solutions14 ViewsLast Modified:
I have super simple webapi call. and when I use aspx/c#, everything is working.
so I try to use ajax jquery to call. and I always get error, but it does not tell me the error.

I also test it with postman using get or post method. They are still working on postman.
so I guess what I need to do with the code below when postman is working....

<script src=""></script>
     <script type="text/javascript">                  
         function GetFleetList()
               type: "GET",
               url: "",                            
               dataType: "json",
               contentType: "application/json;charset=utf-8",
               success: function ()
                error: function (request, message, error)
                              alert("Error" + error + " " + message + " " );

        public List<Domain.Fleet> GetFleetListTestGet()
            #region mapping parms
            _fleet.FleetMasterType = "Tow";
            return _masterFleet.GetFleetList(_fleet);
Systems architect
Join our community to see this answer!
Unlock 2 Answers and 2 Comments.
Start Free Trial
Learn from the best

Network and collaborate with thousands of CTOs, CISOs, and IT Pros rooting for you and your success.

Andrew Hancock - VMware vExpert
See if this solution works for you by signing up for a 7 day free trial.
Unlock 2 Answers and 2 Comments.
Try for 7 days

”The time we save is the biggest benefit of E-E to our team. What could take multiple guys 2 hours or more each to find is accessed in around 15 minutes on Experts Exchange.

-Mike Kapnisakis, Warner Bros