Hello,
I have a form that contains a GridView control which is databound to an ObjectDataSource Control. There are several TextBox controls that are already being used as ControlParameters for the ObjectDataSource. I also have a custom data object that the ObjectDataSource is associated with {TypeName="myDataClass"}. The values are pass...
I'm setting the cookie expiration using the following code:
// remove existing cookies.
request.Cookies.Clear();
response.Cookies.Clear();
// ... serialize and encrypt my data ...
// now set the cookie.
HttpCookie cookie = new HttpCookie(AuthCookieName, encrypted);
cookie.Expires = DateTime.Now.Add(TimeSpan.FromHours(CookieTimeOutHo...
Ok Here's the issue..
I have small page which has label, dropdownlist and a submit button.
<div>
<asp:label id="Message" runat="server"/>
<br />
Which city do you wish to look at on hotels for?<br /><br />
<asp:dropdownlist id="Dropdownlist1" runat="server" EnableViewState="true">
</asp:dropdownlist...
I have a row of data that I need to modify in a database, using a stored procedure. But in order to call that stored procedure, I need to know the name of the each column. How do I determine the name of the columns? (Hardcoding is not an option as we are talking a LOT of columns whose names may change).
EDIT: given the accepted answer, ...
I've used a tool from Aspose (Aspose.PDF.kit) to generate a JPG thumbnail on the fly of a PDF for a .NET application. This works great, but what kind of other alternatives are there? Codeproject.com has this tutorial, but it requires you to have the full version of Acrobat.
Is there an open source alternative that's geared for ASP....
I typically use URL rewriting to pass content IDs to my website, so this
Foo.1.aspx
rewrites to
Foo.aspx?id=1
For a specific application I need to pass in multiple IDs to a single page, so I've rewritten things to accept this:
Foo.1,2,3,4,5.aspx
This works fine in Cassini (the built-in ad hoc web server for Visual Studio) but...
I have a validation control that has the following expression:
(?=(.*\\d.*){2,})(?=(.*\\w.*){2,})(?=(.*\\W.*){1,}).{8,}
That's a password with atleast 2 digits, 2 alpha characters, 1 non-alphanumeric and 8 character minimum. Unfortunately this doesn't seem to be cross-browser compliant.
This validation works perfectly in Firefox but ...
I have asp.net form that contains fields. When I access this window, my javascript functions can access the fields via the DOM with the getElementById() method and when I postpack to the server I am receiving the updates made by the client.
However, when I launch the form as a child window using Telerik's RadWindow control, the javasc...
I'm designing some VB based ASP.NET 2.0, and I am trying to make more use of the various ASP tags that visual studio provides, rather than hand writing everything in the code-behind. I want to pass in an outside variable from the Session to identify who the user is for the query.
<asp:sqldatasource id="DataStores" runat="server" connec...
Hi
I get the following error when trying to load an RSS feed:
"Attempted to read or write protected memory. This is often an indication that other memory is corrupt."
My code works fine from my local host, error only occurs when i upload it to my dedicated server!
Here is the code:
Protected Sub Page_Load(ByVal sender As Object, ByV...
Now that Silverlight 2.0 has been officially released I was wondering if anyone was using it for any line of business apps, for example POS, Vertical Market apps etc. If so how were your experiences compared to an old WinForms app or Web app?
...
I have a pictures table that has the following columns:
PICTURE_ID int IDENTITY(1000,1) NOT NULL,
CATEGORY_ID int NOT NULL,
IMGDATA image NOT NULL,
CAPTION1 text COLLATE SQL_Latin1_General_CP1_CI_AS NULL,
MIME_TYPE nchar(20) NOT NULL DEFAULT ('image/jpeg'),
IMGTHDATA image NOT NULL
In my code-behind I have this:
string tableName = "C...
Is there a way I can control columns from in code. I had a drop drop box with select : Daily and weekend and the gridview column with Monday, Tuesday, Wednesday, Thursday, Friday, Saturday,sunday.
If the user selects Daily i want to show columns only from Monday to Friday.
It is possible to control from the code. Oh i am using this gri...
I know it's possible to change some columns in GridView controls to check boxes and when you are editing certain rows, the cells being hi-lited become text boxes, but supposed I want to add other controls in my gridView. For example: in the image below how would I change the entries of CategoryName to be a dropDown box of possible choice...
How do I generate excel reports with rich formatting including charts with a ASP.Net application?
As per http://support.microsoft.com/kb/257757 server-side automation of office is advisable and also our admin does not allow installation of office on the server
Customer is not ready to spend a lot on 3rd party components
A must require...
I don't understand it.
The ids of html elements in the master page are changed by the same id but with a prefix and it's breaking the css design.
In the master page I have:
<div id="container" runat="server">
<asp:ContentPlaceHolder ...
...
The above code is rendered
<div id="ctl00_ctloo_container">
...
And the CSS s...
I've read all the marketing speak about how mvc and webforms are complementary etc... However it seems that all the blogs talk about is mvc and the only news coming out is about mvc.
Is microsoft going to continue to IMPROVE webforms as a first class citizen or will it just be a supported technology as they move all their real efforts,...
I'm looking for a tool that can be installed on our monitoring server and which allows us to perform scheduled requests to our web sites in order to keep them from shutting down (asp.net).
I don't want to use a web service since we already have a dedicated monitoring server. Our monitoring software doesn't really have the ability to do ...
I need to call a VBScript file (.vbs file extension) in my C# Windows application.
How can I do this?
There is an add-in to access a VBScript file
in Visual Studio.
But I need to access the script in code behind. How to do this?
...
How would I set an image to come from a theme directory (my theme changes so I don't want to directly reference) I am sure this is possible but every example I find doesn't seem to work. They are usually along the lines of:
asp:image ID="Image1" runat="server" ImageUrl="~/Web/Mode1.jpg" /
where Web would be a sub directory in my themes...