Custom Functions Discussions
General Discussions on developing custom functions with FileMaker Advanced
Subforums
-
- 23,100 visits to this link
-
A new community resource for custom functions.
- 19,405 visits to this link
490 topics in this forum
-
Hello, Can some offer some help on how to center a window on any size display. Whether it be a 12" ibook or 20"lcd Is "move resize" used? if so can you explain how? Thanks in advance
-
- 4 replies
- 1.9k views
-
-
I would like a recursive CF to turn this field entry: 3¶ 4¶ 12¶ 102¶ 22¶ Into this: 003¶ 004¶ 012¶ 102¶ 022¶
-
- 2 replies
- 1k views
-
-
Another thread got me to thinking about the problem of translating source text from Filemaker into truly "safe" URL encoding. Using online references about the characters that need to be escaped, I came up with the following long but simple function. It takes care of just about any character that could be misinterpreted by an outside program in a URL--at least those I could find when I dredged online for URL encoding specifications. The only exception made here was for the space character. Usage is simple: just feed text into the function, and all possibly suspicious characters will be changed to their hexcode equivalents. I have not tested it in all situations…
-
- 2 replies
- 1.2k views
-
-
Now that we can pass a bunch of stuff via the script parameter I hate having to create a calc to parse it out every time... I created the following Custom Function: My_Scripts ( value ) Substitute ( MiddleValues ( Get ( ScriptParameter ) ; value ; 1 ) ; "
-
- 8 replies
- 2.3k views
-
-
I'm trying to build a list of similiar values in one field based on the quantity of values in another field (para. delimited - not repeating field) For example: Field_A = "abc" Field_B = "pqr¶stu¶vwx" //3 values The result should be: Field_C = "abc¶abc¶abc" //3 values of Field_A I want the value in Field_A to be repeated in field_C by the valuecount of Field_B. Thanks.
-
- 4 replies
- 1.1k views
-
-
Find on Brian Dunning Custom functions page: Example for calculating Elapsed Time Between Two Dates Broken Into Year, Month, And Day originally by Lee Smith, Smith and Associates. For rest of us I little beet recreated Lee Smiths function: A. ANSI: Y M D or ISO: D M Y B. with changeable Date Names for Y M D in 6 languages (sixth - 6th can be changeable). Input: StartDate = Date EndDate = Date Type: ANSI (Default) or ISO Output: Text recreated by Ino ElapsedbyIno.zip
-
- 0 replies
- 1.2k views
-
-
Here is a set of custom functions for window centering on creating a window. Does not require you to adjust window after creation. Center.fp7.zip
-
- 1 reply
- 1.2k views
-
-
I'm trying to design a custom function to perform a variety of text manipulations (defined by codes) and am having trouble at the first step. Here are sample fields and their values: Input: This is a test Operation: Input [1,1] I want to pass the contents of Operation to the custom function (Textract) and have it recognize and treat the first word (in this case, Input) as a valid field name. The values in the brackets will eventually describe the text operation to be performed, but I'm not there yet. So for now I have a calculation field (Result) Result = Textract (Operation) Textract is simply (and wrongly so far) defined like this: Let([ $field=…
-
- 9 replies
- 1.4k views
-
-
Just moved to FM Pro 8adv. Can someone please explain what custom fucntions are in plain english and maybe a simple example to get me intersted in using this feature? thanks in advance
-
- 1 reply
- 953 views
-
-
[color:#] Is there any way to add to the end of a report the page number in this format,e.g., Page 6 of 12. We do this all the time in MS Word, but I cannot find a function in FM7. Thank you.
-
- 1 reply
- 1.3k views
-
-
I am trying to write a custom function to remove all iterations of a value from a list of values. For instance, say I have a value list in a field called "IDs": 1 2 3 4 2 Now say I want to remove all the twos from this value list. I could use substitute and all that, but I don't want to. No real reason other than I like the new Values functions that FileMaker has for us. So I wrote two custom functions: DeleteValue(value; valueList; startingValueNumber) Let([ $$value = value; valueCurrent = GetValue(valueList; startingValueNumber); $$totalValues = ValueCount(valueList)]; Case(startingValueNumber <= $$totalValues; …
-
- 4 replies
- 1.6k views
-
-
Hi all, Here's a CF I've made that simplifies Portal sorting. The Custom Function is not largely commented but you may adapt it to your needs. If you need more information on how to implement it, just ask. The CF is enclosed the attached file, and include another CF, ReverseAlphabet (Text). I volontarily let you choose the Systems Format on opening as I'm not sure what dates would look like when they'd cross the pond. If it doesn't happen to work, you may need to save as clone and then paste back the graphic so that it behaves as expected. Hope not. Be well and enjoy. Ugo PortalSortKeyCF_FM8.fp7.zip
-
- 0 replies
- 1.1k views
-
-
Hi all friends as I'm a ChindoguMaker I need this function ! But it isn't so simple to explain the "WHY" ! So I wish to point the right direction with the file attached. ANTEFACTA: with a large number of FileMaker function you can retrieve a field contents, but there is no one to retrieve the field name. "You are a lying man !" (you can say)..."there is one: Get ( ActiveFieldName )" Suddenly I'll explain why this isn't the same I wish. PURPOSE: the only situation that need this function is when you make a custom function that needs the field name as a parameter. A simple one that I can think is: __________________________…
-
- 6 replies
- 1.9k views
-
-
Suppose we have a function f(n) where n is a positive integer. We often need to calculate S(m;n) = f(m) + ... + f(n). m <= n This is a simple recursion for a given function f, S(m;m) = f(m), S(m;n) = S(m;n-1) + f(n). So what I am doing here is trying to make the function one of the parameters. Sigma(f;m;n) = f(m) + ... + f(n) Here is the definition of Sigma(f;m;n) Let( [Arg1 = Left(f;Position(f;"#";1;1)-1); Arg2 = Right(f;Length(f) - Position(f;"#";1;1))]; Case( m > n; "Undefined"; m = n; Evaluate(Arg1 & m & Arg2); Evaluate(Arg1 & n & Arg2) + Sigma(f;m;n-1))) Obviously this can be extended to provide the…
-
- 17 replies
- 2.7k views
-
-
Hi,friends I wish to submit you a problem... Field1 contains the word: PIPPO Then in a calculation: 1) if I write: getField(Field1) I obtain: PIPPO 2) if I write: quote(Field1) I obtain: "PIPPO" 3) if I write: Field1 I obtain: PIPPO 4) if I write: "Field1" I obtain: Field1 I would want to obtain: Field1, but in a dynamic way... that because the name of the field could change, and just this thing serves to me in order to estimate the calculation with the Case() function. I cannot therefore write it like in the fourth example! Something would serve me (than it does not exist) of the type: GetFieldName(field1)!! Exists a way or it…
-
- 13 replies
- 1.9k views
-
-
Having only recently started to use custom functions the impossibility (as far as I know) of moving a CF from one database to another becomes irritating. So I have put together a custom function database together with an external script which allows those with Filemaker Pro 8 Advanced and Windows the opportunity to construct a library of CFs with the possibility of transferring a CF into any other FP database with a minimum of effort. This is a first effort and please use it, extend and improve it as you wish. The attachment consists of four files. CFList,fp7, a database into which you can place the definitions of your custom functions, there is a limit of 5 par…
-
- 2 replies
- 1.2k views
-
-
This is my first effort at Custom Functions so be kind. I am working with the example file Matrix Math from http://www.spf-15.com/fmExamples/ and some of the functions below are from that file. I have defined a custom function AddRow which simply adds a new row into a matrix at a given position (the position is the row number of the vector in the new matrix. AddRow is defined as AddRow(matrix,row,vector) = Case( Cols(matrix) ≠ Cols(vector) or Int(row) ≠ row or row > Rows(matrix) + 1 or row ≤ 0;matrix; LeftValues(matrix;row - 1) & vector & If(row ≠ Rows(matrix) + 1; "¶";"") & RightValues(matrix;Rows(matrix) - row + 1 )) He…
-
- 1 reply
- 1.1k views
-
-
So I discovered that the new FM8 function:GetNthRecord ( fieldName ; recordNumber ) there was into FM7 too ! Its name is: GetRowData ( fieldName ; recordNumber ) But it do nothing, neither appears between the functions list. If you enter a calc with this, FM7 accept the function ! If you open with FM8 you'll see the new one ! So (for now I think, I didn't test), if you write a custom function with FM7 Dev around this , when you'll open with 8 it should work :
-
- 9 replies
- 1.7k views
-
-
This sampler uses custom functions to solve some basic geometry problems. Includes CFs for these tasks: Arc Cosine Area of a cone Volume of a cone Area of a cylinder Volume of a cylinder Area of a sphere Volume of a sphere Pythagorean Theorem Cosine Law Inverse Cosine Law Solving a quadratic equation Finding the intersection of two linear equations GeometrySampler.fp7.zip
-
- 0 replies
- 942 views
-
-
I am trying to create a function that would caculate a students "AI" for our recruting database: here is the formula. ((Critical Reading score + Writing)/2 + (2 Highest SAT IIs)/2 + CRC = AI First the CRC is a seperate formula can i call the reulst of that formula to be a variable in this formula. Secound there are different variables for the SAT score and I can replace them with different information. Can I have filemaker use alternate information if a score is not available i.e. if a score is not present substitute class rank for critical reading. email [email protected]
-
- 3 replies
- 1.3k views
-
-
/* MiddleRepetitions function Author *COMMENT Visual Realisation Format MiddleRepetitions ( repeatingField ; startRepetition; endRepetition ) Parameters repeatingField - any repeating field, or an expression that returns a reference to a repeating field. startRepetition - any numeric expression or field containing a number endRepetition - any numeric expression or field containing a number Data type returned text Description Returns the values in specified repetitions of repeatingField, starting with startRepetition and ending with endRepetition (inclusive). Returned values are text items followed by carriage returns. */ G…
-
- 3 replies
- 1.2k views
-
-
In a related topic (Multiplying Fields Together) a solution to the problem of multiplying together a set of fields (in separate records) was given: Product (fieldname; n_records) = If (n_records>1; GetNthRecord(fieldname; n_records)*Product(fieldname; n_records-1); GetNthRecord(fieldname; n_records) ) Now suppose that fieldname is a repeating field. My testing seems to indicate that this custom function only works for the first repetition. I found that surprising (I am learning to not be surprised by FileMaker), but I can't seem to figure out why it is not working. Based on the documentation for GetNthRecord it seems the syntax for returning a repeating fi…
-
- 13 replies
- 2.9k views
-
-
I trying to write my first custom function that basically behaves similarly to the Sum ( field {; field...} ) function; except rather than add the fields, they would get multiplied. The fields, in this case, would be in separate records. Being new to this (but having read the help pages and many of the posts in this forum) I still can't figure out how such a function would get coded. My guess is that recursion would be used but it is not obvious how FM would know to do the math over the set of records. Is there a tutorial on this somewhere? Or am I missing something completely obvious? Thanks...Andrew.
-
- 10 replies
- 1.7k views
-
-
Hi while playng with Get(ActiveFieldName), I found that this function can be used in a custom function and gives back the name of the field specified as parameter of the function itself. Look at the attachment. It launch a script too, but you have to have the S4HU plugin Validate.zip
-
- 7 replies
- 1.4k views
-
-
I'm trying to figure out why I can't use the Evaluate () function in a custom function (at least in the way I want). Here's what's going on... I downloaded a sample file from http://www.databasepros.com (created by Reed Wycuff) of this nifty little ChangeLog2, which shows how to use a single auto-enter calc to create a change log. While looking at the formula, I thought it would be really cool to make it into a more modular Custom Function. I took the original formula of: [color:blue]Let([x = Evaluate("Get(ActiveFieldContents)";[[color:red]Text;Number;Date;Time[color:blue]]);y = "[color:red]Text:Number:Date:Time[color:blue]"];( Case( PatternCount(y;G…
-
- 6 replies
- 2k views
-
-
is it possible to create a custom function that has an optional parameter?
-
- 2 replies
- 3.2k views
-
-
Hi all friends I tried to make a CF (recursive) to grab all the eMails from a given text ... but for now I do not got ! I thinked to count the words and so on... but the "@" character is considered a delimiter of words (as comment kindly explained to me). So I stopped ! The same CF can grab all the words with a given string inside them. Kind of: GetWords(text;string) PS: I can't find a similar CF in the brilliant Brian site
-
- 7 replies
- 2.8k views
-
-
Hi, friends do you know a way to mimic the "go to next rekord" with a custom function ? So, if I have 3 records with field Fruit, with that ipotetic recursive CF I'll end up with: apple orange banana I need that ipotetic way to implement a CF that evaluates only the found set of rekords (much like those pretty summary).
-
- 3 replies
- 1.7k views
-
-
I'm trying to build a time list. It seems it would be best done with a CF but this is starting to hurt my head a bit. For example, I would specify the following: StartTime: 10:00AM EndTime: 2:00PM Interval: 5 This would produce a list of times between 10:00 and 2:00 in 5 minute intervals Any help would be appreciated.
-
- 8 replies
- 1.5k views
-
-
In the UK we have the following types of telephone number London 020 7694 1234 020 8694 1234 Rest of the UK 01642 294 878 or 0870 133 2064 How can filemaker know whether it is a London number or the rest of the UK and insert the spaces as shown below automatically? London (020) 7694 1234 Rest of UK (01642) 294 878 If anyone can help me I would be very grateful. Thanks Martin
-
- 1 reply
- 1.3k views
-
-
To show a Running Balance of a sorted portal without scripting was not possible with FileMaker 6. The Troi Number Plugin solved this problem. Is it possible to solve this problem now with a custom function? The function is very handy for reconciliation of a bank account (Debit/Credit => balance).
-
- 7 replies
- 3.4k views
-
-
Here's a pair of custom functions to return the mode for a list of numbers. Example: Given: 4 2 3 2 5 Returns: 2 This function requires the list to be in sorted order. I used Jeremy Bante's QuickSort() CF to do this. Mode ( list ) = //Mode ( list ) //Given a list of numbers, returns the value(s) that occur most often. //7-25-2005 //By Mike Hackett Let ( [ bimodalSeparator = ", "; //how you want tied values to be separated valueCount = ValueCount( list ); sortedList = QuickSort ( list ); //sorts the values resultList = LeftValues( sortedList; 1 ); //keeps track of the values that occur most ofte…
-
- 0 replies
- 1.4k views
-
-
I'm trying to use a custom function from another file, I only have FM Pro 7 though I'm trying to find out if there's a way to convert or import this custom function, please help would really love to use this funtion and copying and pasting the function won't help it's recursive
-
- 2 replies
- 1.5k views
-
-
anybody see a Custom function for checking correct email format?
-
- 3 replies
- 1.6k views
-
-
Basically, what I am looking for is a custom function that can take a value list and create every permutation of the items in the value list. Say I have a value list "cat;dog;mouse", I want to be able to feed the custom function that value list and get: cat dog mouse cat mouse dog dog cat mouse dog mouse cat mouse cat dog mouse dog cat The order of the permutations doesn't matter as long as all the permutations are returned. Also, the number of values in the list I feed it is variable. One time it may be three values as above, another time it may be four and so on. Anybody help? I have been staring at my screen for hours. I am hoping this…
-
- 8 replies
- 2.3k views
-
-
I'm looking for a simple solution (who isn't?)... I want to create a 2ndMax function similar to the built-in Max(field1,field2,field3,...) function, but it would return the 2nd highest value. For example, 2ndMax(height,width,depth) would return 12 if height=20, width=12 and depth=8. Any suggestions?
-
- 10 replies
- 1.9k views
-
-
I'm strugging to grasp how to make two loops in recursive custom functions ...can anyone??? The result must be a return/pilcrow delimited list of dates within a span from day1 until day2.... --sd
-
- 13 replies
- 2.1k views
-
-
I didn't get any responses to my previous post to correct this, so maybe someone could help me create one from the ground up. Have 6 phone number fields. I have 6 corresponding Priority fields. If I have, for example, Mobile Phone set to 1, and my client says I should call them on the home phone, I want to set the Home Phone Priority to one, and have all of the other priority fields update. Mobile would become 2 in this case, and the rest of the priority fields would adjust accordingly. So if Home Phone was 3, whatever was 2 previously would become 3, and the last 3 fields wouldn
-
- 5 replies
- 1.4k views
-
-
Hi to all, Can anyone make this function ? I'll pass a text field and each letter of the text will go into a position of the reapeting field... It's possible to make this function? I need it to center text into a form with some predefinited square ! Thanks
-
- 17 replies
- 1.9k views
-
-
This single function, will recreate the folder structure, copy, and unlock the file. For instance: You have a cd that has a file on it that goes to: Disk1:Folder1:Folder2:Folder3:file.txt You want to move the complete file structure to: Macintosh HD:MyFolder: Your result after running this function would be: Macintosh HD:MyFolder:Folder1:Folder2:Folder3:file.txt All with one function! Recursive_Create_Folder ( start; stop; DrivePath; Save Path; Fpath; OS; FL_Name ) Start = (I always start at 1 to make this work right.) Stop = (I always start with 2 to make this work right.) DrivePath = The name of the Disk SavePath = where you want to Save …
-
- 2 replies
- 1.5k views
-
-
Thanks for checking this thread out - I've lurked this forum a bit to get the feel of Custom Functions. Now I'm going to try my hand at a few, and wonder if anyone has seen a good tutorial on it that I can use for a little hand-holding. I'm not new to FMP, having used it since the 2.1 days; but for some reason this is the first time I've thought about writing functions. Just jazzed about 7, I guess. anyway, any pointers to a guide would be much appreciated. Thanks for your time! Tony
-
- 3 replies
- 1.3k views
-
-
Hi to all friends, I need a correct english name for a function. It returns a number, chosen by the position assigned to any individual character, for all characters of the Text. E1 ValuedByPosition ( "1" ; "9876543210" ; 0) returns "8" E2 ValuedByPosition ( "111" ; "9876543210" ; 0) returns "8 8 8 " The result is in the format: Number Space NumberSpace ... so I can add all the numbers with: Evaluate ( Substitute ( result ; " "; " + " ) & "0") I was thinking: ValuedByPosition ( Text ; PositionedText ; StartValue ) or SetTextValue ( Text ; PositionedText ; StartValue ) ... but my English is so bad ... This is the functi…
-
- 10 replies
- 1.4k views
-
-
First of all, hello. This is my first post on FMForums. In designing a solution to a specific problem I came up with an interesting technique that I thought was worth sharing, but I want to see if anyone can think of a simpler way to do the same thing. I was looking for a way to store and pass variable data in an array from within the logic of the CF. I wanted a tool similar to a script parameter or a global field. I toyed with creating "non-user" parameters that I could use to hold variables, but this seemed way too flakey. Basically as the subject line hints, I settled on piggy-backing additional variables onto one of the "user" input parameters in a CF. …
-
- 20 replies
- 4.1k views
-
-
Hi, friends I need a recursive function to grab odds and evens of a text(field). Can anyone help ?
-
- 20 replies
- 3.3k views
-
-
This is going to be hard to explain but I'll do my best. Lets say I have 21 records in a table. This is my random record table. just contains the numbers 1-7 but it would look like this: 1a, 2a, 3a, 4a, 5a, 6a, 7a, 1b, 2b, 3b, 4b, 5b, 6b, 7b, 1c, 2c, 3c, 4c, 5c, 6c, 7c In this 'game', each 'player' gets 3 numbers. so you could have 1a, 1b, and some other number. Here is what I need to do. When player 1 gets 1a, I want to say ok, the chance of you getting another 1 is 20/2, if then they get a second 1, I want to say ok, the chance of you getting the last 1 is 19/1. I want this to be automatic. As soon as the see the first 1 I want to say: "10…
-
- 0 replies
- 910 views
-
-
Can anyone help with a function that eliminate duplicate values from a field. I have e.g. a field with 5 values, separated by a carrige return: 8 4 5 4 8 and I need to end up with a field/list that have filtered out the duplicates: 8 4 5 any suggestions ?? ;-) Claus
-
- 9 replies
- 1.3k views
-
-
Here is V2 of the ClosestDate Custom Function that I created. Concept is the same; you need a basedate you are checking and a valuelist that contains the list of dates that you are checking against. This version includes the addition of being able to limit the closest date to either before the base date, after the base date or either before or after the base date you are comparing against. It is two functions which are: /* ================================================== 03/12/2005 1.0 KLN Original Version 03/16/2005 1.1 KLN Added Parameter To Limit Closest To Before, After Or Either ===============…
-
- 2 replies
- 1.4k views
-
-
(as always, i'm sorry for my English) GetRGB(field)... ...isn't a standard function of FM7 !! it gives the color of the text inside a field in the RGB(RRR;GGG;BBB)format. How you'll build that ??
-
- 35 replies
- 4k views
-
-
Can someone tell me how to write a function that warns the user before deleting information in a specific field? I.E. when the delete key is pressed, some text comes up and says, "Are you sure you want to delete?" Thanks!
-
- 5 replies
- 1.2k views
-
-
I've been trying to create a custom function to find the closest date between a date in a table and related dates in another table. For Example Table A ------- 2/9/2005 Table B - Related Dates ------- 1/14/2003 2/1/2004 3/3//2005 3/9/2005 In this case I would want 3/3/2005 returned as it is the closest date via the relationship in table B to the date 2/9/2005 in table A. The closest date can occur on the same day or before or after the date in Table A. In Pre-FM7 days this was done via scripting and updated on a weekly basis. Tons of scripts not to mention process time when I have about 23 different tables finding the closest to eac…
-
- 14 replies
- 2.5k views
-
-
I am discovering that a Custom Function will not perform more than 10,000 recursions. Beyond that I get a question mark in the calc field. I can't find any documentation for this limitation. Can anyone confirm/disprove this?
-
- 11 replies
- 2.3k views
-
-
Here's a custom function implementation of Mikhail Edoshin's Smart Ranges technique for relationships based on date, time, or number ranges. Though complicated, the technique was quite useful in previous versions on FMP, so I thought I'd try to make the implementation easier in FM7 by creating plug-and-play custom functions. In testing it with a large record set (500,000 related records,) I was not able to determine if there was any speed difference between the Smart Ranges technique and FM7's built-in relationship range criteria matches. In my tests, they both performed quite well over a LAN and over a WAN (2-3 seconds to show 100-200 matches out of 500,000 in…
-
- 42 replies
- 9.7k views
-
-
The attached file has a custom function that returns the median value(s) of a return delimited list. Since I can't figure out how to get all the related values in a portal into one calculated field...(ValueListItems only returns unique values) I tried to use the primary keys of the related table to make the value list instead...sorted by the values, not the keys. I can then use the keys corresponding to the median values in relationships to return the values. This file works, but it seems like kind of a hack, and there are field refresh issues due to the way I did it. Can anyone see a way to get all of the values in a one-to-many relationship into a single fi…
-
- 6 replies
- 1.7k views
-
-
Hello All! I'm building a Field Autoenter that uses Evaluate and a custom Function to update. I have a field for Priority for each phone number I store in my database. Sometimes a client will want a mobile phone to be called first. I would like the person working on the file to set that phone numbers priority to 1. Using Evaluate, I have listed all of the evaluate fields to update when any of them change. If mobile phone was 2, and I change it to 1, I want all of the fields to recheck their own priority again. The number that was previosly 1, will goto 2, and the rest of the prioritys will move up if there is a spot open. Here is the Custom Fuction that I'm curr…
-
- 0 replies
- 956 views
-
-
Ok, I have a question for you guys. Lets say, I have a record with 20 fields. Each of those fields can have a number between 1-20. If I do a Case Statment, and start at the highest value possible (20), and work my way down, here's what I'm getting at. If the 20 fields all have a 20, then I want to do something, If 19 fields have the number 20, I want to do something else, And so on down the line, I realize this will be a huge function, because I will go through this with the numbers 1 - 20, I start with 20, because I want the highest value possible first. My question is, is there a way a summary (Sort of) on all the fields in ONE record. So …
-
- 29 replies
- 3.1k views
-
-
Hi, this may have been addressed but I didn't know how to search for it. I was trying to impliment a custom function from the excelisys web site and it had a character in it that looks like kind of like a letter E but looks greek. It has a flat bottom and top and the down line is indented. It almost looks like an hourglass that has the right side missing. Is this making any sense at all? If you know what this is, please let me know and tell me how to enter it. Thanks in advance
-
- 2 replies
- 1.2k views
-
-
I have used FileMaker Pro 6 in the past and just upgraded to FileMaker Pro 7. I need to do a calculation of a student's age. The age needs to appear in year, month,day format. In the past, I would export the data in FM to Excel, where I can do the calculation with the following formula:=DATEDIF(C2,D2,"y") & ";" & DATEDIF(C2,D2,"ym") & "." & DATEDIF(C2,D2,"md"). However, I have not been successful in calculating age in Filemaker. Can anyone help provide the formula for me? Thanks, in advance, for your help.
-
- 8 replies
- 5.5k views
-
-
Part 1 Request Starting out with text in a field (global) === text text cat text text mouse text text text text text dog text text text text 123 inches text text bird text dolphin horse! text text text human text text DOG text === Then I have this table of keywords (This is a table w/ a record for each keyword.) === cat mouse dog bird dolphin DOG horse inches human What I would like learn how to build a custom recursive function that would firstly enable me to do this.. === text text [color:"red"]cat text text [color:"red"]mouse text text text text text [color:"red"]dog text text text text 123 [color:"red"]inche…
-
- 8 replies
- 1.9k views
-
-
Hello everyone, I have a Records Bar custom function which I use in every table. It is simple unstored text calculation = RecordBar. It has worked for months in all tables and continues to work in all - except one. In my Products table (when using Status Area and forward/back through records), the RecordBar calculation displays: 64 of 64 unsorted - next record displays 4 of 127 sorted .... etc. totally inconsistent. But the Status Area shows the right results. I deleted the field and placed a new one - same results - wonky! New layout didn't solve it. I finally deleted the Record Bar calculation and recreated it and the problem was fixed (I left the CF in…
-
- 1 reply
- 1k views
-
-
For my first recursive custom function, I created a simple dice-rolling function. It returns the sum of N number of S-sided dice, as might be used with role playing games, etc. Dice(N,S) If( N > 0; Round(Random * S + .5; 0) + Dice(N - 1; S); N ) RECURSION... Recursion... Recursion... ...is kewl! is kewl! IS KEWL!
-
- 5 replies
- 1.9k views
-
-
// SetCell ( matrix ; row ; column ; value ) // Substitutes value for element in specified row and column; SetCell is the dual of The Shadow's GetCell Custom Matrix Function // By Ronald W. Satz // 11-02-2004 Let ( [ matrix1d = Substitute ( matrix ; "
-
- 4 replies
- 1.6k views
-
-
Once upon a time, someone posted a link to a developer's site (i can't remember the URL) that was a great script for displaying telephone numbers. it provided for 1 in front, extensions, and all sorts of contingencies. I think it even had color coding. Does anyone know this link? I can't refind it.
-
- 2 replies
- 1.2k views
-
-
Has any one turned KAGI basic algorithm in to a custom function? 310 LET A$ = ACGPurchaserName$ 315 let csum = 0 320 let strlength = len(a$) 330 for i = 1 to strlength 340 let char$ = mid$(a$,i,1) 345 debugprint char$ 347 print (rnd * 10)*(val(asc$(char$))) 350 csum = csum+ (rnd(1000) * 10)*(val(asc$(char$))) 360 next 370 debugprint int(csum) 380 PRINT "STATUS=GOOD,seed=" A$ ",key=" int(csum) Instructions are attached... BASICACGHowTo.pdf
-
- 0 replies
- 1k views
-
-
Here's a Decimal to Base-n converter for Bases 2 through 36 using a fairly simple algorithm. Simply change the number in the Base column to see the converted results for the first 20,000 integers. Note that zero is excluded in the sample, but accounted for in the main function. BaseX.zip
-
- 20 replies
- 2.6k views
-
-
Inspired by recent conversions to learn more about the new syntax of the Substitute() function, I have implemented a simple enchefalizer as a custom function. This is a brute force approach. I will next attempt a slightly more intelligent approach using recursion. enchefalizer.zip
-
- 2 replies
- 1.3k views
-
-
I want create a custom function to extract the maximun value of a list of values in a field in only one record. example: if i have in field "data" the data 6.7 8.3 12.6 7.5 8.4 i want result 12.6 I do not finish understanding as the recursivity works in custom functions any idea?
-
- 20 replies
- 2.8k views
-
-
These two custom functions will make it easier to determine the dimensions of a new window all you need to do is to make a mental note of the size of your background image or create a rectangle starting at 0 x 0 pixels (upper left) and then size it to fit the area you want. Then the H & W of this rectangle is used when you create a new window via a script. Use the custom functions below in the window h & w fields of the dialog it will take in to consideration the scroll bar/ & title bar and on both platforms. SetWindowHeight (height) height + Case (Get (SystemPlatform) = -1; 37;54) SetWindowWidth (width) width +…
-
- 1 reply
- 1.2k views
-
-
Okay. I want to wrap a fiscal custom function around any date field and it tell me what fiscal it falls within. should display just the year. Our start is 10/1. so I wrote this: Name: fiscal Parameter: datefield Let ([D=datefield]; If(Month(D) > 9; Year(D); Year(D) - 1)) then I add calculation in different tables with simple fiscal ( AnyDateField ) It doesn't always work. Sometimes date is 10/1/2003 and it says its 2002. Wrong. And at other times it doesn't work right but I can't pin it down. I made sure the date fields are all dates too. Does anyone know what I might have wrong or is this custom function itself the problem? Does the calc nee…
-
- 5 replies
- 1.4k views
-
-
// SetTexttoRepeatingField(RepeatingField;Repetitions) // By Ronald W. Satz, Transpower Corporation // 10-24-2004 // Set Text Field to Repeating Field So That User Can Scroll Through All Values If ( Repetitions < 1 ; // Condition "" ; // Exit // Text is added on the next line GetRepetition(RepeatingField;Count(RepeatingField)+1-Repetitions) & "
-
- 0 replies
- 1.1k views
-
-
Here is a set of custom functions for formatting an auto-entered field instruction when the field is blank. It formats the instruction in a light gray italic font, while the data in the field is formatted as black plain font. Of course you can specify your own colors and styles. AE_Instructions (fieldData; displayText) Case ( fieldData <> displayText and not IsEmpty ( fieldData ); NormalText( fieldData ); InstructionText ( displayText ) ) InstructionText ( Text ) //Makes the selected text light gray in color and in italics TextStyleAdd ( TextColor ( text ; RGB ( 75 ; 75 ; 75 ) ) ; Italic ) NormalText ( Text ) //Makes th…
-
- 3 replies
- 1.4k views
-
-
I'm very new to FM7 so forgive ignorance if it shows. I downloaded the files from K-12 and the Course Tracker file has a custom function called numberFormat in it that automatically formats either a phone number field or a SSAN field or any other text field that you want to set up. It's shown as: numberFormat ( phoneEmergency ; "(###) ###-####"; 1) My question is since I don't have the developer version of FM7 can I somehow utilize this custom function in other files? If so, I don't have a clue how to find it or do it. Thanks
-
- 3 replies
- 1.4k views
-
-
Post deleted by Rick Osgood
-
- 2 replies
- 1.1k views
-
-
just a cross ref to my post in http://www.fmforums.com/threads/showflat.php?Cat=0&Number=123618&an=0&page=0#123618
-
- 0 replies
- 1k views
-
-
Here is an updated version of a custom function that replaces <<merge fields>> in a text field with the field data. Example, if the user entered text field has this (Note the mispelling of the company field): <<Date>> Dear <<Name>>, As a result of recent discussions with our team, we have decided to terminate our contract with <<companie>>. Thank you for your business. The result text will be this: 1/5/2004 Dear Greg Anderson, As a result of recent discussions with our team, we have decided to terminate our contract with <Field Missing: "companie">. Thank you …
-
- 5 replies
- 9.5k views
-
-
Is there a faster/simpler method for moving a batch of custom functions between files than copy/pasting from the clipboard?
-
- 1 reply
- 1.1k views
-
-
Please test those on Windows. I am not sure they will compile right, it did work in FMP 6 though. If you are implementing them, remember to create a global field "NULL" containg just the ASCII nul character , and change the func to reflect your table/field name!!. ASCII null is the only ASCII character which cannot be used in a calculation directly without FM7 crashing. Sorry for docs in German, calcs should translate automatically. 1094828419-Char2Num.fp7.zip
-
- 0 replies
- 1.8k views
-
-
Here are versions of Position() and PatternCount() that are case-sensitive.
-
- 0 replies
- 1k views
-
-
I am trying to develop an invoice form for my own use. My calculation field brings a numeriacl result like; 1,567. I simply wanto to make it possible to show this value again in another field (at the bottom of invoice) but in letters like, "onethousandfivehundredsixtyseven" Thanks a lot...
-
- 2 replies
- 1.2k views
-
-
Almost every table needs record-arrow navigation. I decided to (hopefully) simplify the idea, utlizing Custom Function so that the required calculation in each table would be easier and could be just one calculation for all four arrows. I have attached my simple idea - Preferences table containing the Arrow graphics and a Customer table. I will be implementing this into approx. 25 tables once I get my head clear on it. This will be networked and I need to be sure my use of globals will work. I would hate to have this break when presented in multi-user. I tend to think that even more of the calculation can be moved to the Custom Function, but I am unsure how to acc…
-
- 5 replies
- 1.6k views
-
-
In response to a thread on another forum, here is a Custom Function that will return the number of consecutive occurrences of the specified character or character type (digit/alpha) with the specified frequency (consecutively) for the given text. For example, if the text is AABBABBBA1, the character is A, and the frequency is 2, then the result will be 1. If the character is B, the result will be 2. If the character is 'digit' and 1 is the frequency, 1 is the result; if 'alpha', then 9. Note that this function is case-insensitive and will not work for compound characters, e.g. 'ab', '49'. RegExp.zip
-
- 0 replies
- 1.1k views
-
-
I'm subtracting military time. Start = 0930 End = 1200 Time spent = 270 OK, my question is how can I get the results to show 2hrs and 30min? thanks wdf
-
- 1 reply
- 1.4k views
-
-
[color:"blue"]Is it possible to call a file maker script through a custom function? Or import a xml file from a website through a custom function? Reason I need this is because I have filemaker tied to a program called PCMiler to give me the distance from one zip code to another through XML. I got this to work fine with a script and button but I would really like it to be automatic (with a function). As soon as they fill in the 2 zip code fields It would call a function that imports the data or calls a script... But is this possible ?!? (I hope it is)
-
- 5 replies
- 2k views
-
-
I've added an *in-progress* style-manipulation example to my website: http://www.spf-15.com/fmExamples/ I didn't include it as an attachment since it still needs quite a bit of work. It makes heavy use of custom functions to show how style information can be obtained and manipulated. As a result, there is little point in downloading this example unless you have FM Dev 7. The three examples I've implemented in this file: - Visine: remove all redness from a piece of text, leaving other colors unaltered. - RedToBlue: Moves the red component of all text to the blue component, green is unaltered. - ItalicToBold: Changes all Italic text to Bold, al…
-
- 1 reply
- 1.3k views
-
-
I don't know if it was here are somewhere else where someone was asking about a custom function. Anyhow I will post it here and hopefully whoever was asking for it will find it. If not hopefully someone else might find it useful. This function can help you find the 3rd Saturday from today. Comments are in the custom function so hopefully you can rip it apart. Enjoy. /* ================================================== 05/30/2004 1.0 KLN Original Version Gives the Nth Occurance from a given date. Returns "" If Improper weekday is entered or less than 1 reptation (i.e. only calculates forward to a date in the future) Format for WeekDay is t…
-
- 6 replies
- 1.6k views
-
-
Has anyone seen or messed with the custom functions available in FileMaker Developer 7? Apparently, you make functions and you can use and resuse them throughout your database, sort of like nested scripts within scripts, only better. I have no idea how to use them yet, but I can't wait to learn. This feature alone justifies the purchase of Developer 7, since it's not in FileMaker 7. The best part...once you make a custom function, it stays with the file and is available (but not editable) from FileMaker 7! Sweet. Other than this, I don't notice any major changes in the Developer version. Still, FileMaker 7 is big enough to tide me over! Jeff Version: …
-
- 4 replies
- 1.8k views
-
-
Can custom functions replace multiple calculations? And then just adjust if used within each table? Here's what I need: I have a status bar at the top of every layout. This shows people certain things. It contains AccountName, Layoutname (I name the layouts to a specific task so it can be used to write to the window name also), Record indicator (record 6 of 144 found or total), the sort status (sorted or unsorted - if semi-sorted it displays unsorted). I am just beginning to put this together and I'm already tired. So already in one table I have four calculations all using Get (plus other things). And I change color of Account Name if their Privilege …
-
- 16 replies
- 2.8k views
-
-
I have a javascript which takes an ip address and a subnet mask and returns the broadcast address of the two. I'd like to turn this into a custom function, but haven't got a clue how to start. Anyone have any ideas? Heres the javascript: <SCRIPT language=JAVASCRIPT> <!-- nGlobal=0; function ClearBroadcast(f) { f.Broadcast.value = ""; f.Network.value = ""; } function Len2MaskCalc(nMask) { if (nMask < 1) { return 0; } nCalc = 0; for (nX = 7;nX > -1 ; nX--) { nCalc=nCalc + raiseP(2 , nX); nMask = nMask -1; nGlobal=nMask; if (nMask <1) { return nCalc; } } …
-
- 5 replies
- 3.7k views
-
-
I am not sure if merge is the right word here but this is what I mean. Let say I have two lists: ListA: {A
-
- 0 replies
- 1.2k views
-
-
I discovered this with a much more complex calc, but am able to reproduce it by doing the following: 1. Create a new database file. 2. Add a field called EntryField that is a number field. 3. Add a custom function called "Series" that takes one parameter with the following definition:
-
- 6 replies
- 1.6k views
-
-
I do not display the Status Bar. I provide record nav buttons and display the record number and found count. It seems I always need this for every table/file I work with. But I've always had to create a full calculation in every file in < 7. An attractive feature of a Custom Function is the ability to be used (and automatically associate) to every table. So I created a test Custom Function called getRecordDisplay: "Record " & Get ( RecordNumber ) & " of" & Get ( FoundCount ) But I found I still needed to create a calculation in every table with getRecordDisplay It seems counter-productive (overkill?). However, it's easier to simply refer to …
-
- 1 reply
- 1.4k views
-
Recently Browsing 0
- No registered users viewing this page.
Who's Online (See full list)
- There are no registered users currently online