显示身份证号,提交注册后, [英] Display Id no.,after registration submit,

查看:89
本文介绍了显示身份证号,提交注册后,的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

亲爱的朋友们!

我在asp.net c#中制作了一个注册表,它运行良好.

但是我需要做的一件事是,在提交表单之后,我给出了一条消息(JAVASCRIPT),它将弹出并我写了一条消息记录已成功提交".

提交后我需要一条消息....因为,记录提交成功,您的id是1001之类的东西.

我需要使用此ID进行访问,

因此,我还有另一个可以使用此ID访问的Web表单.
在此Webform中,我有5个文本框.

假设如果我使用该ID,则以这种形式.....如果我在第一个文本框中输入1001,则它应该在其他文本框中显示所有相关的1001.

告诉我在提交注册表后如何显示消息.
我想要在提交"按钮后发送一条消息(例如,您的ID是1002之类的东西)

谢谢,请帮助我解决这个问题

Dear Frnds !!

I made a registration form in asp.net c#, its running fine.

But one thing i need to do is, after submitting the form i gave a message(JAVASCRIPT) and it will be pop up and i wrote a message Records Successfully submitted.

and i need a message after submitting....as, Records Successfully submitted and ur id is 1001 something like that.

I need to access with this id,

SO I HAVE A ANOTHER WEBFORM To ACCESS WITH THIS ID.
In this Webform I have 5 Textboxes.

Suppose if i use that id, in this form.....if i enter 1001 in first textbox it should display all the related 1001 in other textboxes.

SO TELL ME HOW TO DISPLAY A MESSAGE, AFTER SUBMITTING THE REGISTRATION FORM.
I want a message after submit button (Like this your Id is 1002 something like that)

Thanks, Please help me this problem

推荐答案

此链接可能会对您有所帮助
http://stackoverflow.com/questions/5825165/javascript-alert- showmessage-from-asp-net-code-behind [ ^ ]
This link may help you
http://stackoverflow.com/questions/5825165/javascript-alert-showmessage-from-asp-net-code-behind[^]


您可以使用客户端脚本管理器,即

YOu can use client script manager i.e.

ClientScript.RegisterStartupScript(GetType(), ClientID, "alert('Successfully submitted and ur id is " + id + " ');", true);



这应该是提交代码后的最后一行



this should be last line after submitting your code


您好,Rajnith,

对于您的第一页,您可以选择:

1.一个存储过程,它将返回您上次提交的ID的值,并在消息中显示该值.

2.提取最后插入的记录,然后选择时间戳为最新的"id"(如果表中有任何列用于时间戳).

我建议使用首选方法,因为它省时.

对于第二页,您可以获取对象数据源中的所有记录,并将文本框绑定到其字段,并以"id"作为关键字段.

希望对您有帮助!

快乐编码:)
Hi Rajnith,

For your first page you can opt for:

1. A stored procedure which would return you the last submitted ID''s value and you show that in your message.

2. Fetch the last inserted record and select the "id" where timestamp is latest(if you''ve any column for timestamp in your table).

I''d suggest to use first option because it''s time efficient.

For your second page, you can fetch all the records in a object data source and bind your textboxes to it''s fields keeping "id" as key field.

Hope this helps you !

Happy Coding :)


这篇关于显示身份证号,提交注册后,的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