Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default Calculation does not appear in userform


Thank u all

my problem has been solved

here is the complete code: ;) ;) ;)


PHP code
-------------------
Sub MyCalc()
Dim dblTot As Double
Dim dblConsu As Double
Dim dblMaint As Double
Dim dblClea As Double
Dim dblcarmaint As Double
Dim dblTransM As Double
Dim dblmachm As Double
Dim dblbuilm As Double
Dim dblDelv As Double
Dim dblDtax As Double
Dim dbloilful As Double
Dim dblelec As Double
Dim dblbouns As Double
Dim dblstatio As Double
Dim dbltaxes As Double
Dim dblpress As Double
Dim dblservic As Double
Dim dblcommesio As Double
Dim dblfirinsu As Double
Dim dblregs As Double
Dim dblcarinsu As Double
Dim dblgust As Double
Dim dblels As Double
Dim dblels2 As Double

If IsNumeric(tot.Text) Then dblTot = CDbl(tot.Text)
If IsNumeric(txtConsu.Text) Then dblConsu = CDbl(txtConsu.Text)
If IsNumeric(txtMaint.Text) Then dblMaint = CDbl(txtMaint.Text)
If IsNumeric(txtClea.Text) Then dblClea = CDbl(txtClea.Text)
If IsNumeric(carmaint.Text) Then dblcarmaint = CDbl(carmaint.Text)
If IsNumeric(TransM.Text) Then dblTransM = CDbl(TransM.Text)
If IsNumeric(machm.Text) Then dblmachm = CDbl(machm.Text)
If IsNumeric(builm.Text) Then dblbuilm = CDbl(builm.Text)
If IsNumeric(Delv.Text) Then dblDelv = CDbl(Delv.Text)
If IsNumeric(Dtax.Text) Then dblDtax = CDbl(Dtax.Text)
If IsNumeric(oilful.Text) Then dbloilful = CDbl(oilful.Text)
If IsNumeric(elec.Text) Then dblelec = CDbl(elec.Text)
If IsNumeric(bouns.Text) Then dblbouns = CDbl(bouns.Text)
If IsNumeric(statio.Text) Then dblstatio = CDbl(statio.Text)
If IsNumeric(taxes.Text) Then dbltaxes = CDbl(taxes.Text)
If IsNumeric(press.Text) Then dblpress = CDbl(press.Text)
If IsNumeric(servic.Text) Then dblservic = CDbl(servic.Text)
If IsNumeric(commesio.Text) Then dblcommesio = CDbl(commesio.Text)
If IsNumeric(firinsu.Text) Then dblfirinsu = CDbl(firinsu.Text)
If IsNumeric(regs.Text) Then dblregs = CDbl(regs.Text)
If IsNumeric(carinsu.Text) Then dblcarinsu = CDbl(carinsu.Text)
If IsNumeric(gust.Text) Then dblgust = CDbl(gust.Text)
If IsNumeric(els.Text) Then dblels = CDbl(els.Text)
If IsNumeric(els2.Text) Then dblels2 = CDbl(els2.Text)

' load text values into variables
' variables with invalid text will be zero
bal.Value = dblTot - (dblConsu + dblMaint + dblClea _
+ dblcarmaint + dblTransM + dblmachm + dblbuilm _
+ dblDelv + dblDtax + dbloilful + dblelec + dblbouns + _
dblstatio + dbltaxes + dblpress + dblservic _
+ dblcommesio + dblfirinsu + dblregs + dblcarinsu + _
dblgust + dblels + dblels2)


End Sub
Private Sub tot_Change()
MyCalc
End Su
-------------------


yours :)


--
helmekk

-----------------------------------------------------------------------
helmekki's Profile: http://www.excelforum.com/member.php...nfo&userid=693
View this thread: http://www.excelforum.com/showthread.php?threadid=27002

Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Auto calculation on a userform Greg B Excel Discussion (Misc queries) 0 June 13th 05 01:51 AM
Calculation does not appear in userform helmekki[_35_] Excel Programming 1 October 18th 04 01:58 AM
Linking userform to userform in Excel 2003 missmelis01 Excel Programming 2 August 27th 04 08:07 PM
Date Calculation in UserForm TextBox John Pierce Excel Programming 2 February 28th 04 12:11 AM
range.calculation with UDF not working when calculation is set to automatic Brian Murphy Excel Programming 5 October 14th 03 07:02 PM


All times are GMT +1. The time now is 01:47 PM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"