I have links on a homepage that may or may not have attachments associated with them. If the links have attachments, then an icon will be placed next to the link. The icon will only be there if the link has an attachment.
protected void Page_Load(object sender, EventArgs e)
{
foreach (Image pic in imgAttachment)
...
Hi All,
in ASP.NET,
I've bound a listbox control to a List of custom class (consisting of a TimeSpan and Int members).
the ToString() function just displays them both as a long string.
Now I want to save the modified listbox into the DB again, I need to use the custom class objects again.
Does the ListBox save the actual custom object...
In asp.net, when do you bind your gridviews? at Page Load() or Page Init()....why?
...
I have an application written in ASP.NET 1.1. If I switch IIS to use 2.0 what issues am I likely to see? Initial tests have thrown no problems, but I was wondering if anyone had experience of running ASP.NET 1.1 applications under 2.0 and could maybe point out some areas to watch out for?
Thanks for any advice.
...
I've installed ODP.NET and am using the session state service through Oracle for an ASP.NET website. I tested it, I thought, pretty thoroughly and didn't see any major problems. Some of the users have been complaining of exception errors however when they use the system. I added some extra logging and found out how to reproduce the is...
Hi,
what is the difference between session and httpcontext.current.session?
...
I am creating an invoice application and in the section where the user can enter line items, some of the fields will include: Quantity, Price, Extended Price, Description, etc.
If the user enters something into any of the fields, the corresponding fields are required, but if no data is entered into any field, then nothing is required in...
How would one get resx resource strings into javascript code stored in a .js file?
If your javascript is in a script block in the markup, you can use this syntax:
<%$Resources:Resource, FieldName %>
and it will parse the resource value in as it renders the page... Unfortunately, that will only be parsed if the javascript appears in...
My team is currently in the process of building an ASP.NET MVC application, and we're trying to decide which of these frameworks to implement to deal with error handling and logging.
What are the reasons for choosing one of these over the other?
...
In a web application that I have run across, I found the following code to deal with the DataContext when dealing with LinqToSQL
public partial class DbDataContext
{
public static DbDataContext DB
{
get
{
if (HttpContext.Current.Items["DB"] == null)
HttpContext.Current.Items["DB"] = new DbDataCont...
I have a button in a grid that I created programmatically. The button edits some data in a table using data in a hidden column of the grid that the button is in. Normally I send a hidden field the row data using javascript onclientclick of the button then make the changes to the database using that hidden field. But there must be a way t...
Solution:
It turns out I wasn't checking the path that it was looking up, quite silly of me. Once I tracked that problem down and corrected the offending path, the reading worked just fine. Still baffled at the MSSQL issue, since the articles average less than 10 000 bytes.
Clarification:
I am unsure if some of you are under the imp...
In SSRS 2005 (and 2008 I would imagine) you can provide functions to the reports, and if I'm not mistaken, whole assemblies as well, which allow you to perform some type of work before the report is rendered.
Does anyone know at what point in the ASP.NET page life-cycle is this function compiled and / or executed?
I would tend to thin...
Why do we need callbacks in ASP.NET or any server side technology?
One answer can be, to achieve asynchronous calls. But I am not interested in its technological perspective. Please tell me the philosophical perspective.
...
I am having a minor issue playing with my exported Crystal Report, I can generate the reports just fine on our website, however when I attempt to export them to Word documents I don't quite get a document I can do much with.
i.e.:
I can't position the generated text anywhere in the document, it is almost 'frozen' in place. I would ex...
I have a .net 3.5 aspx place with a method tagged with the [WebMethod] tag. I'm calling this with jQuery, sending JSON in both directions. This all works great. My question is, what does [ScriptMethod] do when applied to a function? I've tried this and it seems to yield the same result. Are ScriptMethods and WebMethods identical and inte...
What is the sytnax for displaying a data table column on an ASP.NET page (.aspx)? I know it it along the lines of Container.DataItem, it has been awhile since I worked with DataTable object
...
I am using Visual Studio 2008 | .NET 3.5 | C#. I have created an user control that has the following property: DisplayMode. DisplayMode is meant to either display a series of text boxes or a single text box.
[Browsable(true),
Category("Appearance"),
DefaultValue(DISPLAY_MODE_FIELDS),
Description("Indicates whether to display the phone...
A while back, when ASP .Net Dynamic Data was fresh into beta, we had built a test site with it, checking out its functionality. It was kind of left there not the subject of much attention.
I've now gone back to the site to make modifications, lo and behold, when i tried to load the site, i got this error:
The type or namespace na...
Hello,
Even though UpdateNames stored procedure only takes one parameter named @First, we are still able to define additional parameter named Last, and the update will still be successful:
<asp:SqlDataSource ... UpdateCommand="UpdateNames"
UpdateCommandType="StoredProcedure">
<UpdateParameters>
<asp:Pa...