Solved

Fix to counter

Posted on 2006-07-24
4
195 Views
Last Modified: 2013-12-18
I have a counter that tallies up the count of a bunch of fields. The formula is below, I have added a new field with is used when there are over 25 values. I need to know how I can modify this formula to add in the value from this field, "midas_over" it is a text field so it would have to be converted to number and it will just add as a single value. So if the original counter below gets to 25 and the new field has 10 over, then the final count will be 35.

list:=@Trim (midas1:.....:midas25);
n:=@Elements(list);
FIELD count_midas:=n-@Elements(@Trim(@Replace(list;"midas";"")));""
0
Comment
Question by:jforget1
  • 2
  • 2
4 Comments
 
LVL 43

Accepted Solution

by:
Steve Knight earned 500 total points
ID: 17169065

Sounds kinda odd but you know your app :-)  Any reason why the other field is text for instance?

list:=@Trim (midas1:.....:midas25);
n:=@Elements(list);
over:=@If(midas_over!="" & @IsNumber(midas_over);@TextToNumber(midas_over);0);
FIELD count_midas:=over+(n-@Elements(@Trim(@Replace(list;"midas";""))));

""
0
 

Author Comment

by:jforget1
ID: 17175378
This is a temporary fix while I work on a multi value field attendance system using dialog boxes for entry, just can't get it quite right. Appreciate the help with the code.
0
 

Author Comment

by:jforget1
ID: 17175512
I did change the field over to a number field, eliminated some of the unneeded code, thanks again.
0
 
LVL 43

Expert Comment

by:Steve Knight
ID: 17175590
No problem, glad to help
0

Featured Post

6 Surprising Benefits of Threat Intelligence

All sorts of threat intelligence is available on the web. Intelligence you can learn from, and use to anticipate and prepare for future attacks.

Join & Write a Comment

For Desktop Techs: How to retain a user's Notes configuration data when swapping out the end user's computer. (Assuming that you are not upgrading to a completely different version of Notes client) All you need to do is: 1) install Notes o…
Notes Document Link used by IBM Notes is a link file which aids in the sharing of links to documents in email and webpages. The posts describe the importance and steps to create a Lotus Notes NDL file in brief.
This video demonstrates how to create an example email signature rule for a department in a company using CodeTwo Exchange Rules. The signature will be inserted beneath users' latest emails in conversations and will be displayed in users' Sent Items…
This video explains how to create simple products associated to Magento configurable product and offers fast way of their generation with Store Manager for Magento tool.

705 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

17 Experts available now in Live!

Get 1:1 Help Now