Protocols
Technical Documentation

There may be occasions where you want to create a check-list of tasks or a list of procedures for users to follow. Using Premvet 5 you can create protocol scripts - on-line instructions which take the user step by step through common procedures. Additionally, these scripts can ask the user questions and the answers can be stored to the client's clinical record. With a little practice these scripts can make excellent memory joggers or even unattended training exercises for new staff.


Basic Protocol Design

Protocol scripts can be created using an editor of your choice. They are text files with various tags in it.

The body of your script will be made up of:

Before you start to enter your script, write out all the text you want to include and decide where questions will fit in and how user answers will affect the flow of the protocol. In some cases, for example, a particular user response will make a few following questions irrelevant.

Protocol scripting language

Below are the various commands that can be used in your scripts. Don't worry if they don't appear to make sense at first - there's are examples throughout this guide.

Comments & blank lines

# If you start a line with the hash symbol ( # ) any text you type on the rest of the line will be invisible to the protocol user. Use this command to add author comments. These will be useful if someone other than you needs to edit the script in the future (it will help them follow your train of thought).
. Normally, when the script is being processed blank lines will be skipped. You can make it easier to follow the script by introducing white space. If a full stop ( . ) is used as the 1st character of a line this will introduce a blank line on the screen output.
\ Lines ending with a \ will be treated as in-complete and the following line will be appended. This should be used to include text that would normally be lost. It is mainly for use within the 'Save=' option.
> Lines starting with a > will be indented by seven spaces.

Line labels:

Line labels are used to jump around the protocol, and control the flow for the end user. For example, if the user's answer to one question makes the following question irrelevant, you will want to skip it. Therefore you can give your script lines labels, to tell the protocol which line to skip to.

A label is contained in square brackets, e.g.: [label1]

You can put any text you like in the square brackets, as long as labels are not duplicated within a script and do not clash with the reserved line labels described below.

Note: Line labels and options are case in-sensitive e.g.

[fred], [Fred], [FrEd]
will all be treated in the same way.

Questions

Each question you include in the script will need to conform to the following syntax:

[] Start of Question text     'The question to ask '       { } Answer (optional)
For example:
[] History of seizures {[line]}
There are basically three ways in which a question can operate:

  1. [] Frequency of seizures

    Ask a question and wait till RETURN is pressed, used for the basic 'check list' protocol e.g.

    Title: Basic Checks (Daily) 
    
    [] Check the temperature
    [] Check vital signs {}
    [] Look at xyz
    
    The above script will simply prompt the user to 'check' (i.e. press RETURN) each of the three question.

  2. [] History of seizures { [line] }

    This question is designed to store any text the user types in. In this particular instances, the question displays a line prompt (denoted by [line] ) which will accept a maximum of 50 characters. You would use this when you expect the user's answer to be short, e.g.:

    [] How old was the animal when this started { [line] } 
    
    If you expect the user to enter an answer longer than 50 characters, substitute the [line] command for the [text] command. The program will then display a text box of five lines, allowing 65 characters on each line. e.g.:
    [] History of seizures { [text] }
    
  3. [] Any litter mates affected { yes | no }

    Where you want to present a set of options, you can specify the possible answers separated with a pipe symbol ( | ). The above will ask the question with the two possible answers being 'yes' and 'no'.

    Note: The curly brackets can be used to extend the options over more than one line. If this option is used you MUST have the bracket as the last character of the question line, e.g.

    [] Circumstances under which seizures occur {
    Sleep | Awake | Hard exercise | Excited | Other [text]
    } 
    

    Or to make it more readable, this can be expanded further:

    [] Circumstances under which seizures occur { 
    	Sleep 
    	Awake 
    	Hard exercise
    	Excited 
    	Other [text]
    	} 
    

    Note: Where you are offering users a selection of choices, the first item in the list will be the default. This can be changed with the use of the default tag.

    You may have noticed in the above option the 'Other' answer has a qualifier added '[text]'. This is used to expand on the answer, in this case, if 'Other' is selected a text box will pop up to ask for further information.

There are other qualifiers that can be used and are described in the the later section.

Protocol script examples


