Warren Hinchliffe Posted September 13, 2021 Share Posted September 13, 2021 I quick update on GETCOOKI and PUTCOOKI GETCOOKI will only work if you set a cookie value in the reporting server node. PUTCOOKI only replaces the reporting server copy of the cookie. Below is the steps provided as an example. Login to the Administration console. Select, reporting server, remote services, select a node, click modify Under security object, cookie, enter the name of the cookie you want to read. It needs to be an existing cookie, like IBIWF_language. Add IBIWF_language, click save, then clear cache. The above steps, takes an existing client cookie, and makes it available to the reporting server Make a focexec that can read the cookie, and modify the cookie. -TYPE STEP1 get cookie. -SET &GOT_COOKIE = GETCOOKI( IBIWF_language, A180); -SET &GOT_COOKIE = TRUNCATE( &GOT_COOKIE); -TYPE GOT_COOKIE = &GOT_COOKIE -TYPE GOT_COOKIE.LEN = &GOT_COOKIE.LENGTH -TYPE STEP2 put cookie -SET &NEW_COOKIE_SET = PUTCOOKI(IBIWF_language,fr); -* now read the cookie that you just updated. -SET &GOT_COOKIE = GETCOOKI( IBIWF_language, A180); -SET &GOT_COOKIE = TRUNCATE( &GOT_COOKIE); -TYPE GOT_COOKIE = &GOT_COOKIE -TYPE GOT_COOKIE.LEN = &GOT_COOKIE.LENGTH Link to comment Share on other sites More sharing options...
Toby Mills Posted September 13, 2021 Share Posted September 13, 2021 Hey @warren.hinchliffe Let me see if I understand - I think what you were hoping for was a way to cause a cookie to come to life (like SETCOOKI if there were such a thing). But what you got is a way to Update a cookie (via PUTCOOKI) and a way to retrieve the value. Think its a good NFR to try to make a SETCOOKI I started looking through what I could find of decompiled code and couldnt find anything hidden that might do that. Am I understanding that right Link to comment Share on other sites More sharing options...
Warren Hinchliffe Posted September 13, 2021 Author Share Posted September 13, 2021 Hi Everyone, Has anyone used PUTCOOKI and GETCOOKI functions. I was hoping to set and get a cookie from the reporting server and these functions seems to do the job, but have not worked for me. Link to comment Share on other sites More sharing options...
Warren Hinchliffe Posted September 14, 2021 Author Share Posted September 14, 2021 Yes, to be able to set a cookie from the reporting server would be great. The only option is to return an HTML page with the appropriate js to set the cookie. Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now