Compilation Error

Last post 05-01-2008 6:20 AM by CreativeMind. 3 replies.

Sort Posts:

  • Compilation Error

    04-30-2008, 1:42 PM

    hi all,

    can u plz identify why error occurs: 

     <asp:repeater id="repDocuments" runat="server">
    <HeaderTemplate>    
        <TABLE id="Table61" height="150" width="100%" cellpadding="0" cellspacing="0">
        <TR>                                    
        <TD class="GridSeperator"></TD>
        <TD class="GridHeader" height="20px" width="25%" align="center">Document Name</TD>
        <TD class="GridSeperator"></TD>
        <TD class="GridHeader" align="center" width="20%">Description</TD>
        <TD class="GridSeperator"></TD>
        </TR>
        </HeaderTemplate>
        
        <ItemTemplate>
        <TR>
        <td class="GridSeperator">    </td>
        <TD align="left" valign="top" class="GridCell" height="25px">    <%#DataBinder.Eval(Container, "DataItem.DocumentTitle")%>    </TD>
        <TD class="GridSeperator"></TD>
        <TD align="left" valign="top" class="GridCell"><%# DataBinder.Eval(Container, "DataItem.Description")%></TD>
        
        <TD class="GridSeperator"></TD>
        </TR>
        </ItemTemplate>
        
        <FooterTemplate>
        <TR>
        <td class="GridSeperator">    </td>
        <TD class="GridCell"></TD>
        <TD class="GridSeperator"></TD>
        <TD class="GridCell"></TD>
        <TD class="GridSeperator"></TD>
        </TR>
        <TR>
        <TD class="GridSeperator" colspan="11" height="3"></TD>
        </TR>
        </TABLE>
        FooterTemplate> </asp:repeater>

    the bold line is showing compilationError: cs1040 Preprocessor directives must appear as
    the first non-whitespace character on a line

    thx 

    Filed under:
  • Re: Compilation Error

    04-30-2008, 2:02 PM
    • Loading...
    • ClayCo
    • Joined on 06-14-2002, 10:11 AM
    • United States
    • Posts 267
    • AspNetTeam

    Hi Creative,

    I'm sorry to say this, but I'm not able to reproduce this error.  You might want to click on "Show Complete Compilation Source" in the error page you receive, since that will show how the databinding code you're using is used in context, and ought to help track down the source of the error.

    HTH,
    Clay

    P.S.  How is this related to Silverlight?

  • Re: Compilation Error

    04-30-2008, 2:06 PM

     Try: (whitespace removed in case there were special non-printing chars or something odd in there, and new 2.0 syntax with Eval)

    <TD align="left" valign="top" class="GridCell" height="25px"><%#Eval("DocumentTitle")%></TD>

    Please Mark As Answer posts that helped you.

    "If we learn from our mistakes, I should be brilliant by now."

  • Re: Compilation Error

    05-01-2008, 6:20 AM
    Answer

     thx.. the problem is resolved now. some '>' was missing. on looking compilation source, i found error. this is not really related to silver light. unintentionally was sent to this forum.

    thx again. 

Page 1 of 1 (4 items)
Microsoft Communities
Page view counter