Skip to main content
February 13, 2025
Solved

Parameter Value Not Resolved

  • February 13, 2025
  • 3 replies
  • 0 views

I have an issue that I have seen before I never figured out so want to see if others have encountered this and figure out what I am doing wrong.  I have a data adapter that calls a Dashboard Dataset BR to get populated.  I pass in a parameter like "Parameter1=|!SomeOtherParam!|".  When I use "args.NameValuePairs.XFGetValue" to get the Parameter1 value is returns "|!SomeOtherParam!|".  I expect to see the actual value of SomeOtherParam or nothing but not the literal param with pipe and exclamation mark.  Has anything encountered something like this before?

Best answer by ChristianW

It is related to the processing order of the components, data adapters, and parameters. In your case, the parameter „someotherparameter“ is needed to build the data adapter, but it doesn’t exist yet. And the query fails.

The solution is easy, you just need to test, if the parameter already exists, and exit the business rule if not.

I‘m not at my desk, so I can‘t post a sample. 

3 replies

February 13, 2025

Sweez, I got some of these rules working.

In my case, it's a data adapter configured as Method -> BusinessRule



As you can see, I'm using |!GroupName!| parameter. In my Helper Queries I have the XFGetValue



Can you send us the same screenshot from your solution? Are you by chance enclosing your parameter with double quotes? That can make OS think those are text instead of trying to resolve them.

February 14, 2025

It is related to the processing order of the components, data adapters, and parameters. In your case, the parameter „someotherparameter“ is needed to build the data adapter, but it doesn’t exist yet. And the query fails.

The solution is easy, you just need to test, if the parameter already exists, and exit the business rule if not.

I‘m not at my desk, so I can‘t post a sample. 

February 14, 2025

I agree with Christian, sometimes a data adapter (or other object) is triggered multiple times, if your parameter is not resolved yet it will be returned in its original name (|!name!|). to test this run a brapi that writes your parameter to the errorlog and you should see it more then once, first as the |! !| and then the updated one with the required content. As a solution you could exit your function if your parameter contains |!.
so just add

If sParameter.XFContainsIgnoreCase("|!") then return nothing

 

SweezAuthor
February 14, 2025

Thank you.  This makes sense and give me some things to test.   Appreciate the reponses all.