Home

Cardbox Talk

 

CardboxForumsCardbox Talk > "Help with Validators - creating pick lists"

Help with Validators - creating pick lists

Current user: [none]
Register / Log In · Help

Posted By Post

Bernard B

30-Jul-2008 10:47

Hi,

I'm using Cardbox 3 (Professional) to catalogue a mix of print and electronic resources held in a small specialist library. I want to use validators / pick lists to contain a controlled vocabularly /specified list of terms that I would then add to a subject field in each catalogue record. These terms might consist of a single word such as "disabilities" or more than one word, such as "mental health services". I'm clear on how the lists work, and how to access and use them within Cardbox - my question is can these lists handle terms that are more than one word (i.e. like "mental health services", which I can then apply to the relevant field? I may have overlooked something, but as far as I can see the lists can only contain single words. Is there a way in which the lists can contain terms of more than one word? If anyone knows the answer, I'd be extremely grateful to hear from them.

Bernard Barrett

Mary Doyle (DAF)

30-Jul-2008 11:47

Hi Bernard,

This is our way of verifing keywords, classification codes etc.
Store the keywords in a separate database, then call the macro with a keystroke or pushbutton or whatever you choose to activate the database, select the relevant keyword term(s) (single or multiple words) and transfer it to the relevant field in your catalogue database.

You will need to adapt the sample below, which is based on our classification code transfer (we are too short-staffed to keyword, though I do have a keyword sample somewhere). You will have to add a bit to get rid of leading spaces if the variable KeywordsListedAlready is blank - if you need help to do this I will do it later for you when I have a bit more time.

The actual macro we currently use pre-dates my current scripting knowledge. It is a litte more crude but it works and "if it ain't broke, don't fix it!). It doesn't require removing the spaces, as it goes to the end of the field and pastes the new keyword in after the last one - I think we manually type in a comma after the existing keyword before calling the macro - haven't done it for a while. For reference I will add it at the end.

Hope this helps.

Mary

Activate "thes"
'******************************************************************
'This activates the database that stores our keyword list"
'******************************************************************
Database.ClearTagged
SelectionLevel=0
Format="disp"
Pause "Select and tag keyword"
SelectTagged
KeywordToCopy = ActiveRecord.Fields("kw")
'******************************************************************
'This will copy whatever is in the field - single or multiple words
'******************************************************************
Activate "Catalogue"
'GoToField "SU"
KeywordsListedAlready = Fields("kw")
Fields("KW") = KeywordsListedAlready & " " & KeywordToCopy

Exiting macro - actually used to copy classification codes:

'Written by Mary Doyle, Librarian, DAFF
'This macro looks up subject codes and transfers the selected
'one to the Subject field in the Catalogue

Activate "class"
Database.ClearTagged
SelectionLevel=0
Format="disp"
Pause "Select and tag subject" ' e.g. sheep
SelectTagged
Code = ActiveRecord.Fields("cd") ' classification code
Activate "Catalogue"
'GoToField "SU" ' We have commented out this line, as we call the macro when
'we are in the SU field.
Command cmdEnd+cmdControl 'to go to end of existing text in the field
TypeText Code ' This pastes the classification code

R. Woodhouse

30-Jul-2008 13:07

Dear Bernard,

Martin helped me write a macro which called a separate "Lexicon" database. It was called knowing the field that it was called from, and selected all Lexicon records related to that field. It then displayed a format with the long description of the keywords, allowing you to tag those desired. On selecting return to database it copied the text in the related Lexicon short keyword field and appended them to the end of whatever was already in the database keyword field. I found this much more flexible than the pick lists / validation built into Cardbox. Do remember to add a sort field in the Lexicon database to force it to sort the items in the order you want. I think the basics are in the Macro and Programming Manual.

Good luck with your project
Robert

bert

30-Jul-2008 15:00

Hi Bernard,
I prefer in most cases a pick list. It is very fast, especially using the keyboard. F4, type first characters of a term for fast scrolling, use cursor, on the right term? [Enter] and it's in your field. Spaces are inserted automatically. Repeat it for every term. Very quick. Ok, "mental health services" you have to store in your list as "mental_health_services". In a keyword field of your record is this fine: you can see where your 1st term ends en where your 2nd second term begins (not always clear...!) The underscores can be suppressed in printing.
An external text file is easy to edit. Do not need to sort. The pick list does it by itself. A pity that you cannot use such a list when a db is stored for Internet use. A link to a file as "cardbox://ip or name/kw.txt" is not [yet????] supported.
Store a list in a format is a little potting. The text dialogs are too small. However, this works even by internet access.
As Mary wrote, a separate db can be a good solution. However, you need to macro it very good and it needs (much) more clicks. As a former RSI patient is that to me an important argument.
Kind Regards
Bert

Mary Doyle (DAF)

30-Jul-2008 15:33

Hi Bert,

We use a separate database because we can include notes about the term being used. Also we use keyboard shortcuts so we don't have to click - I try and discourage people using the mouse - I have even penned a document entitled "The Mouse Trap - how not to use the mouse and avoid RSI"! I have taken on your idea, though, of entering the first few letters of the term we are looking for before hitting F9 to go off to find it. It speeds it up a little. So thanks for that.

Mary

Charles Welling

30-Jul-2008 18:40

If anyone is interested: I use a separate thesaurus database which I made in Cardbox (of course). The thesaurus includes preferred terms, non-preferred terms, broader terms and narrower terms, meronyms and holonyms and similar relationships for placenames and persons.
It works with composite terms (more than one word) up to 64 characters in non-Unicode thesauri, which has to do with the maximum number of indexed characters.

You can easily create your own types of links without having to change the macros. The maintenance macro does almost all things that a real thesaurus programme does.
Some examples:
- when you enter "bicycle" and then "bicycle" BT "means of transport" and "means of transport" does not yet exist, the system will add this terms as well, after confirmation by the user.
- if the thesaurus has the following link: "automobile" USE "car" and you enter "Ford" BT "automobile", the system will automatically change this into "Ford" BT "car".
-In this case it will also automatically make "car" NT "Ford".

etc. etc.

Users have a special format that can be easily searched/browsed and terms are automatically inserted in the main database on hitting a single button.
Alternatively users can use a macro that checks all terms that are entered, accepts preferred terms, replaces non-preferred terms, and tags unknown terms.

Scope notes and images are included as well.

The maintenance macro is fully documented for, you may have guessed, easy maintenance.

For those who are REALLY interested I'm willing to write a short manual and of course you can have the format and macros.
The system is not perfect and it needs some further development, but I hope that if anyone uses this system he or she will share the improvements with us.

Charles

Quick Reply

Please log in or register before trying to post a reply.

 
© 2010 Cardbox Software Limited   Home