Hi,
Thank you so much Bruce for your help.
I have been able to make your second example work very well, and as you say
for a larger number of days. 

I have two remaining problems. 
When I tried the first example I found that TodayFormatted and the other
date variables were not being evaluated in the dialog box, so they appeared,
not as a date as in your second example but as TodayFormatted ie as their
variable names. 

In the second example I wanted to have more than one drop down list in my
combo box. 
But even with a lot of trial and error I still keep getting messages about
expecting operators. 
I suspect it is because I am misplacing "" marks or misunderstanding = == ,
+ and ++. 

I thought I understood the dialog box syntax from the help file. 
But whereas in the helpfile it would go 
Inputdialog ("~StartDAy = Choose a day??, Somethingelse =
somethingelsecheck??, "title")

In your very helpful hint it goes
inputdialog("~,=^StartDay=Choose a 
day??"++s, "DialogTitle")

The position of the double quotes is different. 
It seems to me perhaps wrongly that the use of double quotes in dialog
boxes, (where they separate the prompts from the title) and in scripts
generally (where they enclose strings) is different.

I am using the standard configuration. 

I *have* had a good go at trying to understand this in the PPST. 
I hope you will not mind helping me.

Alistair

PS I don't think there is anything at all wrong with the dialog boxes. Just
with their user!



-----Original Message-----
From: [email protected] [mailto:[EMAIL PROTECTED] On Behalf
Of brucexs
Sent: 24 February 2006 01:58
To: [email protected]
Subject: [power-pro] Re: Variables as items to select in a combo box

--- In [email protected], "alistair.murphy321357" 
<[EMAIL PROTECTED]> wrote:
>
> Hi,
> I want to have a combo box that offers a drop down list of the next 
> seven days.
> I can calculate what they are and format them as I like using the 
> date plug in.
> But when I run my script I get just the literal names of the 
> variables displayed, not their values. 
> So, Inputdialog ("~StartDay = Choose a day?? 
> TodayFormatted|TodayplusOneFormatted|...|TodayplusSixFormatted", "Wha

Try Inputdialog ("~,=^StartDay = Choose a day??" ++ "TodayFormatted" 
++ "|" ... ++ TodayplusSixFormatted. "title"))
Note that you need the ,=^ to avoid commas in the date strings 
confusing PowerPro.  

Here is a another way to do it that works for any number of days.
local d = date
local StartDay
for (local i=0; i<7; i=i+1)
    local s = s ++ formatdate("longdate", date.addDays(d, i)) ++ "|"
endfor

local return = inputdialog("~,=^StartDay=Choose a 
day??"++s, "DialogTitle")



There is no limit on the number of entries in the combo box.  The 
limit of six refers to the number of different combox boxes (or check 
boxes or edit inputs).  Nonetheless, I admit that PowerPro dialogs are 
not that great.










Attention: PowerPro's Web site has moved: http://www.ppro.org 
Yahoo! Groups Links



 





Attention: PowerPro's Web site has moved: http://www.ppro.org 
Yahoo! Groups Links

<*> To visit your group on the web, go to:
    http://groups.yahoo.com/group/power-pro/

<*> To unsubscribe from this group, send an email to:
    [EMAIL PROTECTED]

<*> Your use of Yahoo! Groups is subject to:
    http://docs.yahoo.com/info/terms/
 


Reply via email to