CreateViewNavFromCategory

I have a view which is categorised in the following order

Column 1: Category1

Column 2: Category2

Column 3: Category3

When utilising the CreateViewNavFromCategory method I am only able to uniquely specify the first column (category1) in the view.

Set nav = vw.CreateViewNavFromCategory(“Category1”)

Set entry = nav.GetFirst

It is possible to specify a category which appears in the 2nd or 3rd or 4th columns of the view. However, a view entry will not be created.

For example

Set nav = vw.CreateViewNavFromCategory(“Category3”)

Set entry = nav.GetFirst

It is possible to specify a category as in a path for example

Set nav = vw.CreateViewNavFromCategory(“Category1\Category2\Category3”)

Set entry = nav.GetFirst

And a view entry will be created however the view entry is the same as if the view navigator was created only from Category1

Set nav = vw.CreateViewNavFromCategory(“Category1”)

Set entry = nav.GetFirst

Could you please advise how I might return the column values from a view entry from a category in the second or third column of a view using

Set nav = vw.CreateViewNavFromCategory(“Category1\Category2\Category3”)

Set entry = nav.GetFirst

Thank You.

Subject: Try this

a = view.CreateViewNavFromCategory(“Category 1”)b = a.CreateViewNavFromCategory(“Category 2”)

c = b.CreateViewNavFromCategory(“Category 3”)

Then use c and you should be set.

Subject: I couldn’t get your sample to work:

I couldn’t get your sample to work:

a = view.CreateViewNavFromCategory(“Category 1”)

b = a.CreateViewNavFromCategory(“Category 2”)

c = b.CreateViewNavFromCategory(“Category 3”)

‘a’ is a NotesViewNavigator object, which does not have a CreateViewNavFromCategory() method.

Am I missing something?

Subject: You should escape your \

There is createViewNavFromCategory in XPages, that states (in DDE help) that it accepts an input string in the form “Category1\Category2”, as \ needs to be escaped in strings.

But: it does only return the complete first category - so it seems to be brogen.