For those new to message boards please try to follow a few simple rules when posting your question.
Choose the correct forum for your message. Posting a VB.NET question in the C++ forum will end in tears.
Be specific! Don't ask "can someone send me the code to create an application that does 'X'. Pinpoint exactly what it is you need help with.
Keep the subject line brief, but descriptive. eg "File Serialization problem"
Keep the question as brief as possible. If you have to include code, include the smallest snippet of code you can.
Be careful when including code that you haven't made a typo. Typing mistakes can become the focal point instead of the actual question you asked.
Do not remove or empty a message if others have replied. Keep the thread intact and available for others to search and read. If your problem was answered then edit your message and add "[Solved]" to the subject line of the original post, and cast an approval vote to the one or several answers that really helped you.
If you are posting source code with your question, place it inside <pre></pre> tags. We advise you also check the "Encode "<" (and other HTML) characters when pasting" checkbox before pasting anything inside the PRE block, and make sure "Use HTML in this post" check box is checked.
Be courteous and DON'T SHOUT. Everyone here helps because they enjoy helping others, not because it's their job.
Please do not post links to your question into an unrelated forum such as the lounge. It will be deleted. Likewise, do not post the same question in more than one forum.
Do not be abusive, offensive, inappropriate or harass anyone on the boards. Doing so will get you kicked off and banned. Play nice.
If you have a school or university assignment, assume that your teacher or lecturer is also reading these forums.
No advertising or soliciting.
We reserve the right to move your posts to a more appropriate forum or to delete anything deemed inappropriate or illegal.
I am trying to show display reset password screen if data reader fetches records from the database matching the current user's information.
However, no matter what I try, I always get the following message:
Reset password link has expired.It was for one time use only
Any idea what I need to change in the code below?
Thanks in advance
Protected Sub Page_Load(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Load
If Not Page.IsPostBack Then
Dim dr As OleDbDataReader
'Here we will check from the passed querystring that if the email id/username and generated unique code is same then the panel for resetting password will be visible otherwise not
cmd = New OleDbCommand("select UserName,myemail,[UniqueCode] from tblusers where [UniqueCode]=@uniqueCode and (myEmail=@emailid or UserName=@username)", con)
If con.State = ConnectionState.Closed Then
dr = cmd.ExecuteReader()
If dr.HasRows Then
ResetPwdPanel.Visible = True
ResetPwdPanel.Visible = False
lblExpired.Text = "Reset password link has expired.It was for one time use only"
Catch ex As Exception
lblStatus.Text = "Error Occured: " & ex.Message.ToString()
I have been tasked with moving an ASP .NET production servers web application from a 2008 Windows server to a 2012 Windows server. I do not have the application's source code and only have the deployed to IIS application files. Can I do this and if so does anyone know of an artical to instruct me on doing so?
This is more a CSS issue. You can't print to the client's machine via asp.net code, and your asp.net code runs in its entirety before sending anything to the client so you can't "loop" the way you are intending.
Instead send all 7 pages to the client with the relevant css that designates where the page breaks are and the client will need to print from their browser (no you can't do that automatically either, neither can you force them to print) and the documents will be on their own pages. Google for css page breaks or for print style css in general.
I'm struggling with navigation in asp.net mvc and URLs.
When you are visiting your profile at facebook, the url is facebook.com/yourusername.
At your profile there is a menu with the following links: Timeline, About, Friends etc.
When you click on one of these links, for example Photos, the URL is changed to facebook.com/yourusername/Photos, and the photos are rendered. The menu described above are still there, and so also the profile picture and the cover picture. Its like a partial view has rendered viewing the photos.
I want to accomplish this effect in my project, but I don't know how to do it. I have tried to do it with Partial view but the problem is that the URL is not changed when the partial view is rendered.
Anyone can help me with this? How should I structure it?