Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > ASP .Net > ASP .Net Web Controls > detailsview asp.net 2 and insert confirmation

Reply
Thread Tools

detailsview asp.net 2 and insert confirmation

 
 
TdarTdar
Guest
Posts: n/a
 
      11-04-2005
Hi,
using a detailsview and sql, setting the details view to insert as the
primary
view, after someone inserts the data they want to I would like to do something

eather A:

have that page show "Your Request has been Processed"

or B:
Rediret them to another page

after they click the insert button on the detailsview asp.net 2 control.

Tdar

 
Reply With Quote
 
 
 
 
Kevin Yu [MSFT]
Guest
Posts: n/a
 
      11-05-2005
Hi Tdar,

We have reviewed this issue and are currently researching on it. We will
update you ASAP. Thanks for your patience!

Kevin Yu
=======
"This posting is provided "AS IS" with no warranties, and confers no
rights."


 
Reply With Quote
 
 
 
 
Steven Cheng[MSFT]
Guest
Posts: n/a
 
      11-06-2005
Hi Tdar,

Welcome to ASPNET newsgroup.
From your description , you're using the DetailsView control to perform
insert operation (set detaulMode as "Insert") and is wondering how to make
a notify info or redirect the user to another page after successfully
inserted a new record, yes?

As for this, I think we can consider using the DetailsView control's
ItemInserted event, this event is fired after a new record is successfully
inserted. So we can just put or post processing code in the ItemInserted
event handler like:


protected void DetailsView1_ItemInserted(object sender,
DetailsViewInsertedEventArgs e)
{
lblMessage.Text = "You've successfully inserted the new record!";

// or Response.Redirect( new page url...);
}

Hope helps. Thanks,

Steven Cheng
Microsoft Online Support

Get Secure! www.microsoft.com/security
(This posting is provided "AS IS", with no warranties, and confers no
rights.)



--------------------
| Thread-Topic: detailsview asp.net 2 and insert confirmation
| thread-index: AcXhaFP/Ng9qnjQuShCKLQA62gCXSQ==
| X-WBNR-Posting-Host: 24.73.223.27
| From: "=?Utf-8?B?VGRhclRkYXI=?=" <>
| Subject: detailsview asp.net 2 and insert confirmation
| Date: Fri, 4 Nov 2005 09:51:05 -0800
| Lines: 16
| Message-ID: <712A03A7-E91F-4EF8-B69A->
| MIME-Version: 1.0
| Content-Type: text/plain;
| charset="Utf-8"
| Content-Transfer-Encoding: 7bit
| X-Newsreader: Microsoft CDO for Windows 2000
| Content-Class: urn:content-classes:message
| Importance: normal
| Priority: normal
| X-MimeOLE: Produced By Microsoft MimeOLE V6.00.3790.0
| Newsgroups: microsoft.public.dotnet.framework.aspnet.webcontro ls
| NNTP-Posting-Host: TK2MSFTNGXA03.phx.gbl 10.40.2.250
| Path: TK2MSFTNGXA01.phx.gbl!TK2MSFTNGXA03.phx.gbl
| Xref: TK2MSFTNGXA01.phx.gbl
microsoft.public.dotnet.framework.aspnet.webcontro ls:11684
| X-Tomcat-NG: microsoft.public.dotnet.framework.aspnet.webcontro ls
|
| Hi,
| using a detailsview and sql, setting the details view to insert as the
| primary
| view, after someone inserts the data they want to I would like to do
something
|
| eather A:
|
| have that page show "Your Request has been Processed"
|
| or B:
| Rediret them to another page
|
| after they click the insert button on the detailsview asp.net 2 control.
|
| Tdar
|
|

 
Reply With Quote
 
TdarTdar
Guest
Posts: n/a
 
      11-06-2005
Ah ok,
Humm much like before, so doing it in vb was like thisand this works
already thanks)

Protected Sub DetailsView1_ItemInserted(ByVal Sender As Object, ByVal e As
System.Web.UI.WebControls.DetailsViewInsertedEvent Args) Handles
DetailsView1.ItemInserted

Me.Label1.Text = "We have recived your request, thank you."
End Sub

anyways it works, Thanks.


"Steven Cheng[MSFT]" wrote:

