How can I set up the Remote Control time logging feature?
Applicable Versions: Single User Pro, Multi User Pro
One of the coolest (and easiest) ways to integrate CC Time with other FileMaker solutions involves using the Remote Control feature of CC Time Tracting. Basically, you’ll send CC Time intructions for how to create a new time record based on the “context” in your existing solution. CC Time comes with a “Remote Control Example” folder in which a (very) simple jobs file shows you how this can be set up.
For instance, if you’re on Job XYZ in your solution, you can send CC Time instructions to create a new time record for your curently logged in user, for Job XYZ. (Sending these instructions to CC Time is very easy and examples follow below.) Once CC Time gets these instructions it will present a small mini window asking the user for details about the time their recording. Once users click “continue” the mini window dissappears an the user is back in your solution without having to see much of CC Time at all.
Best of all, you can make this kind of Remote Control entry “Contect Sensitive”. Depending on the user’s “context” within your solution, you may be able to send a lot more than just the Job and User. You could, for instance, ascertain that the user is on the “correspondence” screen of a particular project; if you’re clever, you could then send the Project, the Project’s client, the logged in user, and the Cost Center “client correspondence” (for example). In this implementation you’ld send as much as you know about a give context, helping the user pre-fill their time entry. When done well, this can make it much simpler for your users to log time as they’ll have very little to fill out for a given time entry as most of the important time attribute will already be created for them.
Here is how to set this up...
Whenever you wish to log time from your solution, you’ll run a script in your file that has 2 steps. The first sends the Remote Control instructions to CC Time. The second calls a script in CC Time to process the instructions.
Sending the Instructions You’ll first create a new File Reference in your solution for the CCTime. Next, add a table alias for the TimeTracking table to your Relationship Graph. You don’t need to relate this to anything, just placing it on your graph is enough to let you send instructions to a global field in CC Time. To send the intructions you’ll actually set the field TimeTracking::RemoteControlInstructionsGlob with a set of instructions represented as a text string. You’ll send instructoins using a specially formatted calculation in your set field script step. The syntax for this calculation can be found in a sample calculation in the TimeTracking table of the CCTime file. Look for the field called “SampleInstructionsCalc”. The calculation itself contains notes about how to format it, but for now just know that you’ll replace the word “Blank” (including the quotes) with the values you’d like to send. It is pretty simple; you only have to edit the “Let” part of the calculation.
Calling the Script Once you’ve set the TimeTracking::RemoteControlInstructionsGlob field to contain your instructions, you’ll simply call the following script in the CCTime file: “Enter Hours From Remote Instructions”.
There are just a couple things to keep in mind...
p). a) CC Time links time to clients, projects, etc. based on their unique IDs. If you don’t have unique ID fields set up for your clients, etc, you’ll need to create them before you can use Remote Control.
p). b) The layout users see when using Remote Control currently has a pop up list of Users on it. This is for those licensees of CC Time who may not have a log-in system in their own solutions, so they don’t know who the currently logged in user is. If you have such a system and do know who the logged in user is, we recommed that you remove this pop up form the layout. (The layout in question is the “Add Time - Mini Window” layout in CCTime.)
p). c) If you don’t have a log in system, you can use the one in CC Time, and simply pass “Logged In” as the user insruction. This will record the time against the person current logged in to CC Time and request a login if nobody is logged in.