validating input in textbox

Tech-Archive recommends: Repair Windows Errors & Optimize Windows Performance



Hi,

My spreadsheet consists of a numer of sheets:
1. input data from the user
2. a sheet where i make my calculations based on the input of the user
3. help file in which additional dat is stored, needed for the calculations

I would like to construct an application where you don't see excel anymore.
I don't know if this is possible but i started anyway to see if it can be
done.

I have a few questions:

I made the application so that excel disappers (and appears again on closing)
The only thing you see is the multipage userform i constructed (4 pages)
most pages are used to get a sort of flow of information (step 1-4) and on
one page i put an excel sheet where the user can input a database of persons
which i need for the calculations.

Q1. Do i still need excell to make the difficult calculations ore can i let
vba do the calculation for each databasemember and get the total on a
differen page of the userform ? after vba calculated each single memeber of
the database, i want the total...

Q2. How can i access the data in the spreadsheet on the page in the
multipageform ?

Q3 I have a multipage userform on which the user can input various items in
combo's text boxes etc.
in one particular instance I want the input in a textbox to always be an
number (numeric value) and i wrote the following code:

Private Sub hui_eb_hoofd_change()
OnlyNumbers
End Sub

Private Sub OnlyNumbers()
With Me.ActiveControl
If Not IsNumeric(.Value) And .Value <> vbNullString Then
MsgBox "Sorry, alleen getallen toegestaan"
.Value = vbNullString
End If
End With
End Sub

Nothing happens when i enter text instead of numbers. Did i construct the
code wrong or did i place it in the wrong part of the project (i put in in
the form's VBA)? i don't know...anybody?

By the way, i'am looking also for a way to make sure thereis a dat entered
(dd:mm:yyyy) and a way to make sure a percentage is put in with 2 decimals....


I know, a lot of questions but i' am still a novice...but learning fast...
hopefully.
thanks for your help guys !
Jean-Pierre


--
Message posted via http://www.officekb.com
.



Relevant Pages

  • Re: Custom Document Properties - Last Calculation Date
    ... You can use the calculate event to detemine when each sheet was last ... Private Sub Workbook_SheetCalculate ... Or this one in the Sheet module to capture re-calculations on that sheet ... I have turned off automatic calculations during ...
    (microsoft.public.excel.programming)
  • Re: Large Workbook - trouble opening
    ... of calculations, the other I'm not sure why. ... Then on each subsequent sheet I have only one ... The second worksheet is the one that is a doosey. ... I could just file the time folder away while it's saving. ...
    (microsoft.public.excel.misc)
  • Re: Large Workbook - trouble opening
    ... I will have to look to see if I can scale down on the calculations. ... ThisWorkbook module set up a before_close or before_save event to do the ... Then on each subsequent sheet I have only one ... The second worksheet is the one that is a doosey. ...
    (microsoft.public.excel.misc)
  • Re: Best way to handle collection of similar calculations?
    ... similar calculations on different data. ... "template" sheet that will be used for multiple derivative sheets? ... Say I am keeping track of mileage and service for a car. ... I'd define the columns of raw data, ...
    (microsoft.public.excel)
  • Re: Large Workbook - trouble opening
    ... Right click sheet tab>view code>insert this>modify to suit ... I will have to look to see if I can scale down on the calculations. ... ThisWorkbook module set up a before_close or before_save event to do the ...
    (microsoft.public.excel.misc)