On this page you can create or update a Custom Function.
The Source Code can be C# or SQL and in either case valid Custom Function Code should be entered.
You can validate the Source Code by clicking the button labelled ‘Validate’. This will check that Medidata Rave considers the Source Code to be valid. Where possible the line(s) which have error(s) will be indicated with an error icon in the left-hand side bar.
TrialGrid will use a recent version of Medidata Rave to validate the Source Code. It is possible that older versions of Medidata Rave validate Source Code differently (for example, having fewer restrictions on allowed C# methods). For this reason TrialGrid will allow Source Code with errors to be saved.
While editing C# Source Code you can display an autocomplete list using Control-Space (press and hold the Control key and then the Space key). This will display a list of allowed C# classes and methods taken from the Medidata Rave documentation
The autocomplete list will be filtered using the text to the left of the cursor. For example showing autocomplete for this C# code
will display an autocomplete list starting with:
DataPoint.Enter(string, string, int) DataPoint.Enter(string, string, Medidata.Core.Objects.DataEntryState) DataPoint.Enter(string, string, string, int)
You can use the scroll up and down the list using the mouse or keyboard. Typing more characters will filter the list further. You can select an item using the mouse or with the Tab key.
The method signatures are displayed in the autocomplete list but will not be inserted into the code on selection of an item.
Classes and methods which are deprecated by Medidata and/or not supported in Rave EDC (RaveX) are highlighted in red.
The autocomplete functionality is not ‘intellisense’. It filters the list based on the text to the left of the cursor but does not analyze the code to work out class types. In the following code no autocomplete will be displayed because TrialGrid does not know that ‘dp’ is a DataPoint
DataPoint dp = afp.ActionDataPoint; dp.Enter