> Hi Tdar,
>
> Welcome to ASPNET newsgroup.
> From your description , you're using the DetailsView control to perform
> insert operation (set detaulMode as "Insert") and is wondering how to make
> a notify info or redirect the user to another page after successfully
> inserted a new record, yes?
>
> As for this, I think we can consider using the DetailsView control's
> ItemInserted event, this event is fired after a new record is successfully
> inserted. So we can just put or post processing code in the ItemInserted
> event handler like:
>
>
> protected void DetailsView1_ItemInserted(object sender,
> DetailsViewInsertedEventArgs e)
> {
> lblMessage.Text = "You've successfully inserted the new record!";
>
> // or Response.Redirect( new page url...);
> }
>
> Hope helps. Thanks,
>
> Steven Cheng
> Microsoft Online Support
>
> Get Secure! www.microsoft.com/security
> (This posting is provided "AS IS", with no warranties, and confers no
> rights.)
>
>
>
> --------------------
> | Thread-Topic: detailsview asp.net 2 and insert confirmation
> | thread-index: AcXhaFP/Ng9qnjQuShCKLQA62gCXSQ==
> | X-WBNR-Posting-Host: 24.73.223.27
> | From: "=?Utf-8?B?VGRhclRkYXI=?=" <>
> | Subject: detailsview asp.net 2 and insert confirmation
> | Date: Fri, 4 Nov 2005 09:51:05 -0800
> | Lines: 16
> | Message-ID: <712A03A7-E91F-4EF8-B69A->
> | MIME-Version: 1.0
> | Content-Type: text/plain;
> | charset="Utf-8"
> | Content-Transfer-Encoding: 7bit
> | X-Newsreader: Microsoft CDO for Windows 2000
> | Content-Class: urn:content-classes:message
> | Importance: normal
> | Priority: normal
> | X-MimeOLE: Produced By Microsoft MimeOLE V6.00.3790.0
> | Newsgroups: microsoft.public.dotnet.framework.aspnet.webcontro ls
> | NNTP-Posting-Host: TK2MSFTNGXA03.phx.gbl 10.40.2.250
> | Path: TK2MSFTNGXA01.phx.gbl!TK2MSFTNGXA03.phx.gbl
> | Xref: TK2MSFTNGXA01.phx.gbl
> microsoft.public.dotnet.framework.aspnet.webcontro ls:11684
> | X-Tomcat-NG: microsoft.public.dotnet.framework.aspnet.webcontro ls
> |
> | Hi,
> | using a detailsview and sql, setting the details view to insert as the
> | primary
> | view, after someone inserts the data they want to I would like to do
> something
> |
> | eather A:
> |
> | have that page show "Your Request has been Processed"
> |
> | or B:
> | Rediret them to another page
> |
> | after they click the insert button on the detailsview asp.net 2 control.
> |
> | Tdar
> |
> |
>
>

 
Reply With Quote
 
Steven Cheng[MSFT]
Guest
Posts: n/a
 
      11-07-2005
Thanks for your response Tdar,

If there're any further question or anything else we can help, please feel
free to post here.
Thanks,

Steven Cheng
Microsoft Online Support

