Welcome Guest Search | Active Topics | Sign In | Register

navigateURL as a tab Options
Brandyl Coffey
Posted: Thursday, September 23, 2010 12:53:38 PM
Rank: Newbie
Groups: Member

Joined: 8/11/2010
Posts: 5
I am trying to implement a tabstrip where one tab is a link to a form that requires a querystring value. THe issue that I am running into is trying to pass the property value into the URL as a querystring value. I am unable to do the following:

</eo:TabItem>
<eo:TabItem PageViewID="AllSections" Text-Html="All Sections" NavigateUrl="~/SIMS/ManageShipReport.aspx?TransitID=<%# DataBinder.Eval(Container, "DataItem.TransitID")%>">
</eo:TabItem>

It throws a parser error:
Parser Error Message: Literal content ('<eo:TabItem PageViewID="AllSections" Text-Html="All Sections" NavigateUrl="~/SIMS/ManageShipReport.aspx?TransitID=') is not allowed within a 'EO.Web.TabItemCollection'.

Any help is greatly appreciated.


eo_support
Posted: Thursday, September 23, 2010 1:38:08 PM
Rank: Administration
Groups: Administration

Joined: 5/27/2007
Posts: 24,194
Hi,

You won't be able to have binding expression inside NavigateUrl. The easiest way for you is to handle the menu's ItemDataBound event and then set the item's NavigateUrl with code inside that handler.

Thanks!
Brandyl Coffey
Posted: Thursday, September 23, 2010 3:55:26 PM
Rank: Newbie
Groups: Member

Joined: 8/11/2010
Posts: 5
Thanks for your prompt reply.

Sorry, but can you post a code sample in VB that I can reference.
eo_support
Posted: Thursday, September 23, 2010 8:44:26 PM
Rank: Administration
Groups: Administration

Joined: 5/27/2007
Posts: 24,194
Hi,

You would do something like this in your event handler:

Dim dataItem as xxxxx = CType(TabStrip1.DataItem, xxxx)
e.TabItem.NavigateUrl = "~/SIMS/ManageShipReport.aspx?" + dataItem.Items("TransitID")

We do not know your data source type, so we do not know what "xxxx" should be. See here for the relationship between the data item type and data source type:

http://doc.essentialobjects.com/library/1/eo.web.navigationitem.dataitem.aspx

You will also need to replace dataItem.Items("TransitID") with the appropriated syntax to match your data source type.

Thanks!


You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.