Just thought I'd add to my post above, that I've found a free way to generate a GUID in Filemaker. You'll need Visual Studio Express edition (Or similar) for this.
Download and install the DotNet2FM plugin from: http://www.dotnet2fm.com/ (A donation to the author would probably be appreciated).
Follow the instructions/tutorials for the plugin to create a new class library function that returns (The code has been butchered a bit by me in Notepad to remove unrelated code, so apologies for the wrapping) :
using System;
using System.Collections.Generic;
using System.Text;
using System.IO;
using System.Xml;
using DotNet2FMInterface;
using System.Net;
namespace fmConnector
{
public class fm : IPlugin
{
public fm() { }
public string PluginID
{
get { return "fmConnector"; }
}
public short MethodBase
{
get { return 10000; }
}
public bool CanIdle
{
get { return false; }
}
public bool CanPreferences
{
get { return false; }
}
public void Init(IEnvironment environment) { }
public void Shutdown(IEnvironment environment) { }
public void Idle(IEnvironment environment) { }
public void Preferences() { }
public enum Methods
{
GUID,
MethodCount
}
public short MethodCount
{
get { return (short)Methods.MethodCount; }
}
public IMethodInfo GetMethodInfo(short nMethodIndex)
{
switch ((Methods)nMethodIndex)
{
case Methods.GUID:
return new MethodInfo("GUID", "GUID()", 1, 1, MethodFlags.MayEvaluateOnServer | MethodFlags.DisplayInAllDialogs);
}
return null;
}
public bool InvokeMethod(short nMethodIndex, IEnvironment environment, IDataVector parms, IData result)
{
switch ((Methods)nMethodIndex)
{
case Methods.GUID:
return Guid(parms[0], result);
}
return false;
}
// Guid Method
private bool Guid(IData name, IData result)
{
result.AsText = System.Guid.NewGuid().ToString();
return true;
}
}
}
Compile the library and drop the DLL into the FilemakerDotNet2FM Plugins folder.
You should now see the function available in Filemaker that will return a GUID :