o
ZuluLog Sign In
OR
Forgot your password? Reset it now
Need an account? Sign up free
Remember me
Sign in
OR
Looking for an online, multi-user solution for your company?
Start here.
Sign In Using:
 
  Contact Us Sign In  
 
ZuluScript: Custom Columns in Pilot Logbook Setups
When creating a custom column setup, for each position you can specify either a predefined column (e.g. "Aircraft ID") or use a script to create a custom column value, in which case you'll select "Script Column" from the drop-down and enter your script on the right-hand side.
Before working through this column script, make sure you've read the examples for custom currency definitions. The scripting is mostly the same, but there is no initialization script (because there's no need to accumulate values between flights) and the predefined variable you'll use is called col_value rather than currency_ok.
Example: Conditional Column Value Based on Landings
The following script will display one of three values:
  • "Night Currency" if three or more night full stop landings were performed on this flight; otherwise
  • "Day Currency" if three or more landings of any type (full stop or touch/go) were performed on this flight; otherwise
  • The column will be blank.
Script:
	  if (getfieldnum("Night Full Stop") >= 3) 
	    col_value = "Night Currency";    
	  else 
	  {    
	    var nn = getfieldnum("Day Full Stop") +
	             getfieldnum("Night Full Stop") +
	             getfieldnum("Day Touch/Go") +   
	             getfieldnum("Night Touch/Go");  
	    if (nn >= 3) 
	      col_value = "Day Currency";
	    else 
	      col_value = " ";
	  }
	
How it works:
The script sets the predefined variable col_value to the appropriate string for this column, based on the number and types of landings performed.
Back to help index   Next article
 
Version 7.1.1.490
 
© 2024 ZuluLog LLC  All rights reserved Privacy | Terms of Use