Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hello,
I have a sheet object with several buttons on it that will pull up different charts once clicked. Also on the sheet object is a list box with all available months listed. Due to the large amount of data that will be presented if a month is not selected 1st, I would like to be able to program the buttton to only open the chart if a month has been selected.
Can someone point me in the right direct on how to set this up and is there a reference document or website that could assist me in learning how to apply VB code to QV10 to do automation steps like this? I am new to VB and I find it difficult searching for "How to's."
Thank you,
Sean
Hello Sean,
I think you can achive the button to be clickable or not using the "enable Condition" on button props --> general tab. Expression for it would be similar to this:
GetSelectedCount(Month) = 1
HtH
Roland
Thanks for the reply. When I add this in, the Button is unavailable even
after I select a month. Thoughts?
Sean Smith | Business Analytics Developer| Brady Corporation | 414 438 6981
Office | 262 751 5193 Cell
On Wed, Dec 14, 2011 at 8:02 AM, Roland Kunle <
Hi Sean,
did you replace my "Month" with your field(-name) ? That's the only "hook" I can imagine right now. Else don't hesitate to post an exam app, may be with two or three months of data.
RR
LOL, can't believe I overlooked that as my Field is MonthName... Thanks,
I'll give it a go.
Sean Smith | Business Analytics Developer| Brady Corporation | 414 438 6981
Office | 262 751 5193 Cell
On Wed, Dec 14, 2011 at 9:53 AM, Roland Kunle <
I would use a condition as Roland suggests, but would use in preference:
not isnull(fieldname)
as GetSelectedCount doesnt take into account where 'fieldname' has been implicitily selected (ie a 'possible' rather than a 'selected').
Regards,
Gordon
Thanks Gordon. How do I use this and still allow for the user to select
more than 1 month?
Sean Smith | Business Analytics Developer| Brady Corporation | 414 438 6981
Office | 262 751 5193 Cell
On Wed, Dec 14, 2011 at 10:05 AM, gordon.savage <
Sean,
I'm not quite sure I understand what you are trying to do now - I thought you said it was to only display the chart when a month was selected?
If the user can select > 1 month then can he select all? Makes conditioning the chart display irrelevant if so!
If you want to make sure that the user has made some selection (either explicit or implicit) then you could use:
=getpossiblecount(month) < count({1} DISTINCT month)
but be aware the selections could be just one less than all months!
Regards,
Gordon
Excellent, thank you.
Sean Smith | Business Analytics Developer| Brady Corporation | 414 438 6981
Office | 262 751 5193 Cell
On Thu, Dec 15, 2011 at 4:17 AM, gordon.savage <