Click here to monitor SSC
SQLServerCentral is supported by Red Gate Software Ltd.
 
Log in  ::  Register  ::  Not logged in
 
 
 
        
Home       Members    Calendar    Who's On


Add to briefcase ««12

Enable / Disable Hyperlink Action of TextBox Based on Value Expand / Collapse
Author
Message
Posted Tuesday, May 19, 2009 8:43 PM
SSC-Enthusiastic

SSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-Enthusiastic

Group: General Forum Members
Last Login: Wednesday, May 1, 2013 11:21 PM
Points: 138, Visits: 370
kabolick (1/20/2009)
When there is a value, I want the hyperlink action to be enabled, if there is not a value I want to disable the hyperlink action so that the user doesn't click to a report that has no data.


Using the following construct as an expression in Jump To Report works for me:
=IIF(Sum(Fields!CellValue.Value) Is Nothing,Nothing,"Detail Report")

This way the hyperlink cursor never shows on mouseover for a blank cell; it has the effect of disabling any Action.
Post #720272
Posted Wednesday, May 20, 2009 7:44 AM


Old Hand

Old HandOld HandOld HandOld HandOld HandOld HandOld HandOld Hand

Group: General Forum Members
Last Login: Tuesday, December 10, 2013 10:06 PM
Points: 374, Visits: 428
Nate Neufeld (5/19/2009)
kabolick (1/20/2009)
When there is a value, I want the hyperlink action to be enabled, if there is not a value I want to disable the hyperlink action so that the user doesn't click to a report that has no data.


Using the following construct as an expression in Jump To Report works for me:
=IIF(Sum(Fields!CellValue.Value) Is Nothing,Nothing,"Detail Report")

This way the hyperlink cursor never shows on mouseover for a blank cell; it has the effect of disabling any Action.


I was just about to whinge about that RS does not have this feature. NOTHING is what will save you...

Thanks for the tip. The trick with the hiding unhiding overlapping cells, as someoe suggested, brought me troubles in the end with export to PDF/EXCEL. It won't render the same as into HTML, which made me remove the feature. I almost said to the customers that it is not possible to remove 'empty click', before I saw your post. I will try it tomorrow and we will see if it works.

Thanks anyways.

VAL


M.Sc.IT, M.B.A, MCTS BI 2008, MCITP BI 2008, MCTS SQL Dev, CSM, CDVDM
Post #720551
Posted Wednesday, September 16, 2009 4:58 PM
SSC Rookie

SSC RookieSSC RookieSSC RookieSSC RookieSSC RookieSSC RookieSSC RookieSSC Rookie

Group: General Forum Members
Last Login: Wednesday, July 16, 2014 4:35 PM
Points: 32, Visits: 58
TKD-BB: Thanks, I had the same question and your two-textboxes method solved it nicely!

Edit: Then I noticed page two of this thread, saw the problem with Excel export and changed it to
=IIF(Fields!ResourceType.Value) <>"Mobile Resource",Nothing,"Mobile Resource Cost Summary")



Thanks all!
Post #789331
Posted Sunday, May 1, 2011 4:19 AM
Forum Newbie

Forum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum Newbie

Group: General Forum Members
Last Login: Monday, July 14, 2014 5:12 AM
Points: 1, Visits: 27
hi.

there is a simple solution for your problem, just use an IIF and a "false" value, just like the next example i used for my report for disabling the hyperlink.

=iif(Fields!UpTo24H_Count.Value<>0,"desired_report", false)

"desired_report" is the name of the report you want to go to using the hyperlink, you
can use this example for a lot of things, i used it to disable the tooltip i added to the hyperlink,
and the same for the underlined property i added to the text in the font properties.

good day.
gil eiliya
Post #1101282
Posted Monday, July 14, 2014 4:13 AM
Forum Newbie

Forum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum Newbie

Group: General Forum Members
Last Login: 2 days ago @ 7:48 AM
Points: 1, Visits: 2
I solved this by using the following expression
=IIF(Cint(Fields!Field1.Value) > 0,"ReportName/URL",nothing)
Post #1592117
« Prev Topic | Next Topic »

Add to briefcase ««12

Permissions Expand / Collapse