function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
dgggdggg 

summor'09 Visuagorce pages not working on na6 - null value return for button name parameter

We have several pages with list contrller and we are setting the action based on the button name.

 

This was working fine today morning , but suddenly the the value for following parameter is coming as null

 

System.CurrentPageReference().getParameters().get('mynamespace__return');

 

where return is the button name.

 

This is causing the page to go either go in endless loop or gives url not exists error..

 

This error does not happen on na2 thats where our DE org is.

 

In na2 following URL is generated :

 

https://gii.na2.visual.force.com/apex/SalesOrderLineList?retURL=%2Fa0S40000000jRs1&wrapMassAction=1&scontrolCaching=1&id=a0S40000000jRs1

 

But in na6 the url looks different and it has lid and eid in the parameters.


https://gii.na6.visual.force.com/apex/SalesOrderLineList?id=a0b80000000TxSs&lid=00b80000001B2gk&eid=a0b80000000TxSs&ic=1&retURL=%2Fa0b80000000TxSs&wrapMassAction=1&scontrolCaching=1&autoMapValues=1
 

We were able to get the button label by using

System.CurrentPageReference().getParameters().get('mynamespace__return') , but it does not work in na6 anymore.

 

this is a managed release package

 

Please suggest if we need to make any changes to fix it.

 

thanks

 

 

Message Edited by dggg on 06-10-2009 11:40 PM
wesnoltewesnolte

Hey

 

There might be a few things wrong. I had an instance where my namespace prefix was not appended correctly to all page references in my VisualForce pages. There is still no fix for this.

 

How are you sending the parameter? Can you paste that bit of code please?

 

Cheers,

Wes 

dgggdggg
the value for following parameter is coming as null. These are button names.

String calledFromConsume = System.CurrentPageReference().getParameters().get('gii__consume');
String calledFromReturn = System.CurrentPageReference().getParameters().get('gii__return');
String calledFromClearBackOrder = System.CurrentPageReference().getParameters().get('gii__reserveinventory');
String calledFromMaintainInvoiceSchedule = System.CurrentPageReference().getParameters().get('gii__maintaininvoicescheduleslistbutton');
Message Edited by dggg on 06-11-2009 03:03 PM
wesnoltewesnolte

Yeah, but how are you sending the parameters?

 

If you're using <apex:param> on a commandButton there's a bug that stops the values being passed correctly. Change the commandButton to commandLink and it'll work.

 

Cheers,

Wes

aballardaballard

We've identified an issue where custom list buttons that post to visualforce page do not include the form field for the submitting button in the page parameters. 

 

A fix is being worked on.

mtbclimbermtbclimber

The passing of the parameter you are depending on is not part of any API that salesforce.com documents, versions or otherwise supports. 

 

Good rule of thumb when building applications / writing code on the platform:  if you have to view the generated source html to accomplish your goal and you don't find any reference to the behavior you are observing in salesforce.com authored documentation it's probably not supported.  

 

If there is something you need that isn't documented as part of any supported API then log an idea on the idea exchange (ideas tab above) or make a direct ask through your account representative.

 

There is an underlying issue in the changes we made that you noted here which we are working to address. The resolution to that issue may or may not restore the previous behavior on which you depended.  You should be working on a solution yourself that addresses your requirement using an alternate approach that is not dependent on observed and undocumented behavior.

 

Message Edited by mtbclimber on 06-12-2009 10:07 AM
dgggdggg

thanks aballard,

 

do you know when this fix will be ready.