As of December 1, 2020, Focal Point is retired and repurposed as a reference repository. We value the wealth of knowledge that's been shared here over the years. You'll continue to have access to this treasure trove of knowledge, for search purposes only.
Join the TIBCO Community TIBCO Community is a collaborative space for users to share knowledge and support one another in making the best use of TIBCO products and services. There are several TIBCO WebFOCUS resources in the community.
From the Home page, select Predict: WebFOCUS to view articles, questions, and trending articles.
Select Products from the top navigation bar, scroll, and then select the TIBCO WebFOCUS product page to view product overview, articles, and discussions.
Request access to the private WebFOCUS User Group (login required) to network with fellow members.
Former myibi community members should have received an email on 8/3/22 to activate their user accounts to join the community. Check your Spam folder for the email. Please get in touch with us at community@tibco.com for further assistance. Reference the community FAQ to learn more about the community.
I believe this code will allow multi-line headings in a grid:
{ Form1.Grid1.QuickSetCellTypeEx(2, -1, 2); Form1.Grid1.QuickSetText(2, -1, "M\na\nr\nk\n"); -* replace this last value with field values. Form1.Grid1.SetColWidth(2, 20); Form1.Grid1.RedrawCell(2, -1); }
The -1 in the first row means the heading. The \n is the carriage return.
Mark
Posts: 663 | Location: New York | Registered: May 08, 2003
Thanks again for your help. where should i put this piece in a windows onload function. Do you think the windows onload function will be triggered everytime the grid refreshes.
Thanks for your response. A strange thing is happening.
Firstly , Form1.Grid1.GetNumberRows(); is not functioning. It is not getting rowcount. So i am updating the row count in an invisible editbox and getting it from there. The strange thing is the onload function works when i put an alert on the row-count , the row-count pops up and after i close the onload works .
But when i remove the alert and let the window load as usual without any alerts. The window onload does not do its duty.
This may be due to a timing issue. Basically when the JS performs, the grid may not be fully drawn on the screen. An easy way to test for this is to place the JS code behind a button. When the form displays, click the button and see if it works correctly.
This has been a sporadic issue with the Active X grid.
One thing to try is to call the JS function from mntonload.js. Locate that file in: ibi\devstudio\ibi_html\javaassist\ini\html\maint
And add the function call. When that file is loaded (automatically) it can kick off your js code.
Mark
Posts: 663 | Location: New York | Registered: May 08, 2003
Yes you are correct with the timing issue . Bang on Target. I resolved it using a js timedelay function setTimeout and delayed the function call by one second. The onload function now works fine.