Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. General Programming
  3. C#
  4. The DataSource Window in VS2005 is not recognizing a DataSet served through a WebService

The DataSource Window in VS2005 is not recognizing a DataSet served through a WebService

Scheduled Pinned Locked Moved C#
securityquestion
1 Posts 1 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • A Offline
    A Offline
    Andre Vianna
    wrote on last edited by
    #1

    I've developed a webservice serving a data set. This is the code: ----------------------------------------------------------------- using System; using System.Web; using System.Web.Services; using System.Web.Services.Protocols; using System.Data; using System.Data.SqlClient; [WebService(Namespace = "http://localhost/WSTest/")] [WebServiceBinding(ConformsTo = WsiProfiles.BasicProfile1_1)] public class ERPService : System.Web.Services.WebService { public ERPService () { } [WebMethod] public DataSet listaEntidades() { SqlConnection con = new SqlConnection("[hidden for security reasons]"); SqlDataAdapter daEntidade = new SqlDataAdapter("SELECT * FROM Entidade", con); DataSet ds = new DataSet(); con.Open(); daEntidade.Fill(ds, "Entidade"); con.Close(); return ds; } } ----------------------------------------------------------------- It works fine in the browser but when I create a new window project and try to add this service as a data source to bind it to a DataGridView, the interface does not add the DataSource to the window. It reconizes the service ok the reference is added to the project but no data source is displayed. What's wrong? André Pires

    1 Reply Last reply
    0
    Reply
    • Reply as topic
    Log in to reply
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes


    • Login

    • Don't have an account? Register

    • Login or register to search.
    • First post
      Last post
    0
    • Categories
    • Recent
    • Tags
    • Popular
    • World
    • Users
    • Groups