Dynamic rich media component for ASP.Net Flash, Video, Audio, FlashVideo and ToolTip / Balloon Help controls for C# and VB.Net
Welcome Guest Search | Active Topics | Members | Log In | Register

BC30201: Expression expected. Options · View
Guest
Posted: Sunday, November 18, 2007 6:18:00 PM
Rank: Guest
Groups: Guest

Joined: 7/20/2007
Posts: 53,654
Points: 100,812
I am trying to use a playlist based on a simple datasource and this is what a get. Am i missing somthing?

Thank you


Compiler Error Message: BC30201: Expression expected.

Source Error:



Line 73: <asp:TemplateField ShowHeader="False">
Line 74: <itemtemplate>
Line 75: <asp:LinkButton ID="TrackSelectButton" runat="server" CausesValidation="False" CommandName="Select" Text='<%# Eval("URL") /*Eval("TrackNumber")+". "+Eval("Name")*/ %>'></asp:LinkButton>
Line 76: </itemtemplate>
Line 77: </asp:TemplateField>

Dave
Posted: Monday, November 19, 2007 6:21:09 AM
Rank: Administration
Groups: Administration

Joined: 7/20/2007
Posts: 305
Points: -2,485
Location: Primarily in New York, USA
Hello,

From what you've sent me, I'm guessing that your problem is that there isn't a field named "URL" in your DataSource, and the code as it is expects it.

I suggest that you modify the code found here:

Code:
<%# Eval("URL") /*Eval("TrackNumber")+". "+Eval("Name")*/ %>'></


This was never intended to be more than an example (some of it is even commented) - you should modify this to reflect the database/datasource field names that you use.

IE: if you named your url "path" or something like that, change Eval("URL") to Eval("path") and so on. This should be modified so that it looks like you want it to!

Cheers

-Dave
Users browsing this topic
Guest


Forum Jump
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.