Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 5
Default Multipage Query

Hi

I'm trying to use a multipage to help with input data quickly into a main
spreadsheet. Design wise everything is fine, it's just i'm trying to
calculate the total of each multipage(8 in all) to give a subtotal as the
user tabs through each page.
I've used some code that i picked up on from the discussion group but it
only adds up page 1 and I need the same code to calculate pages 2 onwards.

I've attached the code in case anyone can put me straight as I am unsure
what I'm doing wrong!!

Private Sub textbox2_keypress(ByVal keyascii As _
MSforms.ReturnInteger)
If keyascii < Asc("0") Or keyascii Asc("9") Then
Interaction.Beep
keyascii = 0
End If

End Sub
Private Sub textbox3_keypress(ByVal keyascii As _
MSforms.ReturnInteger)
If keyascii < Asc("0") Or keyascii Asc("9") Then
Interaction.Beep
keyascii = 0
End If

End Sub

Private Sub textbox4_keypress(ByVal keyascii As _
MSforms.ReturnInteger)
If keyascii < Asc("0") Or keyascii Asc("9") Then
Interaction.Beep
keyascii = 0
End If

End Sub

Private Sub textbox5_keypress(ByVal keyascii As _
MSforms.ReturnInteger)
If keyascii < Asc("0") Or keyascii Asc("9") Then
Interaction.Beep
keyascii = 0
End If

End Sub
Private Sub textbox6_keypress(ByVal keyascii As _
MSforms.ReturnInteger)
If keyascii < Asc("0") Or keyascii Asc("9") Then
Interaction.Beep
keyascii = 0
End If

End Sub
Private Sub textbox7_keypress(ByVal keyascii As _
MSforms.ReturnInteger)
If keyascii < Asc("0") Or keyascii Asc("9") Then
Interaction.Beep
keyascii = 0
End If

End Sub

Private Sub Calctotal()
TextBox8.Text = CLng("0" & TextBox2.Text) + _
CLng("0" & TextBox3.Text) + _
CLng("0" & TextBox4.Text) + _
CLng("0" & TextBox5.Text) + _
CLng("0" & TextBox6.Text) + _
CLng("0" & TextBox7.Text)

End Sub

Private Sub userform_click()




End Sub

Look forward any comments
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
Multipage Query Tom Ogilvy Excel Programming 1 September 21st 04 04:39 PM
vba - using multipage ajliaks[_23_] Excel Programming 3 August 9th 04 01:29 PM
Multipage Aksel Børve Excel Programming 1 March 1st 04 08:52 AM
Multipage Aksel Børve Excel Programming 0 March 1st 04 08:24 AM
Multipage Paul Excel Programming 1 July 9th 03 02:34 PM


All times are GMT +1. The time now is 05:07 AM.

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"