Get Secure! www.microsoft.com/security
(This posting is provided "AS IS", with no warranties, and confers no
rights.)
--------------------
| Thread-Topic: detailsview asp.net 2 and insert confirmation
| thread-index: AcXi+8zWJnYxnOaRT5mkOhq/peO/RQ==
| X-WBNR-Posting-Host: 65.35.95.187
| From: "=?Utf-8?B?VGRhclRkYXI=?=" <>
| References: <712A03A7-E91F-4EF8-B69A->
<>
| Subject: RE: detailsview asp.net 2 and insert confirmation
| Date: Sun, 6 Nov 2005 09:59:15 -0800
| Lines: 94
| Message-ID: <75D96551-11E7-4E14-A3C7->
| MIME-Version: 1.0
| Content-Type: text/plain;
| charset="Utf-8"
| Content-Transfer-Encoding: 7bit
| X-Newsreader: Microsoft CDO for Windows 2000
| Content-Class: urn:content-classes:message
| Importance: normal
| Priority: normal
| X-MimeOLE: Produced By Microsoft MimeOLE V6.00.3790.0
| Newsgroups: microsoft.public.dotnet.framework.aspnet.webcontro ls
| NNTP-Posting-Host: TK2MSFTNGXA03.phx.gbl 10.40.2.250
| Path: TK2MSFTNGXA01.phx.gbl!TK2MSFTNGXA03.phx.gbl
| Xref: TK2MSFTNGXA01.phx.gbl
microsoft.public.dotnet.framework.aspnet.webcontro ls:11722
| X-Tomcat-NG: microsoft.public.dotnet.framework.aspnet.webcontro ls
|
| Ah ok,
| Humm much like before, so doing it in vb was like thisand this works
| already thanks)
|
| Protected Sub DetailsView1_ItemInserted(ByVal Sender As Object, ByVal e
As
| System.Web.UI.WebControls.DetailsViewInsertedEvent Args) Handles
| DetailsView1.ItemInserted
|
| Me.Label1.Text = "We have recived your request, thank you."
| End Sub
|
| anyways it works, Thanks.
|
|
| "Steven Cheng[MSFT]" wrote:
|
| > Hi Tdar,
| >
| > Welcome to ASPNET newsgroup.
| > From your description , you're using the DetailsView control to perform
| > insert operation (set detaulMode as "Insert") and is wondering how to
make
| > a notify info or redirect the user to another page after successfully
| > inserted a new record, yes?
| >
| > As for this, I think we can consider using the DetailsView control's
| > ItemInserted event, this event is fired after a new record is
successfully
| > inserted. So we can just put or post processing code in the
ItemInserted
| > event handler like:
| >
| >
| > protected void DetailsView1_ItemInserted(object sender,
| > DetailsViewInsertedEventArgs e)
| > {
| > lblMessage.Text = "You've successfully inserted the new
record!";
| >
| > // or Response.Redirect( new page url...);
| > }
| >
| > Hope helps. Thanks,
| >
| > Steven Cheng
| > Microsoft Online Support
| >
| > Get Secure! www.microsoft.com/security
| > (This posting is provided "AS IS", with no warranties, and confers no
| > rights.)
| >
| >
| >
| > --------------------
| > | Thread-Topic: detailsview asp.net 2 and insert confirmation
| > | thread-index: AcXhaFP/Ng9qnjQuShCKLQA62gCXSQ==
| > | X-WBNR-Posting-Host: 24.73.223.27
| > | From: "=?Utf-8?B?VGRhclRkYXI=?=" <>
| > | Subject: detailsview asp.net 2 and insert confirmation
| > | Date: Fri, 4 Nov 2005 09:51:05 -0800
| > | Lines: 16
| > | Message-ID: <712A03A7-E91F-4EF8-B69A->
| > | MIME-Version: 1.0
| > | Content-Type: text/plain;
| > | charset="Utf-8"
| > | Content-Transfer-Encoding: 7bit
| > | X-Newsreader: Microsoft CDO for Windows 2000
| > | Content-Class: urn:content-classes:message
| > | Importance: normal
| > | Priority: normal
| > | X-MimeOLE: Produced By Microsoft MimeOLE V6.00.3790.0
| > | Newsgroups: microsoft.public.dotnet.framework.aspnet.webcontro ls
| > | NNTP-Posting-Host: TK2MSFTNGXA03.phx.gbl 10.40.2.250
| > | Path: TK2MSFTNGXA01.phx.gbl!TK2MSFTNGXA03.phx.gbl
| > | Xref: TK2MSFTNGXA01.phx.gbl
| > microsoft.public.dotnet.framework.aspnet.webcontro ls:11684
| > | X-Tomcat-NG: microsoft.public.dotnet.framework.aspnet.webcontro ls
| > |
| > | Hi,
| > | using a detailsview and sql, setting the details view to insert as
the
| > | primary
| > | view, after someone inserts the data they want to I would like to do
| > something
| > |
| > | eather A:
| > |
| > | have that page show "Your Request has been Processed"
| > |
| > | or B:
| > | Rediret them to another page
| > |
| > | after they click the insert button on the detailsview asp.net 2
control.
| > |
| > | Tdar
| > |
| > |
| >
| >
|

 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
DetailsView edit and insert row widths William LaMartin ASP .Net 4 03-29-2009 01:39 AM
Insert & Insert/Repeat buttons in a detailsview eagle ASP .Net Datagrid Control 0 07-12-2007 12:47 PM
Detailsview loses insert mode contents when Insert fails... cannontrodder ASP .Net 1 07-25-2006 08:38 AM
DetailsView - Changing to Insert Mode (Not By Using the Insert Button In the DetailsView Control) Feege ASP .Net Web Controls 0 12-20-2005 12:28 AM
How to access controls in Edit and Insert templates of DetailsView The_ShotSpotter_Team ASP .Net Web Controls 1 08-30-2005 08:31 PM



Advertisments
 



1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57