How to add a script file programtically?
I have a jquery script that I need to add to my pages through C# code. The way I am doing it now causes trouble with the .net ajax toolkit.
I have it like this
I am using ResolveClientUrl because I have some pathing issues if I don't.
But when I have anything from the toolkit I get this error
The Controls collection cannot be modified because the control contains code blocks (i.e. <% ... %>).
I found a person saying that to avoid this you have to put your script programatically in but I don't know how to do this.
Please see the following blog post:
The Controls Collection Cannot Be Modified Because the Control Contains Code Blocks
Thanks your a lifesaver lol.
How would you add a script in C# codebehind? Just curious.
Using the Grid View
okay so basically i use the login control to make my account on my website (aside from the issue that i can not log in with that account more than once...), i want to use the gridview to show all the members. the problem is it shows everything, security answer/question, is online, provider, etc... i just want to pull out the isonline and UserName columns but idk what table the data is being held in i looked at the tables folder in the database manager on VWD and there is no table i see with those column names.
if anyone can show me how to display:
Member Name IsOnline
in a grid view. or anything like that. let me know...maybe i should use a different control? my thanks in advance
oops. this isnt a new thread... my bad
I might suggest you post this question in a new thread, rather than sticking it in a totally unrelated thread like this. More people will see it that way.
i know i know... i minimized the window and forgot where i was at... i thought i was making a thread but i was looking up the answer to his question.
<%@ Page Language="C#" AutoEventWireUp="true" CodeFile="FirstPageCodeBehind.aspx.cs" Inherits=classname %>
Code File is self explanitory but Inherits links you to the class in the code file. just type a class name.
|All times are GMT -4. The time now is 06:34 AM.|
Powered by vBulletin®
Copyright ©2000 - 2016, Jelsoft Enterprises Ltd.
© 2013 John Wiley & Sons, Inc.