Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 626657
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 13, 20262026-05-13T19:26:33+00:00 2026-05-13T19:26:33+00:00

I am using UltraGrid for inserting data in table. The problem is that i

  • 0

I am using UltraGrid for inserting data in table. The problem is that i need to do insert,update, delete with web service. I am getting dataSet from web service and display it into grid but when I do some changes on the grid for example insert or update data, I need also to send new dataSet to web service so that web service do update data.

This is the table
ID (PK,int,not null)
Name(nvarchar 100,null)

This is the code for client side:

Public Sub Refresh()
    Dim p As localhost.Service1 = New localhost.Service1
   'bind datatable to UltraGrid 
    UltraGrid1.DataSource = p.GetData()
    End Sub

This is the code for web service for getting data from table:

<WebMethod()> Public Function GetData() As DataSet
    Dim custDA As SqlDataAdapter = New SqlDataAdapter("SELECT  ID,Name FROM Btable", nwindConn)
    Dim custDS As DataSet = New DataSet()
    custDA.MissingSchemaAction = MissingSchemaAction.AddWithKey
    custDA.Fill(custDS, "Btable")
    GetData= custDS
End Function

This all working fine but now I want to insert new row to grid and send that to web service and insert it from there. How I can do that? Thanks!

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-13T19:26:33+00:00Added an answer on May 13, 2026 at 7:26 pm

    You should handle the event “AfterRowInsert” of the UltraTable and retrieve the values from the new row. You could then call a new web method on your web service that would insert the row into your database.

    The web method may look something like this….

    <WebMethod()> Public sub AddRecord(id as integer, name as string)
    
    dim sSql as string = "INSERT INTO Btable (ID, Name) VALUES (@ID, @Name)"    
    Dim oCmd as SqlCommand = nwindConn.CreateCommand()
    oCmd.CommandText = sSql
    oCmd.Parameters.Add("@ID", SqlDbType.Int).Value = id
    oCmd.Parameters.Add("@ID", SqlDbType.VarChar).Value = name
    oCmd.ExecuteNonQuery()
    
    End Function 
    

    If your ID column is an auto number it would be slightly different. In this situation your web method would only accept a name parameter and would return the ID of the new record. In MS SQL Server you can get this by calling SCOPE_IDENTITY() after your INSERT query.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Using the Infragistics UltraGrid (e.g. myGrid ), I want to: Hook an event that
I am trying to show xml data in an Ultragrid. I have tried using
Using Yii, I want to delete all the rows that are not from today.
using VB.Net2010 I need to call a C# DLL The problem I have is
I am using Infragistics UltraGrid in a Windows Forms application. I need an event
I need to create a winforms grid with 3 levels, using infragistics ultragrid. Level
Using Server.Transfer to show a page that informs the user that the web site
I am using infragistic's ultragrid and I want to show the text portion of
Using a populated Table Type as the source for a TSQL-Merge. I want to
Using linq2sql I'm trying to take the string in txtOilChange and update the oilChange

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.