Click here to Skip to main content
12,997,210 members (75,952 online)
Rate this:
Please Sign up or sign in to vote.
See more:
Hello, friends.
Please help me.
i have a web service, that execute stored procedure, and return data set:
using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.Services;
using System.Data.SqlClient;
using System.Data;
using System.Web.Configuration;
using System.Xml;

namespace usingparameterwebservice
    /// <summary>
    /// Summary description for mywebservice
    /// </summary>
    [WebService(Namespace = "create_request")]
    [WebServiceBinding(ConformsTo = WsiProfiles.BasicProfile1_1)]
    // To allow this Web Service to be called from script, using ASP.NET AJAX, uncomment the following line.
    // [System.Web.Script.Services.ScriptService]
    public class Service1 : System.Web.Services.WebService
        string constring = WebConfigurationManager.ConnectionStrings["Name"].ToString();
        SqlConnection conn;
        SqlCommand comm;
 [WebMethod(Description = "Просмотр заявки")]
        public DataSet Select(string Reques_id, string nameproc)
            SqlConnection myConn = new SqlConnection(constring);
            SqlDataAdapter myData = new SqlDataAdapter(nameproc, myConn);
            myData.SelectCommand.CommandType = CommandType.StoredProcedure;
            myData.SelectCommand.Parameters.Add(new SqlParameter("@id", SqlDbType.Char, 5));
            myData.SelectCommand.Parameters["@id"].Value = Reques_id;

            DataSet ds = new DataSet();
            return ds;

The stored procedure do simple select

I need to do a aspx page, where will be a table with data from stored procedure.
How to call web service and retrieve data in normal view from web-service.

Please help!
Posted 7-May-13 21:40pm

1 solution

Rate this: bad
Please Sign up or sign in to vote.

Solution 1


This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

  Print Answers RSS
Top Experts
Last 24hrsThis month

Advertise | Privacy | Mobile
Web02 | 2.8.170622.1 | Last Updated 8 May 2013
Copyright © CodeProject, 1999-2017
All Rights Reserved. Terms of Service
Layout: fixed | fluid

CodeProject, 503-250 Ferrand Drive Toronto Ontario, M3C 3G8 Canada +1 416-849-8900 x 100