How to add a Dataset parameter into the Url in rdlc reporting - rdlc

Hi I am new to rdlc reporting and in my project I have to pass Latitude and Longitude into the URL which is defined for a textbox. So what I was using is https://www.google.com.my/maps/place//Fields!TRIPSTARTLATITUDE.Value,Fields!TRIPSTARTLONGITUDE.Value,15z?hl=en
but by using the above code it is not going to the exact position I also want to add a marker in that particular position. I think the reason is because it is not decoding the value of the parameter.So give me some suggestion on how to pass the dataset parameter into the URL

if you have the lat and long being passed into the report (either via parameters or your dataset) then you can use some code on the url to assemble it with the values.
Eg:
="https://www.google.com.my/maps/place//" & Fields!TRIPSTARTLATITUDE.Value & "," & Fields!TRIPSTARTLONGITUDE.Value & ",15z?hl=en"

Related

How do I make the Integer Data Type on the Parameter update the numbers automatically when workbook opens in Tableau?

I am having an issue automatically updating/refreshing the percentages on my donut chart. I created a parameter & plugged it into my calculated field but every time I close my dashboard & open it back up, I have to manually update the parameter so that the percentages update on the donut. I have tried going to the "Value when workbook opens" field in the paramter but the only field from my data source that comes up is the "Donut" value that I used to create my actual donut chart. The value of the donut field is 0 of course since this was just used to create my donut.
I also went to the "List" view in the paramter & the "When workbook opens" has the same option(donut).
Why is this?
How do I get the percentages to be dynamic?
Wow, I just did a quick table calculation & selected "Percent of Total" & it worked. This is an alternative to the parameter.

SSRS textbox hanging indent

I currently have a text box within a table that displays multiple stores based on user parameter input. The problem that I am experiencing that I would like to have a hanging indent that will force the store name to indent once it wraps to the next line (see screenshot).
Is this possible? I am aware that I could put the "Stores:" in it's own textbox, however this makes it difficult when it comes to lining up report items to prevent hidden/merged cells/columns during export to Excel.
The code that I am currently using in the text box is ="<b>" & Microsoft.VisualBasic.Interaction.iif(Parameters!StoreKey.Count > 1, "Stores: ", "Store: ") & "</b>" & Microsoft.VisualBasic.Strings.Join(Parameters!StoreKey.Label, ", ")
The Textbox property you're looking for is called HangingIndent. Try setting it to -10pt.
You could use a table, in the first column you put "Stores: ", in the second the string value, set the borders to none and finally play a little with the alignment (First column top-right alignment & Second column top-left alignment, its your choice) to make it look as if it was all in a single text box.

how can I disable rows in my gridview with datasource rowfilter?

How can I hide rows in my Gridview with a specific value? For example I want to hide all rows with column("dubletten_Vorschlaege") is empty
skmTabelle.SLXADRIUMDEVDataSet.Tables("SKM2").DefaultView.RowFilter = "Dubletten_Vorschlaege =Nothing"
said he cant find the column nothing?
skmTabelle.SLXADRIUMDEVDataSet.Tables("SKM2").DefaultView.RowFilter = "Dubletten_Vorschlaege ="""
said he cannot read the statement at """
I've never used rowfilter so I hope someone can explain.
Edit:
thx levi, it doesn't throw an exception now. But the gridview doesn't change. how do I do that? Do I need to use the fill query again?
on the formload event I have
Me.SKM2TableAdapter.Fillg(Me.SLXADRIUMDEVDataSet.SKM2, Module1.pkey)
which only selects the rows which are new.
for example I imported new 2000 rows it only shows them.
Do I need to use this statement again?
I would refer you to this site for a few tips on using rowfilter.
http://www.csharp-examples.net/dataview-rowfilter/
In your case, I think the proper way may be to write the string like this. I have followed a similar approach and this worked.
...DefaultView.RowFilter = "Dubletten_Vorschlaege ='" & "'"
you will notice that i add a single quote after the = and again add a single quote within double quotes after the &.
Also, I refer you to this StackOverflow link
How do I check for blank in DataView.RowFilter
The user simply added the line of code as this:
...DefaultView.RowFilter = "Dubletten_Vorschlaege = ''"
notice the two single qoutes before the ending double quote.

What to replace in Crystal Report Programmatically?

I have a line of code to set the Report.PrintDate in VB6.How can we replace this line for CrystalDecisions.CrystalReports.Engine.ReportDocument ? In VB6 we have it is the inbuilt property for CRAXDRT.Report.
So can any once help me regarding this ?
if you want to show the current Date/Time of the printed report, you can use the built in Special Fields within the report designer . From your comment I understand you want to set that programatically. Then you need to create a Parameter and set it from code.
You can watch this DEMO to get to know how to create parameters. This Answer would show you how to pass the parameter from code.

Injecting a value into text

I have some contract text that may change.
It is currently (non live system) stored in a database field (we determine which contract text to get by using other fields in table). I, however need to display a specific date (based on individual contract) within this text.
IE (but Jan 12, changes depending on the individual contract):
blah blah blah... on Jan 12, 2009... blah blah blah
but everything else in the contract text is the same.
I'm looking for a way to inject the date into this text. Similar to .NET's
Console.Write("Some text here {0} and some more here", "My text to inject");
Is there something like this? Or am I going to need to split the text into two fields and just concatenate?
I am always displaying this information using Crystal Reports so if I can inject the data in through Crystal then that's fine.
I am using Crystal Reports, SqlServer 2005, and VB.net.
You could use some "reserved string" (such as the "{0}") as part of the contract, and then perform a replace after reading from the database.
If there's no option for this reserved string (for instance, if the contract may contain any type of string characters in any sequence, which I find unlikely), then you'll probably need to split into 2 text fields
Have you tried putting a text marker like the {0} above that can be replaced in the crystal reports code?
You can create a formula field and concatenate your text there.
If the data is stored in the database, the formula text should look like this:
"Some static text " & totext({yourRecord.yourDateField}, "yyyy")
Or you can provide it as a parameter before you show the report:
Dim parameterValue As New CrystalDecisions.Shared.ParameterDiscreteValue
value.Value = yourDate
Dim parameter As New CrystalDecisions.Shared.ParameterField
parameter.ParameterFieldName = "MyParam"
parameter.CurrentValues.Add(value)
parameter.HasCurrentValue = True
Me.CrystalReportViewer1.ReportSource = rapport
Me.CrystalReportViewer1.ParameterFieldInfo.Clear()
Me.CrystalReportViewer1.ParameterFieldInfo.Add(parameter)
Then the formula text should look like this:
"some static text " & {?MyParam}
I'm assuming you have a data source connected to your report. You can drag the field from the Database Explorer drop where it should appear. This way whenever the report runs the correct text will always be shown.