On 28 Apr 2004, at 18:00, [EMAIL PROTECTED] wrote:

Message: 6
Date: Wed, 28 Apr 2004 07:53:32 -0700
From: Rob Cozens <[EMAIL PROTECTED]>
Subject: RE: Remote Find Questions Revisited
To: How to use Revolution <[EMAIL PROTECTED]>
Message-ID: <[EMAIL PROTECTED]>
Content-Type: text/plain; charset="us-ascii" ; format="flowed"

I think it's not necessarily a function of the number of cards,
but the fact that you have "mark any card"

snip


Final note:  My original query asked whether there was an efficient
means of searching a database stack remotely (ie: without actually
going to the stack).  Since, AFAIK, one can only deal with the mark
property of a card in the current stack ("get the mark of card x of
stack y" produces compiler errors here), the answer to my original
question seems to be "No."

Sorry, but this is not true. It is perfectly possible to do it without "going" to the
specific stack or without making it the defaultstack or current stack.
You can test this by putting each of the following handlers in a button in
the proximity of your "Test Results" field.


button 1:

on mouseUp
  put empty into field "Test Results"
  answer file "Select the stack:"
  if the result is "cancel" then exit mouseUp
  put it into x
  put "" into tList
  put the number of cards in stack x into tCount
  repeat 10
    put random(tCount) into a
    if a is not in tList then
      put "card" && a  \
          && "/ id " & the id of card a \
          of stack x & cr after tList
      mark card a of stack x
    end if
  end repeat
  put x & cr & "num of marked cards:" && \
      the number of marked cards of stack x \
      & cr & tList into fld "Test Results"
end mouseUp


button 2:


on mouseUp
  if field "Test Results" is "" then
    answer "Use button 1 first please :^)"
    exit to top
  end if
  put line 1 of field "Test Results" into x
  put "" into tList
  put the cardids of stack x into a
  repeat for each line i in a
    if the mark of card id i of stack x then
      put "card id" && i & cr after tList
      unmark card id i of stack x
    end if
  end repeat
  if tList = "" then put "no marked cards" into tList
  put  cr & tList  after  field "Test Results"
end mouseUp

Something you cannot do is use the command "unmark all cards"
as this indeed requires the defaultstack set to the "searched" stack.


--

Rob Cozens
CCW, Serendipity Software Company
http://www.oenolog.net/who.htm



Greetings, WA

_______________________________________________
use-revolution mailing list
[EMAIL PROTECTED]
http://lists.runrev.com/mailman/listinfo/use-revolution

Reply via email to