Converting a percentage whole number in one field to a decimal in another field in Adobe Livecycle - livecycle

I'm creating a budget template in Livecycle Designer.
I have a field where users can enter a percentage as a number (for example if you want to enter 75%, just enter 75).
I'd like another numfield box to take this number and convert it to .75
Can I do this across num fields or do I have to do it one box (where a user enters 75 and it turns into .75 automatically).

If you just want to enter integer numbers in the numeric field then that can easily be done by just taking a numeric field and then simply entering this javascript in the "exit event" of the field as:
var value1=this.rawValue;
this.rawValue="."+value1;

Related

Formatting telephone numbers basing on a country

I want to format the telephone numbers to: 1) Start with +country code, 2) Format the numbers (spacing after a given number of figures) depending on the recognized country format. Any help is highly appreciated
You can check out this tutorial on phone number/country code selection: https://www.codenameone.com/blog/tip-activation-ui-builder-pattern.html
If you want separate fields for each block in the number see this https://www.codenameone.com/blog/validation-regex-masking.html specifically the auto move functionality to "jump" to the next field.

Requirement to create conditional auto number field for Account number

I have a requirement to create a auto number field for Account number in Account object.
The number will start from 10000 then 10001 upto 20000.After that The number will start from A0000 and will go on till Z0000.After that it will stop creating any new accounts and throw an error "account has reached to its maximum threshold".
Need help on how to achieve this urgently.Thanks.
There may be display format field defined in the auto number field.
Try creating auto number field without display format.
Like this:
Why you want to define the upper limit of the auto number?
I was not able to find setting to set upper limit for the field.
You can use validation rule or trigger.

Get letters instead of numbers in option button with Access

I was trying to design a form in access, when i was in the marital status field i think it was a good idea to use a group of option buttons but i can save letters only numbers. This is not bad but i would like to save letters because is easier to remember. I have 4 values. I have other similar fields, like sex, education and so.
You can use Choose. It returns values from input of 1 to n and Null for values outside the range. This can be used by Nz to return a value for unknown inputs.
This can be used a ControlSource for a textbox, here for values between 1 and 4:
=Nz(Choose([NameOfYourOptionBox], "Male", "Female", "Hermaphrodite", "None"), "Unknown")

How not to hash part of user data in Cakephp

In my cake app user needs to submit mobile number with the registration form, I see that mobile number is automatically encrypted to some other number, how do I not encrypt part of user data ? especially the 10 digit mobile number ?
Since the database field is of type int I'm guessing the issue arises when you try to save phone numbers that are not strictly integers, i.e. +123456, 123 456 789, 00123 456, 123-456-789 etc. You must use a varchar field to store phone numbers that include spaces, hyphens, pluses or start with a zero.

Validation against to database

I have several textboxes and users are entering same data in one of these fields. I have another table which is store machine_no. I would like to restrict user for possible wrong entries. Example if there is no machine_no #4 on table, user will be warn with message box.
Machine_no Value1 In first day
1 500
2 400
3 600
Machine_no Value1 second day
1 8678
2 45645
3 54645
Thanks in advance
If you really want to restrict the available choices, I'd replace the free form textbox with a dropdown list of choices populated from your table.
You could use a NumericUpDown control to let the user enter only integers and validate against a generic List of integers or an array of integers (you can load the list with the existing machine numbers on your data base table), and finally you can use ErrorProvider control to show a warning to the user if enters a not valid number.

Resources