home *** CD-ROM | disk | FTP | other *** search
/ The Electronic Whole Earth Catalog / ElectronicWholeEarthCatalog.img / COMMUNITY / background_4934.txt < prev    next >
Text File  |  1989-02-09  |  23KB  |  1,023 lines

  1. -- background: 4934 from stack: in
  2. -- bmap block id: 3207
  3. -- flags: 0000
  4. -- background id: 0
  5. -- name: Access
  6. ----- HyperTalk script -----
  7. -- bg Access script  2/7/89
  8. on initAccUpdate
  9.   -- called by 'openStack' in stack script
  10.   -- open access update and update index files
  11.   loadAccUpdate "EWEC Update", "EWEC.update", "ewec.update.index"
  12. end initAccUpdate
  13.  
  14. on exitAccUpdate
  15.   -- called by 'closeStack' in stack script
  16.   closeAccUpdate
  17. end exitAccUpdate
  18.  
  19. on openCard
  20.   doAccUpdate
  21.   pass openCard
  22. end openCard
  23.  
  24. -- access update routines
  25.  
  26. -- all these routines require the accUpdate XFCN
  27. -- doAccUpdate requires pullTabbedChunk XFCN (or function)
  28.  
  29. on doAccUpdate
  30.   -- if an access update file has been opened, this function
  31.   -- checks for an update to this card and updates fields accordingly
  32.  
  33.   global tabbedData  -- used by pullTabbedChunk function
  34.   global updHandle
  35.  
  36.   if updHandle is not 0 then
  37.     if field surveyAccession is empty
  38.     then get lookupUpdate( field "accession" )
  39.   else get lookupUpdate( field "surveyAccession" )
  40.  
  41.   if it is not empty then
  42.     lock screen
  43.     put "x" into field beenUpdated
  44.     put it into tabbedData
  45.     put pullTabbedChunk() into field "theTitle"
  46.     put pullTabbedChunk() into field "theSubTitle"
  47.     put pullTabbedChunk() into field "vendorName"
  48.     put pullTabbedChunk() into field "vendorAddr1"
  49.     put pullTabbedChunk() into field "vendorPhone"
  50.     put tabbedData into field "theAccess"
  51.     unlock screen
  52.   end if
  53. end if
  54. end doAccUpdate
  55.  
  56. function lookupUpdate theAccession
  57. global updHandle
  58.  
  59. return accUpdate( 2, updHandle, theAccession )
  60. end lookupUpdate
  61.  
  62. on loadAccUpdate diskName, dataFileName, indexFileName
  63.   -- loads a prebuilt access index file, opens data file
  64.   -- looks in HyperCard directory as well as the named disk
  65.   global updHandle
  66.   global stacks -- list of stack folders from home stack
  67.  
  68.   -- look in HC directory first, it's probably a hard disk
  69.   put accUpdate( 4, indexFileName, dataFileName ) into updHandle
  70.   if updHandle = 0 then
  71.     -- not found, so look in named disk
  72.     put accUpdate( 4, diskName & ":" & indexFileName, diskName & ":" & dataFileName ) into updHandle
  73.  
  74.     -- disabled search of "stacks" folder list
  75.     -- reenable by removing "AND false" clause
  76.     if updHandle = 0 AND false then
  77.       -- still not found, look thru folder list from home stack
  78.       if stacks is empty then
  79.         getHomeInfo  -- Std. Home stack script that fills in global variables
  80.       end if
  81.       put 1 into lineNum
  82.       put the number of lines of stacks into lc
  83.       repeat while updHandle = 0 and lineNum <= lc
  84.         put lc - lineNum
  85.         put line lineNum of stacks into diskName
  86.         put accUpdate( 4, diskName & indexFileName, diskName & dataFileName ) into updHandle
  87.         put diskName & indexFileName
  88.         add 1 to lineNum
  89.       end repeat
  90.     end if
  91.   end if
  92. end loadAccUpdate
  93.  
  94. on closeAccUpdate
  95.   global updHandle
  96.  
  97.   get accUpdate( 3, updHandle )
  98.   put 0 into updHandle
  99. end closeAccUpdate
  100.  
  101.  
  102. -- ****  end of access update scripts  ****
  103.  
  104.  
  105. -- access update build scripts (not used in product )
  106. on updPrepare fName
  107.   -- builds access update index from text file
  108.   global updHandle
  109.   put accUpdate( 1, fName ) into updHandle
  110. end updPrepare
  111.  
  112.  
  113. on updWrite theAccession
  114.   -- writes access update index to a file that loadAccUpdate can read
  115.   global updHandle
  116.  
  117.   put "ewec.update.index" into fileName
  118.   -- open and close the file, just to be sure it exists
  119.   open file fileName
  120.   close file fileName
  121.  
  122.   return accUpdate( 5, updHandle, fileName )
  123. end updWrite
  124.  
  125. -- ****  end of access update build scripts  ****
  126.  
  127.  
  128.  
  129. -- part 4 (field)
  130. -- low flags: 01
  131. -- high flags: 0000
  132. -- rect: left=34 top=85 right=313 bottom=210
  133. -- title width / last selected line: 0
  134. -- icon id / first selected line: 0 / 0
  135. -- text alignment: 0
  136. -- font id: 3
  137. -- text size: 10
  138. -- style flags: 0
  139. -- line height: 13
  140. -- part name: theAccess
  141.  
  142.  
  143. -- part 5 (field)
  144. -- low flags: 01
  145. -- high flags: 0000
  146. -- rect: left=354 top=318 right=338 bottom=456
  147. -- title width / last selected line: 0
  148. -- icon id / first selected line: 0 / 0
  149. -- text alignment: 1
  150. -- font id: 3
  151. -- text size: 9
  152. -- style flags: 0
  153. -- line height: 15
  154. -- part name: thePage
  155.  
  156.  
  157. -- part 6 (field)
  158. -- low flags: 81
  159. -- high flags: 4002
  160. -- rect: left=255 top=0 right=18 bottom=396
  161. -- title width / last selected line: 0
  162. -- icon id / first selected line: 0 / 0
  163. -- text alignment: 0
  164. -- font id: 3
  165. -- text size: 12
  166. -- style flags: 0
  167. -- line height: 16
  168. -- part name: theIdent
  169.  
  170.  
  171. -- part 20 (field)
  172. -- low flags: 01
  173. -- high flags: 2000
  174. -- rect: left=28 top=40 right=64 bottom=463
  175. -- title width / last selected line: 0
  176. -- icon id / first selected line: 0 / 0
  177. -- text alignment: 0
  178. -- font id: 3
  179. -- text size: 14
  180. -- style flags: 768
  181. -- line height: 18
  182. -- part name: theTitle
  183.  
  184.  
  185. -- part 22 (field)
  186. -- low flags: 01
  187. -- high flags: 0002
  188. -- rect: left=345 top=22 right=41 bottom=463
  189. -- title width / last selected line: 0
  190. -- icon id / first selected line: 0 / 0
  191. -- text alignment: 1
  192. -- font id: 0
  193. -- text size: 12
  194. -- style flags: 0
  195. -- line height: 16
  196. -- part name: theHeading
  197. ----- HyperTalk script -----
  198. on mouseDown
  199.   popMenuArticle
  200. end mouseDown
  201.  
  202.  
  203.  
  204. -- part 25 (button)
  205. -- low flags: 00
  206. -- high flags: 0000
  207. -- rect: left=463 top=88 right=130 bottom=507
  208. -- title width / last selected line: 0
  209. -- icon id / first selected line: 0 / 0
  210. -- text alignment: 1
  211. -- font id: 0
  212. -- text size: 12
  213. -- style flags: 0
  214. -- line height: 16
  215. -- part name: Earth
  216. ----- HyperTalk script -----
  217. on mouseUp
  218.   goWholeEarth
  219. end mouseUp
  220.  
  221.  
  222.  
  223. -- part 26 (button)
  224. -- low flags: 00
  225. -- high flags: 0000
  226. -- rect: left=423 top=317 right=338 bottom=453
  227. -- title width / last selected line: 0
  228. -- icon id / first selected line: 1013 / 1013
  229. -- text alignment: 1
  230. -- font id: 0
  231. -- text size: 12
  232. -- style flags: 0
  233. -- line height: 16
  234. -- part name: Down
  235. ----- HyperTalk script -----
  236. on mouseUp
  237.   doArticleDownButton
  238. end mouseUp
  239.  
  240.  
  241.  
  242. -- part 27 (button)
  243. -- low flags: 00
  244. -- high flags: 0000
  245. -- rect: left=353 top=317 right=338 bottom=386
  246. -- title width / last selected line: 0
  247. -- icon id / first selected line: 1014 / 1014
  248. -- text alignment: 1
  249. -- font id: 0
  250. -- text size: 12
  251. -- style flags: 0
  252. -- line height: 16
  253. -- part name: Up
  254. ----- HyperTalk script -----
  255. on mouseUp
  256.   doArticleUpButton
  257. end mouseUp
  258.  
  259.  
  260.  
  261. -- part 29 (field)
  262. -- low flags: 81
  263. -- high flags: 0002
  264. -- rect: left=0 top=172 right=232 bottom=165
  265. -- title width / last selected line: 0
  266. -- icon id / first selected line: 0 / 0
  267. -- text alignment: 0
  268. -- font id: 3
  269. -- text size: 10
  270. -- style flags: 0
  271. -- line height: 13
  272. -- part name: Popup
  273.  
  274.  
  275. -- part 30 (field)
  276. -- low flags: 81
  277. -- high flags: 0002
  278. -- rect: left=0 top=0 right=18 bottom=86
  279. -- title width / last selected line: 0
  280. -- icon id / first selected line: 0 / 0
  281. -- text alignment: 0
  282. -- font id: 3
  283. -- text size: 12
  284. -- style flags: 0
  285. -- line height: 16
  286. -- part name: Accession
  287.  
  288.  
  289. -- part 32 (field)
  290. -- low flags: 01
  291. -- high flags: 2000
  292. -- rect: left=28 top=59 right=81 bottom=463
  293. -- title width / last selected line: 0
  294. -- icon id / first selected line: 0 / 0
  295. -- text alignment: 0
  296. -- font id: 3
  297. -- text size: 12
  298. -- style flags: 256
  299. -- line height: 16
  300. -- part name: theSubTitle
  301.  
  302.  
  303. -- part 34 (field)
  304. -- low flags: 81
  305. -- high flags: 0002
  306. -- rect: left=170 top=0 right=18 bottom=256
  307. -- title width / last selected line: 0
  308. -- icon id / first selected line: 0 / 0
  309. -- text alignment: 0
  310. -- font id: 3
  311. -- text size: 12
  312. -- style flags: 0
  313. -- line height: 16
  314. -- part name: SurveyAccession
  315.  
  316.  
  317. -- part 39 (button)
  318. -- low flags: 00
  319. -- high flags: 0000
  320. -- rect: left=463 top=232 right=275 bottom=488
  321. -- title width / last selected line: 0
  322. -- icon id / first selected line: 0 / 0
  323. -- text alignment: 1
  324. -- font id: 0
  325. -- text size: 12
  326. -- style flags: 0
  327. -- line height: 16
  328. -- part name: Left
  329. ----- HyperTalk script -----
  330. on mouseUp
  331.   doArticleLeftButton
  332. end mouseUp
  333.  
  334.  
  335.  
  336. -- part 40 (button)
  337. -- low flags: 00
  338. -- high flags: 0000
  339. -- rect: left=482 top=184 right=230 bottom=507
  340. -- title width / last selected line: 0
  341. -- icon id / first selected line: 0 / 0
  342. -- text alignment: 1
  343. -- font id: 0
  344. -- text size: 12
  345. -- style flags: 0
  346. -- line height: 16
  347. -- part name: Right
  348. ----- HyperTalk script -----
  349. on mouseUp
  350.   doArticleRightButton
  351. end mouseUp
  352.  
  353.  
  354.  
  355. -- part 43 (field)
  356. -- low flags: 81
  357. -- high flags: 0002
  358. -- rect: left=245 top=18 right=36 bottom=361
  359. -- title width / last selected line: 0
  360. -- icon id / first selected line: 0 / 0
  361. -- text alignment: 0
  362. -- font id: 3
  363. -- text size: 12
  364. -- style flags: 0
  365. -- line height: 16
  366. -- part name: ISBN
  367.  
  368.  
  369. -- part 44 (field)
  370. -- low flags: 83
  371. -- high flags: 0002
  372. -- rect: left=373 top=14 right=63 bottom=509
  373. -- title width / last selected line: 0
  374. -- icon id / first selected line: 0 / 0
  375. -- text alignment: 0
  376. -- font id: 3
  377. -- text size: 9
  378. -- style flags: 0
  379. -- line height: 11
  380. -- part name: keyWords
  381.  
  382.  
  383. -- part 46 (field)
  384. -- low flags: 81
  385. -- high flags: 0002
  386. -- rect: left=73 top=85 right=117 bottom=237
  387. -- title width / last selected line: 0
  388. -- icon id / first selected line: 0 / 0
  389. -- text alignment: 0
  390. -- font id: 3
  391. -- text size: 10
  392. -- style flags: 256
  393. -- line height: 13
  394. -- part name: RealSubtitle
  395.  
  396.  
  397. -- part 47 (field)
  398. -- low flags: 81
  399. -- high flags: 0002
  400. -- rect: left=307 top=61 right=87 bottom=497
  401. -- title width / last selected line: 0
  402. -- icon id / first selected line: 0 / 0
  403. -- text alignment: 0
  404. -- font id: 3
  405. -- text size: 9
  406. -- style flags: 0
  407. -- line height: 12
  408. -- part name: longTitle
  409.  
  410.  
  411. -- part 48 (field)
  412. -- low flags: 83
  413. -- high flags: 0002
  414. -- rect: left=307 top=86 right=113 bottom=504
  415. -- title width / last selected line: 0
  416. -- icon id / first selected line: 0 / 0
  417. -- text alignment: 0
  418. -- font id: 3
  419. -- text size: 9
  420. -- style flags: 0
  421. -- line height: 11
  422. -- part name: authorName
  423.  
  424.  
  425. -- part 49 (field)
  426. -- low flags: 83
  427. -- high flags: 0002
  428. -- rect: left=307 top=112 right=127 bottom=503
  429. -- title width / last selected line: 0
  430. -- icon id / first selected line: 0 / 0
  431. -- text alignment: 0
  432. -- font id: 3
  433. -- text size: 9
  434. -- style flags: 0
  435. -- line height: 11
  436. -- part name: authorIndexed
  437.  
  438.  
  439. -- part 50 (field)
  440. -- low flags: 83
  441. -- high flags: 0002
  442. -- rect: left=307 top=123 right=152 bottom=399
  443. -- title width / last selected line: 0
  444. -- icon id / first selected line: 0 / 0
  445. -- text alignment: 0
  446. -- font id: 3
  447. -- text size: 9
  448. -- style flags: 0
  449. -- line height: 11
  450. -- part name: pubYear
  451.  
  452.  
  453. -- part 52 (field)
  454. -- low flags: 83
  455. -- high flags: 0002
  456. -- rect: left=307 top=152 right=189 bottom=454
  457. -- title width / last selected line: 0
  458. -- icon id / first selected line: 0 / 0
  459. -- text alignment: 0
  460. -- font id: 3
  461. -- text size: 9
  462. -- style flags: 0
  463. -- line height: 11
  464. -- part name: price
  465.  
  466.  
  467. -- part 53 (button)
  468. -- low flags: 00
  469. -- high flags: 0000
  470. -- rect: left=463 top=139 right=173 bottom=508
  471. -- title width / last selected line: 0
  472. -- icon id / first selected line: 0 / 0
  473. -- text alignment: 1
  474. -- font id: 0
  475. -- text size: 12
  476. -- style flags: 0
  477. -- line height: 16
  478. -- part name: Map
  479. ----- HyperTalk script -----
  480. on mouseUp
  481.   doArticleMapButton
  482. end mouseUp
  483.  
  484.  
  485.  
  486. -- part 54 (field)
  487. -- low flags: 83
  488. -- high flags: 0002
  489. -- rect: left=307 top=185 right=219 bottom=510
  490. -- title width / last selected line: 0
  491. -- icon id / first selected line: 0 / 0
  492. -- text alignment: 0
  493. -- font id: 3
  494. -- text size: 9
  495. -- style flags: 0
  496. -- line height: 11
  497. -- part name: vendorName
  498.  
  499.  
  500. -- part 55 (field)
  501. -- low flags: 83
  502. -- high flags: 0002
  503. -- rect: left=309 top=204 right=250 bottom=512
  504. -- title width / last selected line: 0
  505. -- icon id / first selected line: 0 / 0
  506. -- text alignment: 0
  507. -- font id: 3
  508. -- text size: 9
  509. -- style flags: 0
  510. -- line height: 11
  511. -- part name: vendorAddr1
  512.  
  513.  
  514. -- part 56 (field)
  515. -- low flags: 83
  516. -- high flags: 0002
  517. -- rect: left=309 top=248 right=275 bottom=501
  518. -- title width / last selected line: 0
  519. -- icon id / first selected line: 0 / 0
  520. -- text alignment: 0
  521. -- font id: 3
  522. -- text size: 9
  523. -- style flags: 0
  524. -- line height: 11
  525. -- part name: vendorPhone
  526.  
  527.  
  528. -- part 57 (field)
  529. -- low flags: 83
  530. -- high flags: 0002
  531. -- rect: left=310 top=266 right=282 bottom=487
  532. -- title width / last selected line: 0
  533. -- icon id / first selected line: 0 / 0
  534. -- text alignment: 0
  535. -- font id: 3
  536. -- text size: 9
  537. -- style flags: 0
  538. -- line height: 11
  539. -- part name: originatorName
  540.  
  541.  
  542. -- part 58 (field)
  543. -- low flags: 83
  544. -- high flags: 0002
  545. -- rect: left=310 top=282 right=298 bottom=486
  546. -- title width / last selected line: 0
  547. -- icon id / first selected line: 0 / 0
  548. -- text alignment: 0
  549. -- font id: 3
  550. -- text size: 9
  551. -- style flags: 0
  552. -- line height: 11
  553. -- part name: reviewerName
  554.  
  555.  
  556. -- part 59 (field)
  557. -- low flags: 83
  558. -- high flags: 0002
  559. -- rect: left=310 top=298 right=314 bottom=346
  560. -- title width / last selected line: 0
  561. -- icon id / first selected line: 0 / 0
  562. -- text alignment: 0
  563. -- font id: 3
  564. -- text size: 9
  565. -- style flags: 0
  566. -- line height: 11
  567. -- part name: book
  568.  
  569.  
  570. -- part 60 (field)
  571. -- low flags: 83
  572. -- high flags: 0002
  573. -- rect: left=348 top=298 right=314 bottom=384
  574. -- title width / last selected line: 0
  575. -- icon id / first selected line: 0 / 0
  576. -- text alignment: 0
  577. -- font id: 3
  578. -- text size: 9
  579. -- style flags: 0
  580. -- line height: 11
  581. -- part name: bookPage
  582.  
  583.  
  584. -- part 61 (field)
  585. -- low flags: 83
  586. -- high flags: 0002
  587. -- rect: left=386 top=298 right=314 bottom=422
  588. -- title width / last selected line: 0
  589. -- icon id / first selected line: 0 / 0
  590. -- text alignment: 0
  591. -- font id: 3
  592. -- text size: 9
  593. -- style flags: 0
  594. -- line height: 11
  595. -- part name: articleType
  596.  
  597.  
  598. -- part 62 (field)
  599. -- low flags: 83
  600. -- high flags: 0002
  601. -- rect: left=425 top=298 right=313 bottom=511
  602. -- title width / last selected line: 0
  603. -- icon id / first selected line: 0 / 0
  604. -- text alignment: 0
  605. -- font id: 3
  606. -- text size: 9
  607. -- style flags: 0
  608. -- line height: 11
  609. -- part name: domain
  610.  
  611.  
  612. -- part 63 (field)
  613. -- low flags: 83
  614. -- high flags: 0002
  615. -- rect: left=33 top=271 right=308 bottom=289
  616. -- title width / last selected line: 0
  617. -- icon id / first selected line: 0 / 0
  618. -- text alignment: 0
  619. -- font id: 3
  620. -- text size: 9
  621. -- style flags: 0
  622. -- line height: 11
  623. -- part name: misc
  624.  
  625.  
  626. -- part 64 (field)
  627. -- low flags: 81
  628. -- high flags: 0002
  629. -- rect: left=230 top=312 right=342 bottom=303
  630. -- title width / last selected line: 0
  631. -- icon id / first selected line: 0 / 0
  632. -- text alignment: 0
  633. -- font id: 3
  634. -- text size: 12
  635. -- style flags: 0
  636. -- line height: 16
  637. -- part name: publicityphone
  638.  
  639.  
  640. -- part 71 (button)
  641. -- low flags: 80
  642. -- high flags: A003
  643. -- rect: left=4 top=313 right=328 bottom=79
  644. -- title width / last selected line: 0
  645. -- icon id / first selected line: 0 / 0
  646. -- text alignment: 1
  647. -- font id: 0
  648. -- text size: 12
  649. -- style flags: 0
  650. -- line height: 16
  651. -- part name: Show Pic
  652. ----- HyperTalk script -----
  653. on mouseUp
  654.   show Card picture
  655. end mouseUp
  656.  
  657.  
  658.  
  659. -- part 72 (button)
  660. -- low flags: 80
  661. -- high flags: A003
  662. -- rect: left=4 top=327 right=342 bottom=77
  663. -- title width / last selected line: 0
  664. -- icon id / first selected line: 0 / 0
  665. -- text alignment: 1
  666. -- font id: 0
  667. -- text size: 12
  668. -- style flags: 0
  669. -- line height: 16
  670. -- part name: Hide Pic
  671. ----- HyperTalk script -----
  672. on mouseUp
  673.   hide Card picture
  674. end mouseUp
  675.  
  676.  
  677.  
  678. -- part 75 (field)
  679. -- low flags: 83
  680. -- high flags: 0002
  681. -- rect: left=316 top=327 right=340 bottom=331
  682. -- title width / last selected line: 0
  683. -- icon id / first selected line: 0 / 0
  684. -- text alignment: 0
  685. -- font id: 4
  686. -- text size: 12
  687. -- style flags: 256
  688. -- line height: 13
  689. -- part name: WEA?
  690.  
  691.  
  692. -- part 76 (field)
  693. -- low flags: 83
  694. -- high flags: 0002
  695. -- rect: left=433 top=144 right=191 bottom=499
  696. -- title width / last selected line: 0
  697. -- icon id / first selected line: 0 / 0
  698. -- text alignment: 0
  699. -- font id: 3
  700. -- text size: 9
  701. -- style flags: 0
  702. -- line height: 11
  703. -- part name: ppd$
  704.  
  705.  
  706. -- part 87 (field)
  707. -- low flags: 83
  708. -- high flags: 0002
  709. -- rect: left=443 top=127 right=145 bottom=512
  710. -- title width / last selected line: 0
  711. -- icon id / first selected line: 0 / 0
  712. -- text alignment: 0
  713. -- font id: 3
  714. -- text size: 9
  715. -- style flags: 0
  716. -- line height: 11
  717. -- part name: pages
  718.  
  719.  
  720. -- part 88 (field)
  721. -- low flags: 81
  722. -- high flags: 0002
  723. -- rect: left=410 top=128 right=143 bottom=512
  724. -- title width / last selected line: 0
  725. -- icon id / first selected line: 0 / 0
  726. -- text alignment: 0
  727. -- font id: 4
  728. -- text size: 9
  729. -- style flags: 0
  730. -- line height: 12
  731. -- part name: MapDest
  732.  
  733.  
  734. -- part 89 (field)
  735. -- low flags: 81
  736. -- high flags: 0002
  737. -- rect: left=410 top=272 right=287 bottom=512
  738. -- title width / last selected line: 0
  739. -- icon id / first selected line: 0 / 0
  740. -- text alignment: 0
  741. -- font id: 4
  742. -- text size: 9
  743. -- style flags: 0
  744. -- line height: 12
  745. -- part name: LeftDest
  746.  
  747.  
  748. -- part 90 (field)
  749. -- low flags: 81
  750. -- high flags: 0002
  751. -- rect: left=410 top=225 right=240 bottom=512
  752. -- title width / last selected line: 0
  753. -- icon id / first selected line: 0 / 0
  754. -- text alignment: 0
  755. -- font id: 4
  756. -- text size: 9
  757. -- style flags: 0
  758. -- line height: 12
  759. -- part name: RightDest
  760.  
  761.  
  762. -- part 91 (field)
  763. -- low flags: 81
  764. -- high flags: 0002
  765. -- rect: left=354 top=285 right=300 bottom=456
  766. -- title width / last selected line: 0
  767. -- icon id / first selected line: 0 / 0
  768. -- text alignment: 0
  769. -- font id: 4
  770. -- text size: 9
  771. -- style flags: 0
  772. -- line height: 12
  773. -- part name: UpDest
  774.  
  775.  
  776. -- part 92 (field)
  777. -- low flags: 81
  778. -- high flags: 0002
  779. -- rect: left=354 top=301 right=316 bottom=456
  780. -- title width / last selected line: 0
  781. -- icon id / first selected line: 0 / 0
  782. -- text alignment: 0
  783. -- font id: 4
  784. -- text size: 9
  785. -- style flags: 0
  786. -- line height: 12
  787. -- part name: DownDest
  788.  
  789.  
  790. -- part 93 (field)
  791. -- low flags: 81
  792. -- high flags: 0002
  793. -- rect: left=163 top=172 right=232 bottom=277
  794. -- title width / last selected line: 0
  795. -- icon id / first selected line: 0 / 0
  796. -- text alignment: 0
  797. -- font id: 3
  798. -- text size: 10
  799. -- style flags: 0
  800. -- line height: 13
  801. -- part name: PopupDest
  802.  
  803.  
  804. -- part 97 (button)
  805. -- low flags: 80
  806. -- high flags: A003
  807. -- rect: left=79 top=312 right=327 bottom=223
  808. -- title width / last selected line: 0
  809. -- icon id / first selected line: 0 / 0
  810. -- text alignment: 1
  811. -- font id: 0
  812. -- text size: 12
  813. -- style flags: 0
  814. -- line height: 16
  815. -- part name: Show Fields
  816. ----- HyperTalk script -----
  817. on mouseUp
  818.   lock screen
  819.   show bg field "ISBN"
  820.   show bg field "keywords"
  821.   show bg field "longtitle"
  822.   show bg field "realsubtitle"
  823.   show bg field "authorname"
  824.   show bg field "authorindexed"
  825.   show bg field "pubyear"
  826.   show bg field "pages"
  827.   show bg field "price"
  828.   show bg field "ppd$"
  829.   show bg field "vendorname"
  830.   show bg field "vendoraddr1"
  831.   show bg field "vendorphone"
  832.   show bg field "originatorname"
  833.   show bg field "reviewername"
  834.   show bg field "book"
  835.   show bg field "bookpage"
  836.   show bg field "articletype"
  837.   show bg field "domain"
  838.   show bg field "WEA?"
  839.   show bg field "publicityphone"
  840.   show bg field "misc"
  841.   unlock screen
  842. end mouseUp
  843.  
  844.  
  845.  
  846. -- part 98 (button)
  847. -- low flags: 80
  848. -- high flags: A003
  849. -- rect: left=79 top=327 right=342 bottom=224
  850. -- title width / last selected line: 0
  851. -- icon id / first selected line: 0 / 0
  852. -- text alignment: 1
  853. -- font id: 0
  854. -- text size: 12
  855. -- style flags: 0
  856. -- line height: 16
  857. -- part name: Hide Fields
  858. ----- HyperTalk script -----
  859. on mouseUp
  860.   lock screen
  861.   hide bg field "ISBN"
  862.   hide bg field "keywords"
  863.   hide bg field "longtitle"
  864.   hide bg field "realsubtitle"
  865.   hide bg field "authorname"
  866.   hide bg field "authorindexed"
  867.   hide bg field "pubyear"
  868.   hide bg field "pages"
  869.   hide bg field "price"
  870.   hide bg field "ppd$"
  871.   hide bg field "vendorname"
  872.   hide bg field "vendoraddr1"
  873.   hide bg field "vendorphone"
  874.   hide bg field "originatorname"
  875.   hide bg field "reviewername"
  876.   hide bg field "book"
  877.   hide bg field "bookpage"
  878.   hide bg field "articletype"
  879.   hide bg field "domain"
  880.   hide bg field "WEA?"
  881.   hide bg field "publicityphone"
  882.   hide bg field "misc"
  883.   unlock screen
  884. end mouseUp
  885.  
  886.  
  887.  
  888. -- part 99 (button)
  889. -- low flags: 80
  890. -- high flags: 8003
  891. -- rect: left=0 top=291 right=313 bottom=100
  892. -- title width / last selected line: 0
  893. -- icon id / first selected line: 0 / 0
  894. -- text alignment: 1
  895. -- font id: 0
  896. -- text size: 12
  897. -- style flags: 0
  898. -- line height: 16
  899. -- part name: Pour Access
  900. ----- HyperTalk script -----
  901. on mouseUp
  902.   pourAccess
  903.   send mouseUp to bg btn "Hide Fields"
  904. end mouseUp
  905.  
  906. on pourAccess
  907.   put empty into accessInfo
  908.  
  909.   -- take care of the title
  910.   put fld "realSubTitle" into realSubTitle
  911.   put fld "longTitle" into longTitle
  912.  
  913.   if realSubTitle is not empty then
  914.     put stripCR(realSubTitle) & Return after accessInfo
  915.   else if fld "longTitle" is not empty then
  916.     put stripCR(longTitle) & Return after accessInfo
  917.   else
  918.     --put Return after accessInfo
  919.   end if
  920.  
  921.   -- now the author name
  922.   if fld "authorName" is not empty then
  923.     put stripCR(fld "authorName") & Return after accessInfo
  924.   end if
  925.  
  926.   -- publication year and number of pages
  927.   put fld "pubYear" into pubYear
  928.   put fld "pages" into pages
  929.   if pubYear is not empty AND pages is not empty then
  930.     put stripCR(pubYear) & ";" && stripCR(pages) & Return after accessInfo
  931.   else if fld "pubYear" is not empty AND fld "pages" is empty then
  932.     put stripCR(pubYear) & Return after accessInfo
  933.   else if fld "pubYear" is empty AND fld "pages" is not empty then
  934.     put stripCR(pages) & Return after accessInfo
  935.   end if
  936.  
  937.   -- ISBN
  938.   put fld "ISBN" into ISBN
  939.   if ISBN is not empty then
  940.     if fld "articleType" = "pr" then
  941.       put "ISSN" && stripCR(ISBN) & Return after accessInfo
  942.     else          -- if fld "articleType" = "br" then
  943.       put "ISBN" && stripCR(ISBN) & Return  after accessInfo
  944.     end if
  945.   end if
  946.  
  947.   -- Price
  948.   put fld "price" into price
  949.   put fld "ppd$" into ppd
  950.   if price is not empty AND ppd is not empty then
  951.     put stripCR(price) && stripCR(ppd) after accessInfo
  952.   else if price is not empty AND ppd is empty then
  953.     put price after accessInfo
  954.   else if price is empty AND ppd is not empty then
  955.     put ppd after accessInfo
  956.   end if
  957.   put Return after accessInfo
  958.  
  959.   -- vendor
  960.   if fld "vendorName" is not empty then
  961.     put "from:" & Return & Return & stripCR(fld "vendorName") & Return after accessInfo
  962.   end if
  963.  
  964.   if fld "vendorAddr1" is not empty then
  965.     put stripCR(fld "vendorAddr1") & Return after accessInfo
  966.   end if
  967.  
  968.   if fld "vendorPhone" is not empty then
  969.     put stripCR(fld "vendorPhone") & Return after accessInfo
  970.   end if
  971.  
  972.   -- Misc
  973.   if fld "misc" is not empty then
  974.     put Return & stripCR(fld "misc") & Return after accessInfo
  975.   end if
  976.  
  977.   put accessInfo into fld "theAccess"
  978. end pourAccess
  979.  
  980. function stripCR theInfo
  981. repeat forever
  982.   if last char of theInfo is " " OR last char of theInfo is Return then
  983.     delete last char of theInfo
  984.   else
  985.     exit repeat
  986.   end if
  987. end repeat
  988.  
  989. return theInfo
  990. end stripCR
  991.  
  992. function hasBgButton what
  993. repeat with i = 1 to number of bg buttons
  994.   if short name of bg button i = what then return true
  995. end repeat
  996. return false
  997. end hasBgButton
  998.  
  999. on slagBgButtons btnName
  1000.   repeat while hasBgButton(btnName) is true
  1001.     show bg btn btnName
  1002.     select bg btn btnName
  1003.     doMenu "Clear Button"
  1004.   end repeat
  1005. end slagBgButtons
  1006.  
  1007.  
  1008.  
  1009.  
  1010.  
  1011. -- part 100 (field)
  1012. -- low flags: 81
  1013. -- high flags: 0002
  1014. -- rect: left=0 top=324 right=342 bottom=16
  1015. -- title width / last selected line: 0
  1016. -- icon id / first selected line: 0 / 0
  1017. -- text alignment: 0
  1018. -- font id: 3
  1019. -- text size: 12
  1020. -- style flags: 0
  1021. -- line height: 16
  1022. -- part name: beenUpdated
  1023.