Basically, I would like a brief explanation of how I can access a SQL database in C# code. I gather that a connection and a command is required, but what's going on? I guess what I'm asking is for someone to de-mystify the process a bit. Thanks.
For clarity, in my case I'm doing web apps, e-commerce stuff. It's all ASP.NET, C#, and SQL ...
Any suggestions for good open source asp.net (C#) apps out there which meet as many of the following:?
Designed well and multi tiered
Clean & commented code
Good use of several design patterns
Web pages display properly in all common browsers
Produces valid html and has good use of css
Use of css themes. Prefer usage of css than tables...
I need to be able to get a list of the groups a user is in, but I need to have one/some/all of the following properties visible:
distinguishedname
name
cn
samaccountname
What I have right now returns some sort of name, but not any of the ones above (the names seem close, but don't all match correctly. This is what I am using:
Array...
I just noticed that the return list for results is limited to 1000. I have more than 1000 groups in my domain (HUGE domain). How can I get more than 1000 records? Can I start at a later record? Can I cut it up into multiple searches?
Here is my query:
DirectoryEntry dirEnt = new DirectoryEntry("LDAP://dhuba1kwtn004");
string[] loadProp...
Continuation to my previous question is any one aware of a comprehensive document what list all available differences between debug and release modes in C# application , and particularly in web application ?
What differences you aware of ?
...
I have several user controls, let's say A, B, C and D. Based on some random input, I need to generate a combination of these. For e.g. if input is 2a3d1a2c I need to show two of the A's, 3 D's after that, an A again, etc.
I will also need to stabilize clientid's in order for them to work correctly. Because each of these controls use the...
How does one go about programatically building a TemplateColumn object and adding it to a DataGrid. I know how to add it, but not how to build the contents of the TemplateColumn. There are no useful looking methods on the ITemplate the column class exposes.
...
Coming from a Classic ASP background, I'm used to multiple forms on a page, but this clearly limited in a ASP.NET page.
However, I have a situation where I have a form that gathers input from the user, saves the data to a DB, and afterwards I want to render (and tweak the values of) a special form that posts to the PayPal website.
If t...
I am looking for a good way to consistently test my web applications from the end users point of view. I have all kinds of ways to check to make sure my code is working behind the scenes. I can't count the number of times that I make a change to a piece of code, test it and it works fine and then deploy it only to have it blow up somewhe...
Hi all,
I have a DataGrid where each column has a SortExpression. I would like the sort expression to be the equivalent of "ORDER BY LEN(myField)".
I have tried
SortExpression="LEN(myField)"
but this throws an exception as it is not valid syntax. Any ideas?
...
Say I have the following web.config:
<?xml version="1.0" encoding="utf-8"?>
<configuration>
<system.web>
<authentication mode="Windows"></authentication>
</system.web>
</configuration>
Using ASP.NET C#, how can I detect the Mode value of the Authentication tag?
...
I'm trying to make a data bound column invisible after data binding, because it won't exist before data binding. However, the DataGrid.Columns collection indicates a count of 0, making it seem as if the automatically generated columns don't belong to the collection.
How can I make a column that is automatically generated during binding...
Is it possible for ASP.NET to mix up which user is associated with which session variable on the server? Are session variables immutably tied to the original user that created them across time, space & dimension?
...
I have a SQL Server 2000, C# & ASP.net web app. We want to control access to it by using Active Directory groups. I can get authentication to work if the group I put in is a 'Global' but not if the group is 'Universal'.
How can I make this work with 'Universal' groups an well?
Here's my authorization block:
<authorization>
<all...
Based on a simple test I ran, I don't think it's possible to put an inline <style> tag into an ASP.NET server control. The style did not end up rendering to the output HTML. Even if it was possible, I'm sure it is bad practice to do this.
Is it possible to do this? I can see it being useful for quick prototypes that just have 1 or 2 ...
My Web Application is split up in a WebGui and an WebService. The WebService is responsible for Business Logic and Database handling.
From Javascript in the Browser I request data depending on a date and time that is an input from the Browser. This request gous to an .asmx Url in the WebGui and inside this function the webservice is call...
I am writing a Composite control, which contains a listview to display a table of items. Normally when using a ListView in Asp.NET I would define the templates in the code-forward.
<asp:ListView runat="server" ID="ArticleList">
<LayoutTemplate>
<div class="ContentContainer">
<div runat="server" id="itemPlaceholde...
Was looking for some approaches to incrementally converting an large existing ASP.NET VB.NET project to C# while still being able to deploy it as a single web application (currently deployed on a weekly basis).
My thoughts were to just create a new C# ASP.NET project and slowly move pages over, but I've never attempted to do this and ...
I have a user control which is loaded in the page dynamically using the following code in Init of the Page.
Dim oCtl As Object
oCtl = LoadControl("~/Controls/UserControl1.ascx")
oCtl.Id = "UserControl11"
PlaceHolder1.Controls.Clear()
PlaceHolder1.Controls.Add(oCtl)
The user control also contains a button and I am unable to capture th...
I have recently inherited a brownfield application that is currently live. Through response, or a response with a link, how and what is the best method to make changes to a site and deploy them to a live ASP .NET website.
...