Brian Dunning's FileMaker Custom Functions

#mapNumToRange ( val ; valMin ; valMax ; mapMin ; mapMax )

Maps a given value, from one range of numbers, to another range of number

  Average rating: 3.0 (2 votes) Log in to vote

Philip McGeehan   Philip McGeehan - Show more from this author
SMD Ltd
http://philipmcgeehan.com

Share on Facebook Share on Twitter

  Sample input:
#mapNumToRange ( 15 ; 0 ; 60 ; 0 ; 100 )

#mapNumToRange ( 10 ; 0 ; 20 ; 50 ; 100 )
  Sample output:
25

75

  Function definition: (Copy & paste into FileMaker's Edit Custom Function window)

Use this function to take any number and scale it to a new number that is more useful for the project that you are working on.

 

Comments

Log in to post comments.

 

Note: these functions are not guaranteed or supported by BrianDunning.com. Please contact the individual developer with any questions or problems.

Support this website.

This library has been a free commmunity resource for FileMaker users and developers for 20 years. It receives no funding and has no advertisements. If it has helped you out, I'd really appreciate it if you could contribute whatever you think it's worth: