Location.search action no longer works the same(broken)


#1

I have an older app that set and reads the location.search feature. when compiled with the current version it does not work correctly. if you set location.search to a value like [location.search = “?val=1”] then try to do a changeform command the browser fails to open the form specified. looking at the url that is created it is missed formed.

Now if you try open an app with a parameter and the app needs to ‘update the cache’ then when the updated app restarts the parameter is lost. It also seems that after you access location.search once, its value is set to " ".


#2

Are you usinglocation.search to change forms, or changeForm()?

ChangeForm is certainly easier to work with.


#3

George

the app looks to see if location.search has a value, and based on that value it decides which form to open. the opened form then use the value of locations.search to determine what to display. if location.search is blank then the app set to a default and follow the same logic.


#4

Try turning off EnableBrowserArrows in Project Properties.


#5

George

turning off EnableBrowserArrows changed it back to that working as I expected. The app reloads twice which is what I expected, once to do the update and then again with the updated program.

but… I did notice with EnableBrowserArrows turn on that it causes the app to reload 3 times instead of 2. 1 for doing the update and then twice again once with the a the passed parameter and then again without the parameter. This causes the startup routines to run twice causing other issues. Should I be running turning off EnableBrowserArrows as a default? Or will this be changed?


#6

It’s up to you. EnableBrowserArrows lets you use the browser back and forward arrows. That’s the same mechanism that location uses, which is why your messing with location caused odd things to happen.