Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 9165869
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 17, 20262026-06-17T15:00:40+00:00 2026-06-17T15:00:40+00:00

I need help in VB (no C# or Javascript, please — I’m clueless with

  • 0

I need help in VB (no C# or Javascript, please — I’m clueless with those languages)
I have also checked all the “questions that may already have your answer — and those that were in VB didn’t match my situation or were resolved by using AutoPostback,coding a textChanged event, or adding ontextchanged= to the textbox field — I have all of these in my code already.

I can’t seem to get the TextChanged event to fire despite setting the AutoPostBack to true.
Even after creating at submit button it still won’t fire, what have I left out?

What I’m trying to accomplish:
I want the Finish Date to set to a date 30 days after the Start Date if and only if the user edits a start date.
Otherwise just display in the Finish Date whatever would have originally displayed there.
Both dates are allowed to be null in the database and both are defined as datetime.

In Default.aspx

<asp:FormView ID="FormView1" runat="server" DataKeyNames="MASTERID_Action" 
DataSourceID="srcAction">
<EditItemTemplate>
MASTERID_Action:
<asp:Label ID="MASTERID_ActionLabel1" runat="server" 
Text='<%# Eval("MASTERID_Action") %>' />
<br />
Action_StartDate:
<asp:TextBox ID="Action_StartDateTextBox" runat="server" 
Text='<%# Bind("Action_StartDate") %>' 
ontextchanged="Action_StartDateTextBox_TextChanged" AutoPostBack="True" />         <rjs:PopCalendar ID="StartDateCal" runat="server" Control="Action_STartDateTextBox" />
<br />
Action_FinishDate:
<asp:TextBox ID="Action_FinishDateTextBox" runat="server" 
Text='<%# Eval("Action_FinishDate") %>' />
<br />
<asp:Button ID="SubmitButton1" runat="server" Text="Refresh" 
onclick="SubmitButton1_Click" />
<asp:LinkButton ID="UpdateButton" runat="server" CausesValidation="True" 
CommandName="Update" Text="Update" />
&nbsp;<asp:LinkButton ID="UpdateCancelButton" runat="server" 
CausesValidation="False" CommandName="Cancel" Text="Cancel" />
</EditItemTemplate>

In Default.aspx.vb

Partial Class _Default
Inherits System.Web.UI.Page

Protected Sub Action_StartDateTextBox_TextChanged(sender As Object, e As System.EventArgs)
Dim txtStartDate As TextBox = Me.FormView1.FindControl("Action_StartDateTextBox")
Dim txtFinishDate As TextBox = Me.FormView1.FindControl("Action_finishdatetextbox")
Dim strNewFinishDate As String

If txtFinishDate.Text = "" And txtStartDate.Text <> "" Then
strNewFinishDate = Convert.ToString(Convert.ToDateTime(txtStartDate).AddDays(30))
ElseIf txtFinishDate.Text <> "" Then
strNewFinishDate = txtFinishDate.Text
Else
strNewFinishDate = ""
End If

txtFinishDate.Text = strNewFinishDate

End Sub


Protected Sub SubmitButton1_Click(sender As Object, e As System.EventArgs)
Dim mytest As String
End Sub
End Class

16/01/2013 edit: had a typo in Protected Sub Action_StartDateTextBox_TextChanged ran the page but it still doesn’t fire. Still need help with this, please.

17/01/2013 edit: My question is still unanswered, the response I did receive caused more errors. Please help.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-17T15:00:41+00:00Added an answer on June 17, 2026 at 3:00 pm

    No response on this, but I have to keep moving. So, I have chosen what is probably the smarter route — to take care of my postbacks as client-side javascript. I would have accepted an answer of “asp.net can’t do this. Javascript would make your life so much easier” for this issue….

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I need help with the javascript below please. I have 2 text boxes and
I need help with some Javascript. Inside my html I have a form that
Need some help from javascript gurus. I have one page where http://www.google.com/finance/converter is embedded
Need help with a query that I wrote: I have three tables Company id
I need some help please, I have a PHP page with a drop down
i need some help here. I have a dialog box that contains an iFrame
Ok I have googled for hours and found nothing that works. I need help
I'm new to JavaScript so need a help please. Basically I've two radio buttons
As I don't have much knowledge of javascript and I need your help. My
But please bear with me. I do not need help with ndns or JavaScript.

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.