PC Review


Reply
Thread Tools Rate Thread

Cummulative total in Userform

 
 
=?Utf-8?B?THVpc0U=?=
Guest
Posts: n/a
 
      28th Aug 2007
I have an userform with 12 lines of 3 text boxes (36 textboxes total)

The first textbox in the line looks up for a costumer name and places a
balance in the third textbox. The second textbox holds a payment that reduces
the balance (third textbox). I got that part taken care of.

My problem arises when I try to validate several data entry scenarios: the
same costumer making several payments, (up to 12) either in consecutive order
or not and being able keep the running balance and place it in the 3rd text
box of the respective line.
Any suggestions?


 
Reply With Quote
 
 
 
 
=?Utf-8?B?VG9tIE9naWx2eQ==?=
Guest
Posts: n/a
 
      29th Aug 2007
give the textboxes names that identify their function, location and are
conducive to looping through

for i = 1 to 12
set tbox = me.Controls("bal" & i)
' perform necessary calculations

next i

--
Regards,
Tom Ogilvy


"LuisE" wrote:

> I have an userform with 12 lines of 3 text boxes (36 textboxes total)
>
> The first textbox in the line looks up for a costumer name and places a
> balance in the third textbox. The second textbox holds a payment that reduces
> the balance (third textbox). I got that part taken care of.
>
> My problem arises when I try to validate several data entry scenarios: the
> same costumer making several payments, (up to 12) either in consecutive order
> or not and being able keep the running balance and place it in the 3rd text
> box of the respective line.
> Any suggestions?
>
>

 
Reply With Quote
 
=?Utf-8?B?THVpc0U=?=
Guest
Posts: n/a
 
      29th Aug 2007
Thank you for the prompt response.
I think I wasn't clear enough.
I'm invisioning different scenarios, like customer1 in the first row needs a
running balance, then in line two costumer 2 needs a separate balance, then
in line three costumer 2 again, then in line 4 costumer1 again, I have to be
able to compute the current balance. The code has two identify any
reocurrance of the same client and keep the balance running.

"LuisE" wrote:

> I have an userform with 12 lines of 3 text boxes (36 textboxes total)
>
> The first textbox in the line looks up for a costumer name and places a
> balance in the third textbox. The second textbox holds a payment that reduces
> the balance (third textbox). I got that part taken care of.
>
> My problem arises when I try to validate several data entry scenarios: the
> same costumer making several payments, (up to 12) either in consecutive order
> or not and being able keep the running balance and place it in the 3rd text
> box of the respective line.
> Any suggestions?
>
>

 
Reply With Quote
 
=?Utf-8?B?VG9tIE9naWx2eQ==?=
Guest
Posts: n/a
 
      29th Aug 2007
I guess it is me that isn't being clear.
Naturally you will have to write the code to perform the functionality you
want. That is what writing code is all about.

I showed you a good way to loop through your controls. Within that loop or
multiple loops you write the complex code that is required to examine the
controls and make decisions.

--
Regards,
Tom Ogilvy


"LuisE" wrote:

> Thank you for the prompt response.
> I think I wasn't clear enough.
> I'm invisioning different scenarios, like customer1 in the first row needs a
> running balance, then in line two costumer 2 needs a separate balance, then
> in line three costumer 2 again, then in line 4 costumer1 again, I have to be
> able to compute the current balance. The code has two identify any
> reocurrance of the same client and keep the balance running.
>
> "LuisE" wrote:
>
> > I have an userform with 12 lines of 3 text boxes (36 textboxes total)
> >
> > The first textbox in the line looks up for a costumer name and places a
> > balance in the third textbox. The second textbox holds a payment that reduces
> > the balance (third textbox). I got that part taken care of.
> >
> > My problem arises when I try to validate several data entry scenarios: the
> > same costumer making several payments, (up to 12) either in consecutive order
> > or not and being able keep the running balance and place it in the 3rd text
> > box of the respective line.
> > Any suggestions?
> >
> >

 
Reply With Quote
 
=?Utf-8?B?THVpc0U=?=
Guest
Posts: n/a
 
      29th Aug 2007
I got it. Thanks a lot.

"Tom Ogilvy" wrote:

> I guess it is me that isn't being clear.
> Naturally you will have to write the code to perform the functionality you
> want. That is what writing code is all about.
>
> I showed you a good way to loop through your controls. Within that loop or
> multiple loops you write the complex code that is required to examine the
> controls and make decisions.
>
> --
> Regards,
> Tom Ogilvy
>
>
> "LuisE" wrote:
>
> > Thank you for the prompt response.
> > I think I wasn't clear enough.
> > I'm invisioning different scenarios, like customer1 in the first row needs a
> > running balance, then in line two costumer 2 needs a separate balance, then
> > in line three costumer 2 again, then in line 4 costumer1 again, I have to be
> > able to compute the current balance. The code has two identify any
> > reocurrance of the same client and keep the balance running.
> >
> > "LuisE" wrote:
> >
> > > I have an userform with 12 lines of 3 text boxes (36 textboxes total)
> > >
> > > The first textbox in the line looks up for a costumer name and places a
> > > balance in the third textbox. The second textbox holds a payment that reduces
> > > the balance (third textbox). I got that part taken care of.
> > >
> > > My problem arises when I try to validate several data entry scenarios: the
> > > same costumer making several payments, (up to 12) either in consecutive order
> > > or not and being able keep the running balance and place it in the 3rd text
> > > box of the respective line.
> > > Any suggestions?
> > >
> > >

 
Reply With Quote
 
 
 
Reply

Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

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


Similar Threads
Thread Thread Starter Forum Replies Last Post
how do I get a cummulative total in excel luvkoffee Microsoft Excel Misc 1 6th Jan 2010 11:47 PM
How do I calculate "cummulative percent of total" in a pivot table =?Utf-8?B?U3RldmUgUA==?= Microsoft Excel Misc 0 25th Sep 2007 02:06 PM
a cummulative or to-date total based on time and metrics dreamkeeper Microsoft Excel Discussion 0 9th Aug 2006 06:16 AM
a cummulative or to-date total based on time and metrics dreamkeeper Microsoft Excel Discussion 0 9th Aug 2006 06:14 AM
Getting a cummulative total from a one-to-many Ted Allen Microsoft Access Queries 0 11th Mar 2004 04:04 PM


Features
 

Advertising
 

Newsgroups
 


All times are GMT +1. The time now is 01:58 AM.