Quake3World.com Forums
     General Discussion
        ASP.Net Programmers


Post new topicReply to topic
Login | Profile | | FAQ | Search | IRC




Previous topic | Next topic 
Topic Starter Topic: ASP.Net Programmers

Cobalt Adrenaline
Cobalt Adrenaline
Joined: 07 Jun 1983
Posts: 31077
PostPosted: 04-06-2006 09:40 AM           Profile   Send private message  E-mail  Edit post Reply with quote


Jesus please help me, this is driving me nuts.

Default.aspx
Code:
<%@ Register TagPrefix="Portal" TagName="Banner" Src="~/modules/Banner.ascx" %>

<script runat="server">
    public int access = 5;
</script>

<Portal:Banner id="banner" runat="server"  access="<%# access %>"/>



Banner.ascx
Code:
<script runat="server">
    public int access;
    void Page_Init(Object sender, EventArgs e)
</script>
<% Response.Write(access.ToString()); %>


Banner always prints 0 :(:(:(




Top
                 

Cobalt Adrenaline
Cobalt Adrenaline
Joined: 07 Jun 1983
Posts: 31077
PostPosted: 04-06-2006 09:42 AM           Profile   Send private message  E-mail  Edit post Reply with quote


oh, if I manually set "access='5'" it works fine, so the link across is running smooth, just access isn't going in properly.
sommat wrong with <%# %>




Top
                 

Timed Out
Timed Out
Joined: 02 Aug 2000
Posts: 38067
PostPosted: 04-06-2006 09:44 AM           Profile   Send private message  E-mail  Edit post Reply with quote


Jesus doesn't post here anymore. I hear he's on ina forums nowadays :3



_________________
"Maybe you have some bird ideas. Maybe that’s the best you can do."
― Terry A. Davis


Top
                 

Cobalt Adrenaline
Cobalt Adrenaline
Joined: 07 Jun 1983
Posts: 31077
PostPosted: 04-06-2006 09:45 AM           Profile   Send private message  E-mail  Edit post Reply with quote


help meh!

please :'(




Top
                 

Cobalt Adrenaline
Cobalt Adrenaline
Joined: 07 Jun 1983
Posts: 31077
PostPosted: 04-06-2006 11:06 AM           Profile   Send private message  E-mail  Edit post Reply with quote


almost fixed it all
Code:
    <asp:SqlDataSource
        ID="PortalDatabase"
        runat="server"
        ConnectionString="<%$ ConnectionStrings:serviceportalConnectionString %>"
        SelectCommand="SELECT [tab_name], [file_name] FROM [tabs] WHERE ([access_level] <= @access)"
    >
        <SelectParameters>
            <asp:Parameter Name="access" Type="Int32" DefaultValue="2" />
        </SelectParameters>
    </asp:SqlDataSource>


need that "DefaultValue=2" to be DefaultValue=access




Top
                 
Quake3World.com | Forum Index | General Discussion


Post new topic Reply to topic


cron
Quake3World.com
© ZeniMax. Zenimax, QUAKE III ARENA, Id Software and associated trademarks are trademarks of the ZeniMax group of companies. All rights reserved.
This is an unofficial fan website without any affiliation with or endorsement by ZeniMax.
All views and opinions expressed are those of the author.