How to pass trim servername as parameter ?
-
Monday, January 07, 2013 4:24 PM
Hello, I wanted to see if there is a way to pass a trimmed parameter to the report being generated. Example
In the report the User inputs server name as: SERVER989\SQL2008
The only portion that needs to be passed from their input is the SERVER989
I have the VB but Im not sure where to put it.
Any help would be greatly appreciated.
=Left(Parameters!ServerName.Value, Len(Parameters!ServerName.Value) - InStr(Parameters!ServerName.Value, "\"))
- Edited by MSSQLRahzel Monday, January 07, 2013 4:25 PM
All Replies
-
Monday, January 07, 2013 4:43 PM
Hi,
Add Param2 as a hidden and use an expression to specify the default value below:
=Split(Parameters!ServerName.Value,"/")(0)
Then use Param2 value to pass to the report.
Hope this helps!
k r o o t z
- Edited by krootz Monday, January 07, 2013 4:47 PM
- Edited by krootz Monday, January 07, 2013 4:53 PM
- Edited by krootz Monday, January 07, 2013 4:53 PM
- Proposed As Answer by Charlie LiaoMicrosoft Contingent Staff, Moderator Tuesday, January 08, 2013 8:06 AM
- Marked As Answer by Charlie LiaoMicrosoft Contingent Staff, Moderator Tuesday, January 15, 2013 11:52 AM

