473,387 Members | 1,516 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,387 software developers and data experts.

How to Multiply $50 times, by how many was input in the textbox?

anoble1
245 128KB
I am working on trying to calculate a penalty, I have 2 text boxes. On of them is where a user inputs a number like "2" (We will call that textbox Z) then their is another txt box under it that I want to be the Total txtbox.

So, I want to multiply the user input number by $50.00 and create a Total in the next textbox. I can't seem to get it right.

I have done a "After Update" on the txtbox Z

Expand|Select|Wrap|Line Numbers
  1. Private Sub txtLateGB_AfterUpdate()
  2.  
  3. txtLateGBCost.SetFocus
  4.  
  5. txtLateGBCost.Text = (Forms!frmFeeder!frmPenaltiesIncentives.txtLateGB.Text) * (50#)
  6.  
  7. End Sub
I'm just trying to get it to multiply their number by $50 and trying to get it to show up in the other textbox instantly. That's why I did an after update hoping that would do it.

Thanks!!!
Nov 4 '10 #1
1 1940
use the change event

Expand|Select|Wrap|Line Numbers
  1. Private Sub txtbLateGB_Change()
  2.     txtbLateGBCost = txtbLateGB * 50
  3. End Sub
  4.  
Nov 5 '10 #2

Sign in to post your reply or Sign up for a free account.

Similar topics

1
by: bbwrede | last post by:
Hi, I have an html page that asks the user for info, preforms a calculation and then displays the output in a read only text box. The problem is that I have a grey background for the page, but...
3
by: Astra | last post by:
Hi All Could somebody confirm if and how I can change the TYPE of a textbox from PASSWORD to TEXT depending on whether a user checks a checkbox. In essence I have a login and password form and...
2
by: Roman | last post by:
Is there any way to display a tooltip when the user puts their mouse over an input box? Thanks
6
by: Maziar Aflatoun | last post by:
Hi, I have a little application that reads a text file line-by-line and processes each line depending on the CVS values. Now I want to change my program to capture this from a textbox. How do...
1
by: craigkenisston | last post by:
I'm creating a form with asp.net. I have my inputs like this : <label for="USER_COMPANY">Company Name:</label> <asp:textbox id="USER_COMPANY" runat="server" cssclass="inputBox"...
1
by: eSolTec, Inc. 501(c)(3) | last post by:
Thank you in advance for any and all assistance. I'm trying to validate an email address entered into an input textbox. Does anyone have any code for this? -- Michael Bragg, President...
2
by: darren.murray2 | last post by:
Hello all, I'm fairly new at this so I may be doing this the wrong way but I've got a FormView within a multiview that when it is updated in edit mode, will call on the update method associated...
3
by: Mike | last post by:
Is there a way to determine if a user deleted text in a asp:textbox? I have a textbox were users can enter in a product number, then they click a button to see if the product numbers(s) exists in...
2
by: perhapscwk | last post by:
My code below, I can add and remove textbox, however, it can add/remove the last one only. How I can add a input textbox between field? thanks. my html file <script...
3
by: Court K | last post by:
This is mostly taken from bits and pieces found on the internet and I need help adjusting it, because I don't understand how it works. I have a form that will display selects based on a select, and...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...

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.