Solved

Web Developr Express and Gridview control

Posted on 2013-01-20
2
334 Views
Last Modified: 2013-01-20
I have a weird issue, I can't delete or update the first record I view in a gridview table, subsequent records I can delete, update etc.

I also get another issue, if I make any of the columns read only and then try and update a non read only column, the data will not change, also does not allow me to delete that record either. If I take read only off, it's ok.

Any ideas ?

I'm using web developer express 2010 and SQL 2005.
0
Comment
Question by:ndr-itsolutions
2 Comments
 
LVL 6

Accepted Solution

by:
esolve earned 500 total points
ID: 38798247
Do you have any code samples? Do you use automatic row update/delete or do you do it manually?

Setting the commandname of the edit buttons is important eg. The default "edit" will be used to do inline editing.

If you manually coding it and you use e.item.itemtype == GridItemType.AlternatingItem in the databind event it will only update every 2nd row.

If I remember correctly you're not allowed to set readonly on a column because obviosly you're explicitly denying updates/delete on that column or row.
0
 

Author Closing Comment

by:ndr-itsolutions
ID: 38798260
Brilliant, your last statement is spot on, I have removed the read only flag and can now edit and delete. I also under stand why.
0

Featured Post

PRTG Network Monitor: Intuitive Network Monitoring

Network Monitoring is essential to ensure that computer systems and network devices are running. Use PRTG to monitor LANs, servers, websites, applications and devices, bandwidth, virtual environments, remote systems, IoT, and many more. PRTG is easy to set up & use.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

This article explains how to reset the password of the sa account on a Microsoft SQL Server.  The steps in this article work in SQL 2005, 2008, 2008 R2, 2012, 2014 and 2016.
JSON is being used more and more, besides XML, and you surely wanted to parse the data out into SQL instead of doing it in some Javascript. The below function in SQL Server can do the job for you, returning a quick table with the parsed data.
This video shows how to set up a shell script to accept a positional parameter when called, pass that to a SQL script, accept the output from the statement back and then manipulate it in the Shell.
Via a live example, show how to backup a database, simulate a failure backup the tail of the database transaction log and perform the restore.

830 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question