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. One Problem

One Problem

Scheduled Pinned Locked Moved C#
helpcsharpdatabasesql-serversysadmin
2 Posts 2 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.
  • P Offline
    P Offline
    Preeti1979
    wrote on last edited by
    #1

    hi.... i have made two fields in SQL server 2005 named DistrictId smallint and DistrictName varchar(100).In a web application (language C#) i have made a form in which i have made a text box in which user will enter the name of the district which he want to modify.i want a code for the purpose that user will enter the name of district and when he click on the button named MODIFY the district name will be modified.Please help me as soon as possible...........

    B 1 Reply Last reply
    0
    • P Preeti1979

      hi.... i have made two fields in SQL server 2005 named DistrictId smallint and DistrictName varchar(100).In a web application (language C#) i have made a form in which i have made a text box in which user will enter the name of the district which he want to modify.i want a code for the purpose that user will enter the name of district and when he click on the button named MODIFY the district name will be modified.Please help me as soon as possible...........

      B Offline
      B Offline
      Bardy85
      wrote on last edited by
      #2

      SqlParameter[] myparm = new SqlParameter[2]; myparm[0] = new SqlParameter("@DistrictNewName", this.txtDistricNewName.Text); myparm[1] = new SqlParameter("@DistrictName", this.txtDistricName.Text); String SqlQuery = "UPDATE TableName SET DistrictName = @DistrictNewName WHERE DistrictName = DistrictName"; This should get you started.

      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