I would like to find a way to create and populate a database during asp.net setup.
So, what I'm willing to do is:
Create the database during the setup
Populate the database with some initial data (country codes or something like that)
Create the appropriate connection string in the configuration file
I'm using .NET 3.5 and Visual St...
I'd like a way to both show an asterisk by an invalid field and show a verbose message in a validation summary. However, setting Display to "NONE" in the validation control suppresses any message that would appear next to the field to validate.
Is there a way to get this kind of hybrid function?
...
I'm working on IIS6, ASP.NET, VS2008. The web site uses a custom error handler to catch 404 errors and serve an alternate page. When presented with an url of the form:
http://srv/crimson/articles/index
Everything works perfectly. But an url of the form:
http://srv/crimson/blog.aspx
Where blog.aspx does not exist, fails with the follo...
I want to have a DropDownList in the header of my GridView. In My codebehind I can't seem to access it. Here is the HeaderTemplate:
<asp:TemplateField SortExpression="EXCEPTION_TYPE">
<HeaderTemplate>
<asp:Label ID="TypeId" runat="server" Text="Type" ></asp:Label>
<asp:DropDownList ID="TypeFilter" runat="server" Auto...
We have several ASP.NET applications deployed to a few servers. Is there a standard way to reuse session data or some other method to not require users to log in to the next application when moving from application to application if they've already authenticated? I'm hoping there's a best practices way of doing this that you guys know ab...
What is the best way to reset the scroll position to the top of page after the an asynchronous postback?
The asynchronous postback is initiated from a ASP.NET GridView CommandField column and the ASP.NET update panel Update method is called in the GridView OnRowCommand.
My current application is an ASP.NET 3.5 web site.
EDIT: I ha...
I am not a designer, so I took a design template from http://www.opendesigns.org/ and was successful in implementing the design in one page, but when I tried to put it into a masterpage, it came out funny looking, so I was curious if there were any resources/tutorials on taking design templates and putting them in masterpages.
...
Our system consists of a self-hosted (non-IIS) WCF service and an Asp.net website which hosts a Silverlight application. The application is supposed to do pretty much everything, the website is just a "shell" in this case.
We have a hard time figuring out how to solve user authentication securely.
To my knowledge, Silverlight can not h...
I've got a LinkButton set up in the ItemTemplate of a ListView. It displays fine, but it's not doing anything when clicked. It's supposed to be a simple Edit button, but it's driving my crazy. Here's the button:
<asp:LinkButton ID="EditLinkButton" runat="server" CommandName="Edit" Text="Edit" />
and here's the code-behind:
Protected ...
Hi All
I'm using RC1 of ASP.NET MVC.
I'm trying to extend Phil Haack's model binding example. I'm trying to use the default model binder to bind the following object:
public class ListOfProducts
{
public int Id { get; set; }
public string Title{ get; set; }
List<Product> Items { get; set; }
}
public class Product
{
pu...
I would like to be able to do something like:
<ui:Tab Title="A nice title">
<TabTemplate>
<asp:Literal runat="server" ID="SetMe">With Text or Something</asp:Literal>
</TabTemplate>
</ui:Tab>
but also be able to do:
<ui:Tab Title="A nice title">
<TabTemplate>
<asp:DataList runat="server" ID="BindMe"></asp:DataList>
</T...
I made a fairly large social network type website and used nothing but inline SQL Statements to access the database (I was new to the language so back off!)
Are there any performance issues when doing it this way as opposed to using a massive XSD DataSet file to handle all the queries? Or is this just bad design?
Thanks!
...
hi
I've started learning data source controls
To my understanding, the only benefits of using data source controls instead of using regular data binding are the following:
you don’t have to write data access logic (thus you don’t have to create SqlCommand, SqlConnection etc, and you also don’t have to create Datareader or DataSet)
y...
JQuery is not being able to identify tags when I use in the Master Page. The following code:
<script type="text/javascript">
$("body").append('<div id="test"><p>Hello</p></div>');
</script>
Works fine in normal pages, but when the body is in the master page and I put this same code in the Master page - nothing happens!
How can I...
I'm using asp.net 2.0. I am using declarative datasources. For some things in the code behind I want access to the object returned by Foo.Bar (In the following example). the system is caching it so I should be able to acces that version instead of having to re-call Foo.Bar(). How do I do this?
<asp:ObjectDataSource ID="MyLuckDataSource1...
I have an asp.net page with a save button within an updatepanel and contenttemplate. The save works nicely, but I am trying to add a "wait" gif while the save is happening using JQuery, but the ajaxStart event is not firing. I put a simple catch shown below:
$(document).ajaxStart(function(){
alert('starting');
...
I have a rather complex custom control - the custom control has a couple of update panels in it.
I am trying to use the control like this inside of an update panel:
<asp:UpdatePanel ID="up1" runat="server">
<ContentTemplate>
<asp:Button ID="btn1" runat="server" Text="Sample Button" /> <asp:Label ID="lblTime" run...
I'm working on a web site which contains sections that need to be secured by SSL.
I have the site configured so that it runs fine when it's always in SSL, I see the SSL padlock in IE7/IE8/FireFox/Safari/Chrome
To implement the SSL switching, I created a class that implemented IHTTPModule and wired up HTTPApplication.PreRequestHandlerE...
I need a few pointers about how to make a project structure in order to migrate from VSS to SVN, as it stands now it has:
Dev
trunk-------------------------------->http://localhost/myapp
Test environment branch
---------->http://test.myapp.com
Production environment
branch-->http://www.myapp.com
The deal here are th...
I am attemping to have my gridview be:
bound by a List in code-behind. I am using my own custom BOL.
no datasource object on the html page
sortable on each column that I choose. The SortExpressions are all set correctly.
The resulting error message:
The GridView 'myGridView' fired event Sorting which wasn't handled.
How can I have...