Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Return multiple tables to AJAX call
Message
De
06/08/2014 11:39:03
 
 
À
Tous
Information générale
Forum:
ASP.NET
Catégorie:
AJAX
Titre:
Return multiple tables to AJAX call
Versions des environnements
Environment:
VB 9.0
OS:
Windows Server 2012
Network:
Windows 2008 Server
Database:
MS SQL Server
Application:
Web
Divers
Thread ID:
01605232
Message ID:
01605232
Vues:
48
Hi all

I need to return two data tables from a stored proc via an AJAX call, but it's giving me an "Internal Server Error" on the return to the AJAX call

AJAX Call:
    function grid_update()
    {
        $.ajax({
            type: 'POST',
            dataType: 'json',
            contentType: 'application/json',
            url: 'HeartBeat.aspx/UpdateGridData'
        })
        .done(function (response) {
            SetGrids(response.d);
        })
        .fail(function(){
        alert("Grid Update Error: " + arguments[2]);
                });
      }
The WebMethod being called:
       [WebMethod]
        public static DataSet UpdateGridData()
        {
            cSettings cSet = GetSettings();
            //ExecuteDataset(string commandText, string ConnectionName)
            DataSet ds1 = new DataSet();
            string SPCommand = "exec HFCJobLog.dbo.GetHBData 'all', ' " + cSet.TimeStart.ToString() + "', " + cSet.TimeSlice.ToString();
            ds1 = BLL.cJobs.GetHBData(SPCommand);
            return ds1;
        }
Could someone please 'splain to me (in words of one syllable preferably) how I need to go about this?

thanks
"You don't manage people. You manage things - people you lead" Adm. Grace Hopper
Pflugerville, between a Rock and a Weird Place
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform