473,320 Members | 1,948 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,320 software developers and data experts.

Formview Problems

Hello,

This problem is really frustrating to me. I have a FormView on my page
where I do all of the binding programatically. In other words, I don't
use a datasource control but I bind to the DataSource property. I have
defined an ItemTemplate which is necessary that has only a single link
button with a command of "New." I also have defeined an
InsertItemTemplate with two link buttons with command names of "Insert"
and "Cancel", and various other controls to edit the values I need to.
I have overrode the ModeChanging event to programatically change the
formview mode by calling the ChangeMode method. If I don't override
this function, the ASP. NET infrastructure throws and exception telling
me that I have to override it. Now, when I press the Cancel link
button when in insert mode, the formview DOES NOT revert back to the
default mode, which is readonly, and contains the single link button
with a command name of "New." If I press it again, it does. In other
words, I have to press it twice in order for it to revert back to the
correct mode.

I think there is some sort of bug in the form view control and this is
extremely frustrating because there is no help with respect to this
anywhere.

I hope a MSFT MVP reads this message, because these things should be
easily able to be coded and shouldn't cause any problems.

Hammad

Jan 6 '06 #1
0 1330

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

0
by: Neil Young | last post by:
Hello group, I'm referring to a "rather old thread" (April 21st 2005). Because I also ran into problems with ASP.NET 2.0 formview and DBNull, but found a way around, I would like to share my...
3
by: Jéjé | last post by:
Hi, I want to dynamically load an ASCX control which contain a formview. And I want to render the result into a string. but I receive some errors like: Control 'FormView1' of type 'FormView'...
0
by: Metal2You | last post by:
I'm working on an ASP.NET 2.0 application in Visual Studio 2005 that accesses a Sybase database back end. We're using Sybase SQL Anywhere 9.0.2.3228. I have installed and registered the Sybase...
4
by: Rob | last post by:
Hey all, So.. a simple FormView/SqlDataSource to handle inserting records into a table. The table has a primary key that the user enters (eg DiscountCode). If the user enters a duplicate the...
2
by: Islamegy® | last post by:
I'm use FormView for editing a photo gallery... I add FileUpload control to upload images to the Gallery. I'm binding my Formview to objectdatasource i tried upload images onItemInserting &...
0
by: MRW | last post by:
For some strange reason, I'm having problems finding a GridView in a FormView. I keep getting the error: Object reference not set to an instance of an object. I have the code below, it's very...
2
by: sck10 | last post by:
Hello, I have 3 objects: LinkButton GridView FormView The LinkButton is used to open the FormView in Insert mode. The GridView provides a list of products. When the "Select" link is
2
by: Phil Sandler | last post by:
I am trying to do something which seems (to me) to be very simple, and yet I can't seem to figure it out. I have a gridview and a formview. When a user clicks "select" in the gridview, the...
0
by: =?Utf-8?B?TGFkaXNsYXYgTXJua2E=?= | last post by:
Hello, I read some msdn and other articles about how does databinding among DataSource controls and FormView / GridView controls works but I still don't fully understand to this blackbox. I have...
0
by: ryjfgjl | last post by:
ExcelToDatabase: batch import excel into database automatically...
0
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
1
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: jfyes | last post by:
As a hardware engineer, after seeing that CEIWEI recently released a new tool for Modbus RTU Over TCP/UDP filtering and monitoring, I actively went to its official website to take a look. It turned...
0
by: ArrayDB | last post by:
The error message I've encountered is; ERROR:root:Error generating model response: exception: access violation writing 0x0000000000005140, which seems to be indicative of an access violation...
1
by: PapaRatzi | last post by:
Hello, I am teaching myself MS Access forms design and Visual Basic. I've created a table to capture a list of Top 30 singles and forms to capture new entries. The final step is a form (unbound)...
0
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
0
by: Defcon1945 | last post by:
I'm trying to learn Python using Pycharm but import shutil doesn't work
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.