The following examples are included to help you get to grips with creating protocols:
[] Continue { Yes [nostore] | No [abort] } 
Two options Yes and No. If No is selected then quit without saving, otherwise carry on without saving the question or answer.
[] Is the animal normal apart from the seizures? {
   Yes [save="No reported signs other than seizures."] 
   No  [save="The client reported:",text] } 

If Yes is selected store the text 'No reported signs other than seizures'. If No is selected, the text 'The client reported:' will be saved AND the user will be prompted with a text box so they can enter further details.

[] Previous illness / trauma / surgery / anesthesia { yes [text]| no }
Ask the question. If yes is selected then ask for additional information.
[] { Single | Clusters }
In this case there is no question, the user will be prompted to answer either Single or Clusters. Use this sort of question where you have explained the options in preceding text.
[] Previous anticonvustant treatment { Yes | No [to-here] } 
If No is selected then jump to the label within the script called 'to-here'.


Index File

You normally access protocols either via an Automatic Pricing Procedure or by the pr'O'tocol option on the clinical prompt line.

The protocol filename should have a suffix .pro e.g.

seizure.pro
By default, when accessed via the 'O' option, the system will list all protocols files (by looking for *.pro in the text folder) on your machine. If you only have a few then this procedure is fine, however, as you start to use more and more then the list will get a little messy.

You can create one or more 'Index Files' to group together related protocols, hide work in progress, hide protocols that should only be called via AP.

The procedure is identical to that you may be using for your definition files. See the FAQ Organise your Definition Files for the procedure. The top level index for protocols is: text/protocol.idx.

We have included two samples, Protocol.idx and Sample.idx, rename those to be protocol.idx and sample.idx respectively and edit to suit.


Calling From Automatic Pricing

If you want to call a protocol file from within an Automatic pricing procedure you can use ^37=filename on the extras line. You do not need to specify the suffix .pro as this will be assumed. If the protocol file does not exist it will silently be ignored.

If no argument is given either a pop-up box or the Index with all the protocols will be displayed.

If you are specifying a specific file and are wanting to include the title in the clinical records you should specifically use the [clinical] option.

When called like this you can 'pass back' information to the animal card. See the [passback] option.


Tags and Protocol Commands


Reserved labels

The following labels are reserved, they are not commands or tags, they have a 'special' function. All are optional.
MENU
[menu] if a user exits a menu with the <ESC> key the system will jump to this label.

Tip: If you are wanting a 'get-out' on simple scripts then add at the END, after a [goto quit] the following:

 .....
 [goto quit]
 [menu]
 [goto abort]
As this is at the end it is not normally used, the 'quit' just prior will handle the save etc. and the 'abort' will exit with no save.

START
[Start] used to indicate the start of the protocol and is mainly used to 'skip' any introductory comments.

GOTO

[goto xxxx] - Allows you to 'jump' around the script. The label you want to jump to is specified as XXXX. e.g.

...
[goto menu]
...

There are three reserved XXXX options to goto:

abort Jump to the end of the script, do NOT SAVE the answers.
quit Jump to the end of the script, SAVE the answers.
exit Jump to the end and prompt if you want the answers saved.

TITLE/NOTITLE/ATTACH

[notitle] Do NOT add a title, this is the default if the [html] or [pdf] options are enabled.
[title xxxx] Use xxxx as the title
[attach xxxx] Use xxxx as the attachment description.
The Title of the protocol will initially be set to:

If the script encounters the tag [Title] XXXX then XXXX will be used (XXXX will be checked for Reserved Words).

The Title will be used in a few places.

The default is to do all the above however, there will be occasions where this is not desirable.

If you do NOT want the title added, you can:

If a protocol is attached to the animal card the system will normally use the 'title' as the Description.

To change the description used when attaching the results you should use [attach XXXXXXXXX]. In this case the text XXXXXX will be used. (XXXX will be checked for Reserved Words)


Questions

When we looked at questions earlier you saw the [line], [Char] and [Save] tags that could be applied.

The full list of qualifiers that can be used:

