asp.net

Simple Question, how to I create a dynamic CSV - ASP.NET, VB

Howdy, Now I'm a complete newby to .Net and the likes of VB (I'm more of a Ruby/Rails, PHP kinda guy). Anyway I currently have a sub that has a string builder that I'm wish to use as the content of a CSV which I will email later from a webpage. My stringbuilder is creating the content for the CSV but I don't know how to create the CSV ...

changing checkbox label colour on databound

Ive searched everywhere for this but cant find the answer. I have used the following code before to change repeated items properties in an asp.net repeater as after they have been bound to do things i couldnt do prior to binding them. protected void rowRepeater_ItemBound(object sender, RepeaterItemEventArgs e) { foreach...

Checking for database changes at set intervals in ASP.NET page

Hi all, I have an ASP.NET page which contains a large number of gridviews, which contain masses amount of data which take a fair while to rebind. I currently have it set so the gridviews are only bound when the account number is changed (on the page, the user searches for an account which then displays their information). I'd like it to...

sorting gridview

I had gridview where bind datasource I had to add sorting for this gridview I added the code below to that but It didnot work well. private string ConvertSortDirectionToSql(SortDirection sortDireciton) { string m_SortDirection = String.Empty; switch (sortDireciton) { case SortDirection.Ascending: m_SortD...

Parse a JSON query response string in ASP.NET

Hey guys I have the following code working which is sending a GET Request and receiving JSON Response. Now I can basically go GetWeatherByLocation(53.3, -6.28); and the method returns {"status":"OK","url":"http://www.link.com/areas/rathfarnham-11","name":"Rathfarnham"} I was now wondering how can I retrieve the values for URL Nam...

Dev and deploy management with SVN of a Web Site

Hi We have a .Net solution for a website, consisting of 5 projects, and there are a few(less than 10) developers working on the solution. We deploy almost on a daily basis. The question is, how to setup the SVN repo to support this scenario (the daily deploy), also mentioning that not every commited file should go to production, there is...

how to check Page.Validate() on client side (Javascript) in Asp.net?

I want to check page validation on client side, like Page.Validate() but its server side method, is there any client side function which can work like Page.Validate() with javascript. ...

Library to convert Word document text to HTML

Hi, Is there a .Net open source library to convert the word dococument to HTML to display inside the webpage. I know several tools to convert word docs to html files, but my requirements is to convert the doc(either from the file or just extracted text) to HTML on the fly in the ASP.Net application. I found the converting-a-word-docu...

to rewrite url in Global.asax, ASP.NET

HEllo. I need replace double slashes in one slash. I am planning do this in Global.asax Application_BeginRequest event. Is it enough? or better do a http module? Thank you. UPD Sub Application_BeginRequest(ByVal sender As Object, ByVal e As EventArgs) ' Fires at the beginning of each request Thread.CurrentThread.CurrentCul...

ASP.NET session id shared amongst browser tabs

I've recently been developing a website using asp.net webforms that uses in proc sessions and I noticed that session ids are shared amongst browser tabs. So I was wondering what you would do for the following situations: Problem: Multiple logins with different users in the one browser problem User opens browser tab 1, logins with "...

Order of CSS and Script Calls in a aspx page

Is there any specific order in which the external CSS or Scripts should be called in a aspx page which could help a bit in decreasing the page load time? i.e script type="text/javascript" src="../Includes/JavaScript/jquery.ui.tabs.js" link href="../Includes/css/ui.all.css" rel="Stylesheet" type="text/css" or link href="../Includes...

Multiple submit Button click problem?

I have a form which inserts data in DB on Submit button click but the problem is when client click the button multiple times its sends multiple create requests means multiple button click events for the same time of same data, which must not be. I tried to disable the button when client click the Submit button first time but after this ...

Removing Specific Routes from ASP.NET 4 RoutesTable

hello everybody my site has many many routes. since the users can add or remove pages at will, i need a way to reregister the routes from time to time at reregister i do not want to clear the whole route cache ("RouteTable.Routes.Clear"), but i would rather go thru the table route by route, and using a certain regex on its name, decide...

Linq to DataTable not producing Distinct values

Hi, I have a datatable which has been dynamically generated from FoxPro tables using a UNION Select statement. e.g. SELECT * FROM x UNION SELECT * FROM y UNION SELECT * FROM Z ORDER By v_alue1 This produces a datatable with about 100 rows, each containing many fields, one of which is c_olor. From this datatable, I would like to selec...

ASP.NET handling dropdownlist selection across multiple tabs session or querystring?

I've recently been developing a website using asp.net webforms that uses in proc sessions and I noticed that session ids are shared amongst browser tabs. So I was wondering what you would do for the following situation Problem: In my application I have a requirement where the user is allowed to select a competition via dropdown list. I...

Adding A Custom Property To Entity Framework?

I am using the Entity Framework for the first time and want to know if the following is possible - I have generated my classes from the DB, and have one called Category. Obviously it has all my fields in the table (ID, CategoryName, SortOrder etc..) but I want to know if I can add a custom property which is not in the table, but is actu...

Multiple different Excel sheets into one SQL table

Hello, I have a lot of excel sheets which columns are slightly different, i want to import all of these sheets (one at a time) into ONE SQL TABLE. I'll give an example : Say ive written the required program and called it Excel2sql converter. So Excel2sql takes an excel sheet and create a database table with the data of that excel shee...

stop/compile/run = "Unable to connect to any of the specified MySQL hosts." + crash, why?

In visual studios while debugging my asp.net project i see a change i'd like to make. I cant change code dynamically like i may in a winform app so 100% of the time i stop the app. Write my code and run. Now randomly, a good % of the time i get the error Unable to connect to any of the specified MySQL hosts. with a crash shortly aft...

How to catch 500 internal server error in c#

Im using Google Analytics Dashboard Control which are available at http://gadashboardcontrols.codeplex.com/ Issue is its working fine when im connected to internet but if im using it on a machine that doesnt have internet access then it shows Server Error in '/' Application. The remote name could not be resolved: 'www.google.com' ...

How to custom 'Type' in Compare Validator in ASP.Net

How to reset date Type for Compare Validator in ASP.Net i am using the dd/MM/yyyy format for the Calendar Extender of a textbox, where as Compare Validater looks for MM/dd/YYYY format. so how to change date format of Compare Validator. ...