Skip to main content

All Questions

Tagged with
0 votes
0 answers
37 views

Passing two parameters (IFormFile and a string) with JSON to C#

Versions: ASP.NET and Web Tools - 17.10.341.11210 C# Tools - 4.10.0-3.24312.19+ JQuery - 3.3.1.js JS - 2.8.3.js I'm trying to pass an IFormFile and a string from a JSON file select and a string input. ...
Kevin Fischer's user avatar
1 vote
1 answer
92 views

AJAX POST call to a controller is passing NULL

Call from View $.ajax({ url: _urls.saveNoteDetailsUrl, type: "POST", cache: false, contentType: "application/json", data: JSON.stringify(inputModel), ...
Pakshirajan's user avatar
1 vote
1 answer
37 views

Attempting to pass a list of objects using ajax to my controller yields null data

I'm passing a list of objects in JSON to my controller, the communication appears to be working but the data coming into my controller that I am passing is coming up null. I've scoured so many ...
SpacedGano's user avatar
1 vote
1 answer
147 views

update div without page reload using ajax or a quick tool

I have the following form: <div class=" modal-dialog p-3 shadow-xl modal-xl" id="myModal"> <form method="post" asp-action="Edit" asp-controller=&...
Vinicius Maciel Pires's user avatar
1 vote
0 answers
84 views

asp.net webapi works in browser and postman, but Jquery Ajax can't parse the returned JSON object

Fiddled with every imaginable combination of webapi controller and jquery ajax script which, when debugging, does make a get call to the controller, but it won't parse the data (in debug, the data is ...
MC9000's user avatar
  • 2,300
0 votes
1 answer
127 views

How to read a c# server side value in jquery

I've a JArray response value like below {[ { "id": "90b254dc-3fcd-4e7c-9943-59bce366ccdc", "invoice_number": "510002500007368" } ]} i'm getting ...
user avatar
0 votes
1 answer
50 views

How to get a simple JSON string from response through jQuery

I have a simple jQuery function that calls a controller action which should return a JSON string. However, I am unable to get the value of the string. The popup box just says 'undefined'. I have ...
Zenacity's user avatar
  • 296
0 votes
3 answers
2k views

Upload files using .Net 6 MVC model biding serialization by jQuery Ajax/JSON

Need to upload files using MVC model biding by AJAX jQuery/JSON. I was uploading with a normal submit form, but now I need to change to AJAX. How can I do this? I mean, biding using MVC and AJAX, ...
Guto Barroso's user avatar
-1 votes
1 answer
371 views

Auto map JSON AJAX returned data to table row in Jquery/JavaScript

Ok I have created a tab with a table inside of it as follows - function createTab(Name, id) { var $button = $('<button/>', { 'class': 'tablinks', 'onclick': 'return false;', ...
Corey Gashlin's user avatar
-3 votes
3 answers
1k views

jQuery ajax passing null to controller in ASP .NET MVC

I am trying to send stringified array from view with $.ajax but I am constantly getting null in controller. This is controller function: [HttpPost] public void SaveColumnsToDb(string data) ...
forrestDumb's user avatar
0 votes
0 answers
265 views

Delay between ajax call and Controller method receiving

I have a page in which I execute an ajax call to an ActionResult passing a JSON as data. Ajax Call: $.ajax({ contentType: "application/json; charset=utf-8", traditional: true,...
Gabriel Nazato's user avatar
0 votes
1 answer
147 views

Jquery datatables in razor view with thousands of rows/records

I'm developing a project that, inside a razor view, calls an external server and retrieves a json file (WebRequest, StreamReader on response) that I use to build a table. I don't have access to the ...
ReneRam's user avatar
  • 81
0 votes
2 answers
37 views

Loop nested array values using jQuery

Using the following JSON below, how do I loop the inner Errors and Messages values using jQuery: JSON Format: { "PagesCreated":0, "AssetsCreated":0, "AssetsUpdated&...
seanrco's user avatar
  • 1,039
0 votes
1 answer
932 views

Getting text/html Response instead of application/json on user machine in case of Exception

I am experiencing strange issue with JSON response. MVC Application A hosted on Server A. when user browse the URL which internally calls MVC action for fetching data in UI using JQuery Ajax. MVC ...
Dinesh Prajapati's user avatar
0 votes
1 answer
192 views

Return list to Partial View using JSon

I am trying to get a list of Categories and along with that list I want to show the number or Count of records that match the category. I have the Json in the controller. Before I just returned a list ...
S.Purtan's user avatar
  • 125

15 30 50 per page
1
2 3 4 5
70