[text] Prompt for the text box, normally the text box will be 5 lines, this can be changed by [text x] where x is the number of lines.
[line] Prompt for a line answer, there are some additional sub-options:
[line 5] the '5' will limit the line length to 5, [line 10 10 characters etc.
[line //blah// use blah as the default answer, it will be changed for reserved words.
[char] prompt for RETURN
[nostore] Don't store the question or answer in the output file.
[save="..."] Rather than storing the question/Answer displayed on the screen, use the text within the quotes instead. Lines can be continued by added a '\' to the end of the line. The text will be checked for reserved words.
[quit] Jump to the end of the script, SAVE the answers.
[abort] Jump to the end of the script, do NOT SAVE the answers.
[exit] Jump to the end and prompt if you want the answers saved.
[IMAGE] See [Image tag
[HTEXT] See [HTEXT tag
[INCLUDE] See [Include tag
[PRINT] See [Print tag
[PASSBACK] See [Passback tag
[CLINICAL] See [Clinical tag
[SETV] See [Image tag
[file(] See [file( tag
[?TABLE] This could be
See [atable tag
See [ctable tag
See [vtable tag
See [wtable tag
See [rtable tag
[...] Jump to the label specified.

DEFAULT

[default x] - Set the default the question will use. If you use [default 3] then the 3rd menu options will be the default.

The setting for [default x] will stay in affect until another 'default' has been issued. This enables you to direct the flow of the script. e.g.

[Default 2]
[Goto heart]
This will set the default to be the 2nd menu option and then jump to the option 'heart'.

PRINT

Comes in two forms:

[print]
Print the results of the protocol at this point in time to the default printer, if the HTML option is enabled then filter the results via lynx. Normally the [print] will be at the end of the file BUT this is not a requirement. Once printed you can continue to add comments etc.

When the 'print' option is used it will use one of the following:
Output as Command used
Plain Text cat RESULTS | 'default formatter' | 'default printer'
HTML cat RESULTS | lynx -dump -force_html | 'default printer'

(Default formatter is: | par P=_q j )

[print filename]
This will printout filename, it will check for and replace reserved words etc. It will NOT include any of the protocol file, just prints a definition file. e.g. [print new.pro]. You can use this as an answer to questions e.g.
  []!Print a Hills QC form {
         Yes [print hillqcrof.def]
          No [nostore]
       }
This will process the the 'hillqcrof.def' file if they answer Yes to the question.


INCLUDE

[include filename]

This will include a file into the main protocol file, reserved words will be replaced, blank lines will be included if they are present in the included file. No screen output, the store / nostore option is ignored. e.g. [include new.pro]

When using the [include filename] option, you can stop lines being formatted by prefixing them with a quote (').

Definition files also have the ability to handle 'if/else' question - e.g.

 .if species = canine
Add this text relating to dogs
.el species = feline
Add this for cats
.el
This is for anything other than cats and dogs
.fi

So you can adjust the output to make sure the text is appropriate to the animal. These def files can be added based on the answer using the [include tag e.g.

Adv Empty anal glands every 3 mths [save="To prevent 
recurrent anal gland problems, emptying every 3 months
is advised."],\
[include analg.def]
Here the definition file 'analg.def' will be added only if the user selected the 'Adv Empty anal glands' option.


COMMAND

[command command]

Take the result of the operating system command given and store the answer in the protocol file. You can include the name of the protocol file by entering a % symbol e.g: [command lpr % ] does the same as the [print] option, or you can read in the date with [command date].


PIPE

[pipe command]

Take the current output of the protocol file and 'pipe' it into the command given.

A '%' sign will be replaced with the name of the results file. Any output from the command will be discarded e.g: The entry [pipe mail -s "protocol file" vet] will mail the user vet with the full file.


BEEP

[beep xx]

The Beep tag will as the name suggests, tell the system to 'beep' when encountered. The xx can be number of times to beep, if it is not specified then 1 will be assumed.


COLOUR

[colour xx]

Display the following text using colour event xx, if xx is missing (or 0) then revert to normal text.

This fragment will display the text 'Summary Report' using colour event 220.

[colour 220]  
Summary Report
[colour 0]    


Standardising The Look

If you want to customise the 'top' of the page, if you just create the file 'name-of-protocol.top' e.g. wellpet.top, this will be used automatically. Likewise 'name-of-protocol.bot' e.g. wellpet.bot, will be added at the end of the page. The XXX.top file will be inserted after the 'body' tag. The default for top is the Protocol title, while the default if the XXX.bot file is missing is 'Prepared by date'.


Style sheets - When generating HTML you can use `style sheets' - If there is a file 'style.css' in the sheets folders it will be included automatically in the header. This allows you to load standard style sheets to all your protocols.

You can use [style filename] to use another style you want. If when using the [style.. option the filename does NOT contain a '/' it will be taken from the Sheets folder.

The style.css can be a full style sheet reference e.g.

<link rel="stylesheet" type="text/css"   
     href="../../protocol.css"  
     title="protocol css">
or an in-line style sheet e.g.
<style type="text/css">
  H1 { color: blue }
  </style>

The choice is yours.


HTML

Adding [html] to the top of the document will enable the Web Based output. With this option enabled the top/bottom of the document are as follows:


PDF

Adding [pdf] to the top of the document will switch on the html option and save the resulting file as a PDF document.


ANIMAL TABLE

[atable] - Animal Table - This will add a table showing the animal Name, Species, Breed, Date of Birth, Colour, Sex and Insured.

If there is a Image of the animal it will be added, otherwise

e.g. Here is an example with no image:


Puttle
Species Canine Picture
Breed Chow x Inuit
Date of Birth 16.07.1976
Colour BLUE
Sex Female
Neutered/Spay Yes
Insured Not Insured

Note: The system will include the jpg 'no-image.jpg' from the sheets folder. If you want to use a different picture just replace this jpeg.


WEIGHT TABLE

[wtable] - Weight Table - Shows current weight and date last recorded.


Weight ( Optimum 2 Kgs. )
Weight Last Recorded
3 Kgs 12.11.2007



REFERRAL TABLE

[rtable] - Referral - If the animal is a referral then this will add in the Referring practice name and address.
Referral Details
Practice Referral Veterinary Group
Address Station Rd
  Chrinside
  Borders
  TD11 3QQ
Telephone 01361 883111


CLIENT TABLE

[ctable] - Client Table - This will add a table with the owner name and address.
Owner Details
Mrs Melvin
21 Station Hill, Duns, Chrinside
Borders , TD11 1WW


SHOW

The [Show ....] option displays information on the screen.

the full list of options is:

Species Species
Breed Breed
Client Client Name
Animal Animal Name
Colour Animal Colour
Age Age of Animal
Idnumber ID chip number
Dob Date of birth
Sex Sex of animal
FullSex Expanded Sex of animal e.g. male entire
Insured Who it is insured with
Weight Weight of animal
Optimum Optimum weight for the breed
Vaccination Date of last primary Vaccination
Email E-Mail address


FULLSEX

When working out the 'full sex' details the system will take each character in the sex field and build up the details using the following:
M male
F female
E entire
N neutered
G gelding
S stallion
The 1st letter of the finished string will be converted to upper case.


WARNING

[Warning XXXX YY] - add a warning to the screen is the criteria is not met. XXX can be one of:

Tag Text That Will Appear
WEIGHT Last weight recording was: `date last recorded' please update.
DEAD Animal marked as dead on 'date of death'
VACCINATION Vaccination Overdue - Was due: `date due'
INSURED Animal is NOT Insured.
IDNUMBER Animal has NO ID Chip.

YY is the number of months over due.

There must be two fields even if the 2nd option does not make sense.

It will use colour event 212.

These three lines will report is the animal has no ID Chip, is not Insured or has not had a weight recording in the last 3 month.

[warn insured 0 
[warn idnumber 0
[warn weight 3  


Charts and Graphs

All Charts start with [CHART_xxxx where xxxx is one of the following:

TYPE yyyyy
Signifies the start of building a chart, you cannot have two charts on the 'go' at the same time, you can however start a chart and spread it's creation over multiple questions.

There is no limit to the number of charts that can appear in any protocol, you must finish one chart before starting another.

yyyy - Type_of_Chart - presently the only supported Type at present is weight-basic for a basic weight or Lab result graph e.g. as per Existing Weight and Glucose.

TITLE Title
Adds 'Title' to the top of the Chart
SUBTITLE Title
Adds 'Title' as a Sub_Title at the bottom of the chart
DATA X Ana_Code Months
X Chart Type - W = Weight, L = Lab (if W is specified then Optimum weight will be included if available)
Ana_Code Analysis code to chart - (WGT will be Weight Ana Code)
Months Include data for the LAST xx Months (approx) (If not specified then include ALL data)
OPTIONS xyz
If there are any options to be added to the <img src=...> entry then specify them here.
DRAW xyz
Inserts the chart at this point in the protocol, this 'ends' the process and the current chart settings are reset ready for a new chart if needed. xyz are options to pvchart if needed.
E.g.
[Chart_type  weight_basic
[Chart_title  &animal's Weight 
[Chart_data W 229 3
[Chart_draw]


Image of animal

The image the system will use is taken from the 'Image of Animal' on the attachment screen. This can be in any format your browser can support.


RESERVED WORDS

The text will be checked for some reserved words (at present these must be in lower case):

&animal Animal Name
&practice Practice name.
&breed Breed
&species Species
&heshe he/she/it
&himher him/her/they
&age the Animal age.
&optimum Optimum weight.
&weight Animal weight.
&age Animal age.
&email E-Mail address


Setting Options (setv)

With weights in particular, you may want to use the Passback option to pass back to the systems new weight you have obtained for the user. However, the 'passback' feature works once the Protocol has been finished. If you are referring to the the weight later on then the old weight will still be used. You can circumvent this with the [Setv ....] option. This will 'set' some specific options to allow the details to be used during the protocol run.

This is generic to allow for other options to be added later.

The options are:

kgs Weight (answer in Kgs)
lbs Weight (answer in Lbs and converted to Kgs)
opt Optimum Weight - set's the optimum weight
email E-Mail - set the Mail Address
nomail E-Mail - Remove Mail Address and set to NCC
okmail E-Mail - Set E-Mail to Yes

For Weights, you could use it like:

[]!Weight { 
    Continue [nostore]
    New Recording [line 5 ], [setv kgs], [passback WGT_AP ANSWER]
    }
[show weight]

This will ask for the weight, assume it's in Kgs., set the weight so the following 'show weight' is correct and then pass back when finished the AP code 'w' with the weight as the multiplier.


SQL

[sql scriptname] - This will run the DataMajor script 'scriptname', which should be located in the text folder. These scripts are identical to those on the custom screen and the same scripts can be used (see read220b option 10). The 'scriptname' should be in lowercase. The output will be added directly to the protocol result file. Remember to include animal number as &ref.

For example, here is a basic script to pick up all work on analysis code 242 and 254 in the last 2 years.

Select TransactionDate, ClinicalText From clinical 
Where ( AnalysisCode = 242 or Analysiscode = 254 )
And transactiondate > now() - interval 2 year
And pvid = &ref order by 1;

If you have the html option enabled then the output will be suitable to Web Pages otherwise it is formatted as a table. See the htext option below for more details on formatting Web Pages.

DATA

[data what] - Very similar to the [ sql option, in this case you do not need to worry about generating sql scripts. Part of DataMajor tags all clinical lines based on your Itemised Billing categories (groups) - the [data option uses these.

You may have a billing category (slot) set for 'Dental Work', if you use [data dental] then it will list all work where 'dental' is contained in the description - that is 'Dental Procedure', 'Dental Products' etc. the 'text' it looks for can appear anywhere in the description.

For a list of the descriptions use:
DataMajor -> Stored Reports -> Analysis options.

The default will be to list the last two (2) years - this may not be appropriate for say diets, you have the option to do [data diet xx] where xx is number of years (you can include fractions e.g. .5 is 6 months, .25 is 3 months etc.)

Note: If you have any '[data xxx' entries the default formatter will be disabled as you don't want the data re-formatted. You can over-ride this by using the [format ....] command AFTER all [data..] lines have been used.

Note: the script behind the screens to generate this is text/proto.sql - which will created if it does not exist. Once there you can change it if required:

Select date_format(TransactionDate,'%d.%m.%Y') as 'Date', ClinicalText
From clinical inner join agroup using (AnaGroup)
Where GroupDesc like "%&what%"
And transactiondate > now() - interval &year year
And pvid = &ref order by 1;

FILE(

[file(filename text)] - this will read the file 'filename' for the label 'text' and include all the information following it until either the next label or the end of the file.

The filename is relative e.g. it does not have a '/' in the name it will be assumed it resides in the text folder.

This tag can be used in a number of ways, one large file, lots of little files (one per main body area), generic files etc. The data can be shared between multiple protocols e.g.

[ears ok]
The ears are ok and do not need any ....

[ears clean]
The ears need cleaned .....

If these were saved in say ears.txt then using [file(ears.txt ears ok)] will include the block relating to the label 'ears ok' etc.

You can use the reserved words mentioned earlier, e.g. if you have all the inherited diseases in a file breeds.txt you could use [file(breeds.txt &breed)] to lookup details on the breed you are generating the protocol for. Some practices have a mixture of breeds, 1st off use Data Major to tidy them up!! or you can use multiple [label] entries e.g.

[GSD]
[German Shepherd]
[Alsatian]
Text here will be added if any of the above labels are matched

OPTIMUM

Optimum Weight

The above 'file' option is used when the system is asked to lookup the optimum weight of the breed. This is used when either the [show optimum] or the [wtable pseudo labels are called.

The 'Breed' is looked up in the table 'text/weight.txt' - it does not matter about Species - just all add the breeds to the one file:

[Affenpinscher]
 4 / 3 

[Hound Afghan]
[Afghan Hound]
27 / 22.5

[Terrier Airedale]
[Airedale Terrier]
 21.5 Kgs.

[American Cocker Spaniel]
 NS
The system will use the Sex field and return the text before the '/' if sex starts 'M', the text after if Sex starts with 'F' or Unknown if blank. The text 'NS' will return 'Non-Specific. The word 'Kgs.' will be added of not already specified.

This can be regarded as a 'general' weight, in many cases it will be sufficient, however, in the case of Weight Clinics you may want to get an 'ideal weight'. This may not resemble what is returned from the breed file. This question:

[] Ideal weight if not &optimum { [line, 5], [setv opt] }
Will ask for the 'ideal weight', you will be able to see the optimum weight ( reserved word &optimum), if a weight is entered it will be available ( setv opt) for inclusion in text and graphs. It will for the duration of the script be available as &optimum.


Logo's and Images

[image filename] - The handout can be customised to add some pictures, logo's, images etc. This is done with the [image tag for example, if you want a Frontline logo, save the image to the sheets/images folder, and add:

[image frontline.jpeg
This will include the image 'frontline.jpeg' at that point. The default location for images will be sheets/images folder. If the system finds a '/' in the image name it will taken as a location relative to the animal folder.

You can use the htext tag to 'tweak' this further, to centre it use the [htext tag e.g.

[htext <center>
[image frontline.jpeg 
[htext </center><p>]

The image will be added 'as is', if you want to have multiple images or adjust the sizes you can use:

 
[image drontalpluslogoprod.gif ]
[image milbemax.jpg height="140" depth="97"]

That example will add two images side by side, and adjust the size of the Milbemax picture.

You may want to alter/add the image (or definition file) based on the answer the user gave. This can also be done.

[] Skin and Coat {
   Fleas Present [ Save = " Fleas have been found .....
    .... control by 2 injections skin/coat problems."
   ],[htext <center>],[image frontline.jpeg],[htext </center><p>]

Here the htext and image tags are used as options and the Frontline logo will be added only if the user has selected this option.


VACC TABLE

[vtable x y z . .] - Recall Table - If recall x or y or z or . are set create a table with those recalls in them (in the order specified), showing Last done, Next due (Month/year) and Interval (in weeks). This can be used for any recall not just vaccination - any of the pop-up, food, dental work etc.


Recall Last Done Interval
VACCINATION 18.09.2007 50


e.g. If Vaccination is recall 1, Rabies recall 10 and Kennel cough if 15 with Felv being 7 then [vtable 1 10 15 7] will display any of the those recalls found for the animal you are on.


VTEXT

[vtext some-text] - Tied to the recall Table - this sets the title to print on the following vtable.

The initial default will be 'Recall Status'.

e.g. Say you have a recall, number 55 being set every time a client buys prescription Diets. You could add:

[vtext Prescription Diet]
[vtable 55]

This will give you a table titled 'Prescription Diet' with the date the last time the client purchased items tagged as a diet. e.g.


Prescription Diets
Recall Last Done Due Interval
Diets 07.12.2007 Feb 2008 12 Weeks


Note: If there are no recalls matching what was entered on vtable x,y then NOTHING will be included in the output.


SHOW VTABLE

The [show vtable x y x .] option is similar to the ' vtable' option explained in the next section except this will be displayed on the screen.


STORE

[store] Start storing ALL the screen output in the external file until the NOSTORE label occurs.

NOSTORE

[nostore] Stop the storing of screen output.

SAVES2

Adds records to Screen 2 (Condensed History).

This example will record the protocol starting, ask a question and then record the results.

ALL animals receiving treatment for otitis externa must have
the following assesment:

[]Continue {yes[nostore]|No[abort]}
.
[saves2]  Ear assesment protocol undertaken
.
[]Are any of these statments true?{
                >=5 Ear presc in last 2 years
                On atopy prot + 2 Ear presc  
                Unresovable V. Canal pathology 
                Positive swab result
                None of the above [qu2]
                }

[saves2] ANSWER
[saves2] POTENTIAL SURGICAL CANDIDATE
[goto qu3]


FORMAT

[format command] Passes the whole document through one of the system 'formatters' which should be specified in command. The default will be par and is used to get rid of long and unsightly lines.

Default format command: | par P=_q j

Disabled if PDF or HTML tags are used


DEBUG and RESET

These are used to set/alter some options used by VS. The tags are reserved.


VSL

[VSL_xxxx tags will be ignored. We are using them for in-line documentation - feel free to emulate the tags we are using.


LINE

[line] Draw a line on the screen.


MAILOK

If E-Mail is set to Yes, YDU or NCC then no action will be taken the script will exit. If E-Mail flag is set to No then the protocol will continue.

This can be used to run a script only if there is no valid mail address.

There are Setv option to set/edit the E-Mail address. They could be used like:

[]!E-Mail { 
    Exit [abort]
    Confirm Mail OK  [setv okmail]
    Remove Mail Address [setv noemail] 
    Add/Edit Mail Address [line //&email//], [setv email]
    }

Note: The //&email// sets the default for the question.


HEADUP/HEADDO

Can force the system to think the heading has or has not been displayed.


HLINE

[hline] - Draw a line centred, width 80% (HTML/PDF options).


HTEXT

[htext some text here] - This will add the text directly to the resulting protocol file. For example, if you wanted to include some DataMajor information and format it to match the rest of the document, you could use:

[htext <h3>History of Wormer Purchases</h3><p><dir>
[sql worm.sql]
[htext </dir>]
[hline]

Will add the heading 'History of Wormer Purchases', run the script 'worm.sql' which will list all the wormers the client has purchased, indented to match the other tables and add it as a table then draw a line.

The [htext option is handy for adding additional information. When the [pdf option is used, the pdf processor looks for additional tags for details on document formatting e.g. to take a new page use:

[htext <!-- PAGE BREAK -->]

In this case you can also add html code to alter the font:

[htext <span style="font-family: Helvetica, Verdana, Arial, sans-serif">] 


NOSAVE

Adding [nosave] to the document will alter the defaults when the run has finished. Normally, the results will be saved to the animal card, the default for 'Save' will be Yes. When [nosave] is used the results will NOT be saved and the default will be No.


CRLF

[CRLF x] this will print x blank lines to the protocol file. If x is omitted it will default to 1.


CLINICAL

[CLINICAL XXX Text - XXX is optional ana code ( between 1 and 255)

Add the 'text' to the clinical screen.

[] How long did the surgery take?{
   1-5 min
  6-10 min
 11-20 min
 21-30 min
 30-40 min
 >41 min }

[clinical] 100 Time: ANSWER

Here the clinical line will contain the length of time surgery took (and given analysis code 100) e.g. Time: 11-20 min


PASSBACK

[passback] - When called from AP commands (^37=), you can 'pass back' AP/Stock codes which the system will continue to process.

The format is: [passback] ap_code e.g.

    [passback] 20 syn250 
which will dispense 20 Synulox 250mg tabs.

Params.txt Entries

There are two options that can be set:

Weight_AP_Code
(Default 'w') The Automatic Pricing code for recording Weight.
Protocol_Title
(Default Y) WILL add a title See Also NOTITLE

Index

Index under Construction


Sample Examples

Here are some examples to show how the protocols can be used.


Body Score Index

This script will ask the use to enter a 'score' for the Body condition, the '!' as the 1st option will stop the user from just entering return.

The answer will be added to the clinical record under analysis code 155.

Title: Body Condition Score
[start]
Use this to record Body Condition Score 
[]What is the animals body condition? {
             !
             BCS1 Very Thin
             BCS2 Underweight
             BCS3 Ideal!
             BCS4 Overweight
             BCS5 Obese
                }
[clinical] 155 ANSWER

[goto quit]                              

Surgical Procedure

Title: SURGERY GROUP 3:
[start]
Use this protocol to record which operation in group 3 you have undertaken.
[]Continue {yes[nostore]|No[abort]}

[clinical]
[store]

History
.
[show breed]
[show species]
[show age]
[show sex]
.
[nostore]

[]What was the operation? {
	Gastric torsion
	Prox. Tibia physis
	Anal gland removal
	Urethrostomy	
	Simple platings radius & tibia
	Total mammary strip
	Lateral fascia lata overlap trochleoplasty and or tibial crest transposition
	Aural resection
	Enterectomy
	Repair of ligaments
	Pyloroplasty
	Im pin mc and mt	
	K-wires and tension band
	Perineal hernia
	Lat.condyle # humerus
	External fixators
	Dog & complex cat mandibular 
	Cruciate & meniscal tear
	Elbow luxations surgical
	Arthrotomy
	Plating femur & humerus shaft
	Excision arthroplasty
	}

[] What is the expected outcome of this operation?{
	[text]}

[] Were there any complications during surgery?{
	Yes|No[qu1]}

[] What were the complications?{[text]}

[qu1]
[] How long did the surgery take?{
	1-5 min
	6-10 min
	11-20 min
	21-30 min
	30-40 min
	>41 min }

[goto quit]


Cardiac Reminder

In this example it provides a reminder of the signs and aetiology of Congestive Cardiac Failure.

Title: Congestive Cardiac Failure
Author: Canine Internal Medicine Page 61

# The [Start] Label is a special label indicating where to start
# processing the file. This Label is optional.
[Start]

Extract from Canine Internal Medicine (Darke)
.
This includes signs of simultaneous failure of both left and right sides.
However, neither side is in isolation and a degree of failure of both
sides is often present especially in volume overload.
.
[] { Aetiology [aet] | Signs [sig] | Findings [find] | Quit [abort] }

[aet]
Aetiology:
.
  a. Left to right shunts, including:
       i.  Patent ductus arteriosus.
      ii.  Ventricular septal defect
  b. Myocardial failure
  c. Sequel to left or right-sided failure.

[] { Signs [sig] | Findings [find] | Start [Start] | Quit [abort] }

[sig]
Signs:
.
  a. Lethargy, exercise intolerance, weight loss.
  b. Dyspnoea
  c. Coughing
  d. Abdominal distension

[] { Findings [find] | Aetiology [aet] | Start [Start] | Quit [abort] }

[find]
Findings:
.
  a. Usually a weak, rapid pulse.
  b. Often dysrhythmias
  c. Usually murmurs

[] { Quit [abort] | Signs [sig] | Aetiology [aet] | Start [Start] }

[abort]