.NET Tutorials, Forums, Interview Questions And Answers
Welcome :Guest
Sign In
Win Surprise Gifts!!!

Top 5 Contributors of the Month
Gaurav Pal
Post New Web Links

How to remove white spaces - asp.net 4.0

Posted By:      Posted Date: October 12, 2010    Points: 0   Category :ASP.Net

hello everybody. i want to remove all white spaces at both html and javascript files. how can i achive this.


using iis 7.5

asp.net 4.0

asp.net web site project


thank you 

View Complete Post

More Related Resource Links

How to remove the blank spaces between subreports in sql server reporting service?


In Sql server reporting service the blank spaces or white spaces are coming in between the subreports, when we place the subreports in the main reports.

If any one know how to remove the blank spaces between the subreports, please reply me. Its very urgent.

How to remove blank spaces between the subreports

How to remove blank spaces between the subreports if subreports don't have data to show up?
for example if in my reports there are 7 subreports. if subreports 2 and 4 don't have any data then there is blank space between 1 and 3 and 3 and 5.

How to minify html , css , javascript ( removing white spaces etc )


i am looking for a tool which will minify my code when publishing website


or it may be run time minify too if not using too much cpu power



Microsoft Ribbon for WPF - How to remove white gloss from Tab Panel


Using the Ribbon, I can set the background property to Black. This doesn't set the entire background to black, but only appears to set part of a gradient to black, leaving the top half of the tab's panel with a gradient fade to white. (or maybe it's a clear to white gradient overlaying the black background).

I'd provide an image but I can't find any tools allowing me to upload one. The XAML to reproduce is quite simple however, just start a new project with a the Ribbon for WPF (downloaded from http://www.microsoft.com/downloads/en/details.aspx?FamilyID=2bfc3187-74aa-4154-a670-76ef8bc2a0b4) and set the Ribbon's background to black:


remove white space between the html tag


hi i m using vs2005 for development

i haev desing a one web page with size ( 15 k)

now i want to remove the white space and make it in one single line .

how i can do that , thax

How to remove spaces from varchar column


Hello guyz;

I got a varchar column that I want to remove extra spaces from its contents.

what I want to do is keeping only 1 space between each 2 words ...I don`t want to keep more than one space between each 2 words

Remove Spaces in an SQL Statement


I have a query which is shown below:


Decalre @sql as nvarchar(max)

set @sql = 'Insert into XYZ( [x],



  THe query was wriiten by one of my developers and each column started on anew line.

The problem here is when i tried to use the following statement

EXEC sp_executeSQL @sql1

the execution is failing because the whole @sql is not fitting into nvarchar. As far i know if i use so_executesql the max length allowed is 4000, but my query is longer than tht, hence there is error becuase everything could not fit into into Nvarchar

IS there a way that i can trim the empty spaces while executing.

I have a tedious process where i bring all the columns into one single one. Is there an easy process for this?


Remove #Region from whole web site


Hi All,

I need to deliver source code to client and my boss need to remove all the comments and #region sections from the whole web site source code.

So is there any functionality available in visual studio 2010 or may be in an other 3rd party tool available to do so, which can remove all the #region from all over the source code ?

Otherwise my developers has to do donkey work.... :(( and I don't wish it. 

Any help or tips/tricks would be appreciated.


Image processing, determine white space and crop



I have created a image upload for our ID card system to allow users to upload new images, edit them and submit for approval.  This is all working well with a combination of asp.net (c#) and jquery to give a seemless editor etc.

We have had a few users who I cannot believe have scanned a photo of themself and then just submitted it with the A4 page of white and little photo.

I am wondering if anyone can help with a suggestion on how I could possibly reduce the load of these coming through (I can't believe they can be this stupid), it stipulates UK passport standards.

Would my only option be to check for a single continues colour that occurs and if it reaches a certain percentage point say 60% then to just send back an error stating they need to crop the image.

Can anyone help with providing sample or that I can use to move this one on.

I am still in disbelief on this one.  the other one is they take a photo of whole body and other in it and cut straight down middle chopping the people out but supplying a photo that no use for an id photo card....but that I can't imagine being solved programatically as I need to determine where their face dimensions are and what percentage of the actual photo is taken up by it and if it below a threshold reject it.

Web deployment project - web.config section replacement does not add remove tag


I have a web application that is actually installed as a component of a third party site.  In some configurations, I need to remove certain connection strings and re-add them.  I'm replacing this web.config section with a xml file that includes the following:

      <remove name="MyOverridenConnection"/>
      <add connectionString="Integrated Security=SSPI;Persist Security Info=False;Initial Catalog=MyDb;Data Source=MyServer" name="MyOverridenConnection"

For some reason the remove tag is left out during the substitution and I end up with the following in the installed config:

      <add connectionString="Integrated Security=SSPI;Persist Security Info=False;Initial Catalog=MyDb;Data Source=MyServer" name="MyOverridenConnection"

Is there any way to issue removes in replaced sec

Remove characters in a string


i have a string like this   sravani/, asdfff/, lsdsf/
i want to remove last character '/'  in the above string...
which function can i use?

pls help me....

How To Remove a Query Parameter from a URL


for a string such as this:


how would I remove the parameter id 12?


Delete spaces created by combining 2 fields


Howdy, this is kind of a continuation of an answer I got from this thread:  http://forums.asp.net/t/1592766.aspx

My users will enter a city/station where an incident occured, and the date.  The trigger below does work, but it will occasionally put spaces between the citystation and the date.  I think this happens when the citystaion name is not very long, but not sure.

(ex: city____08242010)

How can I make sure that if the incidentid is going to have spaces, that sql deletes those spaces?  I need the id to be space free.





TRIGGER [dbo].[tr_AddID1] ON [dbo].[tblIncidents] INSTEAD

Remove HTML formatting


Anyone know how to remove html-formatted-string to plain text programatically?

I want to get the same result as if i ctrl+a in a browser's page and then ctrl+v in a notepad.

I was googled how to strip html string, but didn't find the good result.

Removing tag using regex: "<(.|\n)*?>" causes some problems:

* The html-table is not nicely converted to tabbed plain text. It produces *crazy* table in plain text.

* the html-alternate-image lost

* the list ( <ul> & <ol> ) is not conveted well. No numbering or bullets in plain text

SharePoint Workflow E-mail Hyperlink has the Spaces Between Two Words Are Removed

I have a very simple Workflow, that includes href link to Infopath form.
If the form name includes spaces, the URL redirects to a The Form has been Closed message, indicating that it cant find that form.
In our scenario, the file name of the document/form in SharePoint when saved is called "Travel Request - <submit date>"  as noted with spaces.
The Hyperlink URL in the email generated by the workflow appears to encode all values in the name after the first two words (after Request).  See below.  after the word Request the spaces are encoded properly.     its replacing the first space with it appears %0d%0a (CR LF)
The URL below is what is displayed when right clicking, and selecting Edit Hyperlink in the email

I can reproduce this in development and production.  Any ideas on how this can be resolved?

While Printing an Infopath Form it Prints lot of Blank Spaces Before RichText Field


I had an infopath form with few rich text field. When i copy some content from somewhere and paste in the richtext Box then while Printing the form I get Lot of Blank Spaces Infront of the rich text box.

I tried creating teh print view too but still i get bunch of empty pages printed before by richtext box control.

Is there a way we can remove those blank spaces.....

I am not able to find out what is going wrong here....

SSRS Report viewer + Remove


I am running the report from SSRS report server in the view i am finding that the window title is Report Viewer - Windows Internet Explorer.

How to remove this name and get the name of the report over there.

I am using java at the back end to call the repot through url.

Please help me .

Thanks ,


ASP.NetWindows Application  .NET Framework  C#  VB.Net  ADO.Net  
Sql Server  SharePoint  Silverlight  Others  All   

Hall of Fame    Twitter   Terms of Service    Privacy Policy    Contact Us    Archives   Tell A Friend