Xpages Repeat Controls Tabular display - nested

I have a situation wherein I need to display all documents in view. Issue is I need to display multivalued fields (can be achieved by modifying view column to display new line). Now issue comes when a column value is also multivalued. E.g. first column is created by looping through 50 fields (single value) and second column is created by looping through corresponding 50 fields but these fields are multivalued.
I am looking for ideas about how to nest repeats in this case. Issue is in first repeat I get the handle of documents but in nested one i am not able to get this handle to be able to loop through fields. And it is not simply one column or value I want to display, there are 4-5 such columns.
Any ideas are welcome.
Thanks in advance.

You want to start looking at a repeat control, not a view control. Have the outermost control loop through the entries in the view and populate the data source of a containing panel with a Notes document. Then inside the panel you only refer to the inner document data source.

Related

#SetViewInfo with Sorted Columns

Can someone advise whether #SetViewInfo can be used with click to sort columnns.
When a view is filtered using #SetViewInfo it removes the column sorting options, thus removing the functionality of the view. Even when resetting to all records the column sorting option is not available, however I have overcome this by opening a second view then opening the original view, messy but it works. I am using View Action Buttons. (Not sure how to store the value in a Check Box Action).
Filtering
#SetViewInfo([SetViewFilter]; "userinitials"; "$80"; 1)
Resetting.
#SetViewInfo([SetViewFilter];"";"$80";1);
#SetTargetFrame("frame");
#Command([OpenView]; "DummyView"); //Needed to get the click to sort back
#Command([OpenView]; "OriginalView")
Also if the view is already sorted on another column, ie not in a categorised state no records are found. I don't want to have to remove the sorting options on my views. The help implies you don't need to have the view categorised. But I cannot get it to work if I don't, ie if I use 0 on an uncategorised view nothing happens.
From Help
isCategory - Number. Boolean value. Required in a Standard Outline view; not for use in Calendar views. 1 indicates that the column in the columnName value is a category. 0 indicates that it is not.
Is the #SetViewInfo limited as I have found or am I missing something?
Any help appreciated.
Yes, #SetViewInfo has limitations. As far as I know, you cannot keep the sorting when you use SetViewFilter. I also believe you need to have the view categorized, at least in older versions of Notes this was the case, if I remember correctly.
Limitations like this is why I personally don't use #SetViewInfo very often (if at all), I try to use other ways to display filtered documents.
One way I have handled it in the past is to use a special form with a rich text field, and then I build a list of filtered documents (e.g. through a search) and render the list of documents in the rich text item.
I use this technique to do that: http://blog.texasswede.com/dynamic-tables-in-classic-notes/

Multi Select List Box Document Property with Search bar enabled

I am working on Multi Select List Box document property with search field.
It works fine when I give any keyword like 'An' it gives me Andorra, Angola, Anguilla etc. I can multi-select all these 3 records and make my underlying data table filtered.
Now the challenge is, if I search for the records that starts with Z in the search bar and click Enter then the above selection is deselected/disappeared (meaning the last search elements alone will be available).
Any ideas on how to make the current selection and newly searched elements available ?
Any inputs and suggestions would be much helpful.
Attached the sample dxp file and screenshots.
I think the filtering you are doing is based on the document property attached to this multi select list box.
You can make another property and attach this value to that doc property, whenever somebody changes this value run an IronPython to append to that doc property.
Give a reset button to clear this value when required

XPages - Value Picker - Update Multiple fields

I would like to use a dominoViewValuePicker to update several fields with several values. I have seen that it is possible to add multiple values to the one field. Is it possible to select one document from a dominoViewValuePicker and then use multiple values from this document to update multiple fields on the XPage?
Certainly. Just set the onChange event to refresh those fields (preferably, they all go into a panel so that you can do a partial refresh rather than a full refresh) and compute the values (either from the script on the onChange or just by the formulas for determining those values in the first place).
If you do set up a panel for a partial refresh, make sure to give the panel an ID. By default panels are not given ID's and are not available to refresh.

Have text in row overflow into right column

I have a view with multiple columns that's showing documents with response documents underneath.
I have a field on the parent document that is long that i'm putting in the first column.
I've got another column that has a field specific to my response document.
I want to have the first column be very small (width), so the responses aren't indented by much.
The problem is that the parent document's field gets cut off.
How can i allow the parent property column to overrun into the child property column?
This would be similar to a categorised view, except that the 'category' is a parent document.
I'd like a solution where i can get a child's property to overrun into a sub-child's property too, i.e. Document->Response->Response of response
There are two ways to set up a parent/child relationship between the rows in a NotesView. First works with one or more types of documents where you take a flat view of documents, pick a column to group by, and set its type to Categorized. The Category row then shows up above the entries that have their field set to the category value.
The second way is to have two types of documents using the built in document / response (and optionally response to response) relationship. In your form selection criteria, you make sure you select all the documents you want, and then tack on the descendants. In the view settings you need to select "Show response documents in a hierarchy". Then the parent documents will show above all their child documents.
I think you're trying to use the second method, but it seems like something is missing. When it is set up, the parent row can show any number of columns, and usually the child row shows only one (see the design of the built-in discussion databases). To designate a column to be for responses, select the Show Responses Only option in the column properties. Otherwise the column will appear for just the parent document.
To get what you want to do you should just need a couple of columns. The first one would be for the response documents and can be very narrow, but will automatically stretch across the whole window. The second would be for the parent document. Lastly you can select the "Extend last column to window width" option so the parent column fills the screen, or just stretch the parent's column wide enough to fit everything. You can even set the view properties to allow that column to show on multiple lines (up to 9) if it doesn't fit on one.
Hopefully this fills in any gaps. If I missed something please let me know in the comments.

how to hide the grand total row in views using #formula or lotusscript

I want to hide the grand total row in views using #formula or lotusscript.
How should I do this?
There's no Formula or LotusScript for hiding the grand total in a view, but I found a work-around for the cases where the grand total does not make business sense at all and would only confuse the users.
Displaying the view as an embedded view in a form, using Show single category leaves out the grand total row. You may need to use this view only as embedded view and have otherwise useless fixed category for all documents (i.e. put "1" in the formula for the categorized column and use the same in Show single category). You'll also need the SaveOptions text field with default value "0" so the users don't get dialog asking whether they want to save the document (after all, for them this is a view) and the line Continue = False in the QuerySave event.
Then you need to find how to best integrate this with the other views - maybe use Auto frame in the form properties if your application uses framesets. The users may not be able to tell the difference.
Seems like a lot of work for removing one line from the view but I am not aware of another way to hide it and sometimes it's worth the added complexity.
Does that help?
You can also create a Filtered By Category view by using #SetViewInfo with first column with value "1" and filter by this values. All documents will be displayed only total sum will be hidden.

Resources