Retrieve The Full Output From A Web Application With MSBuild

Jan 12, 2010

I have a misunderstanding with MSBuild. I want to build a web application (with a traditional .csproj project file) and get the "entire output" of the build in a new, clean output folder - including all the website files that are included in the project with <Content Include="....

The AspNetCompiler utility makes this easy for "web site" style projects - you specify the input folder and the output folder, and they can be entirely different.

So far I've only had success specifying the OutoutPath folder, i.e. moving the bin folder - but this only gives me the binaries and ignores aspx, image files, etc.

View 1 Replies


Similar Messages:

Get MSBuild Output From CCNet Api?

Jul 16, 2010

I am building an asp.net shell on top of CCNet 1.5, where I send commands like force build to CCNet through the api. The ThoughtWorks.CruiseControl.Remote namespace has methods to get information from CCNet on the build, like status, elapsed time, etc.I would like to programmatically get the MSBuild task output from the CCNet api, but I haven't seen any methods for this. Is it at all possible? Or do I need to scan output files on disk or something?

View 2 Replies

Retrieve The Full Application Path Within Code?

May 29, 2010

I need to be able to get the root directory for my site within my code. If my site is http://xyz.com, how can I retrieve this information within code?

View 7 Replies

Building A Web Application Using Msbuild?

Dec 10, 2010

I have a web application solution with 14 projects which include web services, class libraries, sub-web applications.. can anyone provide a solution on how to get along with an example?

View 1 Replies

Cannot Retrieve Output Parameters Until SqlDataReader Is Closed

Apr 13, 2010

While the SqlDataReader is being used, the associated SqlConnection is busy serving the SqlDataReader, and no other operations can be performed on the SqlConnection other than closing it. This is the case until the Close method of the SqlDataReader is called. For example, you cannot retrieve output parameters until after you call Close.

If the above claim is true, then why is the following method able to retrieve a value from output parameter before the reader is closed:

public int Something()
{
using (SqlConnection con = new SqlConnection(this.ConnectionString))
{
SqlCommand cmd = new SqlCommand("some_procedure", con);
cmd.CommandType = CommandType.StoredProcedure;
cmd.Parameters.Add("@ID", SqlDbType.Int).Direction = ParameterDirection.Output;
con.Open();
cmd.ExecuteReader();
return (int)cmd.Parameters["@ID"].Value;
}
}

You can reset the CommandText property and reuse the SqlCommand object. However, you must close the SqlDataReader before you can execute a new or previous command.

Why must you close sqldatareader before you execute new command?

View 2 Replies

Xslt - How To Retrieve Xsl:output Media-type Value From Xsl File

Mar 9, 2010

Is there a way to retrieve the media-type value? e.g. like OutputSettings.OutputMethod used to get xsl:output method.

View 2 Replies

Web Forms :: Retrieve Full URL And Display Inside Of A Control On The Page Using Masterpages

Jan 27, 2011

I am going to change an image, based on the incoming URL. So lets say, I have an image control named "specialImg", and 5 images I want to load based on the incoming URL.

Using C#, how do I accomplish the following?

User clicks a link and the URL is categoryproduct1, and when the page loades, I want this "specialImg" control to show the product1 image (it would read in the incoming URL and based on the name, change the image). If the user then goes to categoryproduct2, when the page loads, I want the "specialImg" control to display product2 image.. and so on.

I set the image control to runat="server", I guess I need to find out how to reference it by C# on page load.

View 7 Replies

MVC :: Change The Output Path Of Application?

Mar 16, 2010

I want to change the output path of a MVC2 application that is using the internal ASP.NET Dev Server within VisualStudio 2008.If I let the path "bin" it works. But if the path is changed, I get a Parser error:

Parser Error Message: Could not load type 'MvcApplication3.MvcApplication'.

View 10 Replies

Web Parts Vs. Full Blown Application In SharePoint?

Mar 2, 2011

I'm trying to get up to speed with SharePoint, coming from ASP.NET Web Forms. We're looking to use SharePoint exclusively for several reasons; one of the main selling points is to consolidate our development efforts. So for example, today we have several one-off websites with anywhere from 1-5 pages (smallish) on several servers, IIS installs, etc. and seem to be a bit fragmented.

Let's say I have a requirement for a smallish site (1-5) pages. What is the SharePoint way to handle this situation? Do I create several Web Parts, then create the pages in SharePoint and plug them in or do I simply create an ASP.NET Web Forms application and provide a link within SharePoint to it?

Update.I'm going with neither. Based on feedback and additional research it seems that Application pages are what I'm looking for. Here's a good article:

http://grounding.co.za/blogs/brett/archive/2008/07/13/sharepoint-the-role-of-a-web-part-vs-using-application-pages.aspx

View 4 Replies

How To Return The Full File Path In A C# Web Application

Apr 12, 2010

I have a VS 2008 web application that I need to capture the full file path (directories and file name) from the selected file. So user selects a file and then clicks on one of the buttons which transfers control to my code for processing. So how do I get the file path? I can get the file name, but not the path.

View 2 Replies

Get User's Full Name From Active Directory In Web Application?

Nov 28, 2010

I am trying to get the full name of a given user from active directory. This code works on my PC but when I put it on the server it throws exception:

The network path was not found.

The code is:

DirectoryEntry obDirEntry = null;
try
{
obDirEntry = new DirectoryEntry("WinNT://" + "domain" + "/" + Environment.UserName);
System.DirectoryServices.PropertyCollection coll = obDirEntry.Properties;
object obVal = coll["FullName"].Value;
Response.Write(obVal);
}
catch (Exception ex)
{
Response.Write(ex.Message);
}

how to fix so it would work on the server also? Or maybe some other way I can get the full name of a given user name? Do I need to use LDAP instead somehow?

View 1 Replies

How To Do Video/audio Input And Output Application

Feb 20, 2011

How to do video/audio input and output programmer/application using asp.net

View 3 Replies

C# - Output Javascript Selectively Depending On Application Settings?

Feb 24, 2010

I am developing a site which includes several different javascript files and libraries. For optimization purposes I have implemented YUI Compressor for .Net

This will minimize and combine my javascript files into one single file.

Now I have put this up in a MSBuild script that automatically does the compression and minimization and outputs it to a file of my choosing. However, I still wish to keep the original javascript files in my development environment. My question is simply:

Is there a good way to depending on the Debug setting for example choose which javascript to use? This to not have to change the MasterPage by hand each time I release the build.

Allow me to illustrate.

If I am running in Debug="true" I wish my MasterPage to include the following javascripts:

<script type="text/javascript" src="first.js"></script>
<script type="text/javascript" src="second.js"></script>
<script type="text/javascript" src="third.js"></script>
<script type="text/javascript" src="fourth.js"></script>

If I am running in Debug="false" I wish this to be outputted in the MasterPage:

<script type="text/javascript" src="compressedAndMinimized.js"></script>

View 2 Replies

Outputstream - Can Get Read Access To The HTTP Output Stream In Web Application

Feb 22, 2010

I would like to read all content that's been written to the output stream. I'm attempting to do this using an HTTP module, and it seems like the obvious timing would be when handling the PreSendRequestContent event.

However, if the output stream seems to be set to write-only, as I can't read using a StreamReader. Is there a way I read and re-write the content without writing my own IIS module?

View 1 Replies

Compile A MVC Project Using MSBuild?

Feb 3, 2010

How do I compile an ASP.Net MVC project using MSBuild? We use a Continuous Integration server to compile and deploy our applications. To keep things simple I created an MVC 1.0 project in VS2008. I immediately created an MSBuild script file to compile it. I did not change any code in the project. The MSBuild script contained the following target.

<AspNetCompiler
VirtualPath="/"
PhysicalPath="C:Developmentmvc1"
TargetPath="c:publishxxx"
Force="true"
Debug="false"
Updateable="true"

The MVC project sln file is contained in the c:developmentmvc1 directory.I am running XP/Pro.I am receiving an error ASPCONFIG: it is an error to use a section registered as allowDefintion='MachineToApplication' beyond application level.

I removed the authenication mode, membership provider, etc. from the web config file until I finally saw a different error message.I am now receiving an error message saying that the file '/views/shared/site.master' does not exist.

View 3 Replies

Building A .net 1.1 Project Using Msbuild?

Dec 7, 2010

The Web project we are working on is built against .net 1.1 framework.We would like to automate the build process for this project by using msbuild.However MSBuild only targets 2.0 framework. So how can this be done if we like to use MSBuild or MSBEE(this asks us to convert the web project to new version by opening up in Visual studio IDE)?We cannot convert the project to suit to 2.0 framework

View 1 Replies

Web Forms :: How To Capture Url And Show The Hyperlink Button Data Output In Console Application

Oct 6, 2010

i have an assignment , i have to capture a url which contain some hyperlink btn, i have to show the hyperlink btn text and their description

View 5 Replies

Controls :: How To Display Full PDF Files In Full Screen On Web Page

May 7, 2015

I use the code, to display the file that I saved in the database.the question is: why the file can not be performed with a full screen.

protected void View(object sender, EventArgs e)
{
int peraturan_id = int.Parse((sender as LinkButton).CommandArgument);
Session["peraturan_id"] = peraturan_id;
ClientScript.RegisterStartupScript(this.GetType(), "open", "window.open('file_view.aspx','_blank' );", true);
}
 
[Code] ....

View 1 Replies

How To Use Nant And MSBuild To Build Debug Deployment

Jun 17, 2010

I have a Nant build script which referrences 30 other build scripts.

Each build script referrences a visual studio solution using MSBuild.

Each solution has 3 to 5 projects in.

Some projects are Class Librarys and some are Web Apllications.

The projects reference other projects both in their solution and out of their solution, so the projects do not use project references, they reference the the Release DLLs in the Bin folders of the other projects.

To use the software, I need to publish all the solutions together.

Which means I cannot do a deployment which is in debug mode.

Which means I cannot the step into and debug the code.

I would like to run the build script to get a deployment of the software which I can debug.

View 1 Replies

Configuration :: How To Use Msbuild To Create MSI Files Or Setup

May 27, 2010

I want to Use MSBUILD to create MSI Files or setup. Can I do it programetically.

View 1 Replies

MSBuild: Automate Collecting Of Db Migration Scripts?

May 20, 2010

Asp.net web application (source stored in svn) sqlserver database. (Database schema (tables/sprocs) stored in svn) db version is synced with web application assembly version. (stored in table 'CurrentVersion')CI hudson server that checks out web app from repo and runs custom msbuild file to publish/package app.

My msbuild script updates the assembly version of the web app (Major.Minor.Revision.Build) on each build. The 'Revision' is set to the currently checked out svn revision and the 'Build' to the hudson build number (incremented on each automated build).

This way i can match the app to a specific trunk revision also get other build stats from the hudson build number.

I'd like to automate the collecting of migration scripts (updated sprocs etc) to add to the zip package. I guess by comparing the svn revision of the db that has yet to be deployed to, to the revision being deployed, i can find what db files have changed in the trunk since the last deployment to that database/environment.

This could easily be achieved by manually calling the svn diff -r REVNO:REVNO command to list changed .sql files. These files could then manually have to be added to the package.
It would be great if this could be automated.

Firstly i'd imagine I'll have to write a custom task to check the version of the db that has yet to be deployed to. After that I'm quite unsure. how this would be achieved through an msbuild task either existing or custom?

Finally I'll have to autogen a script to add to the package that updates the database version table so as to be in sync with the application.

View 3 Replies

Web Forms :: Browser Output Doesn't Look Like Web Developer Output Using Nested Master Pages And Css Stylesheets

Apr 18, 2010

First off, suggest better ways if you want rather than patch up this code. I am just starting this project and it is first time I have tried to code a web site so anything you suggest is very much welcomed. I have spent the last 2 and 1/2 days trying to find workable answers to this but none I have found and tried seem to fit. If needed I can email screens shots or code. I am trying to construct a website that will have the same main theme throughout as far as the header, navbars sitemap, and footer go. Naturally the content will vary from page to page. I want to use a single master page and css stylesheet for this main theme and I will change the content format as needed per page because each page may vary somewhat.

However, about 15 of the pages will all use the same format for their content and this format will differ from the rest of the site but the format of the main theme will stay the same. So I am trying to create a nested master page to use to format the just the content area for all these pages while retaining the main theme for the header, etc.. I believe I should use a separate css file with the nested master page to handle the formatting of the content areas for these 15 pages. I have code that looks like it works when viewed in web developer but design view but does not work when viewd through a browser (IE, Chrome, Firefox). So far I have the following done in web developer.

If it helps the code and screen shots follow. Master Page called "Parent.master". For all theme throughout site Nested Master Page called "Lab.master". For the 15 like pages Primary stylesheet file for main theme called "StylesheetNew.css" For site theme Secondary stylesheet file to syle the 15 like formatted pages. It is called Labmaster.css Labs.apsx file to use as first of the 15 like pages.
Finally screens shots from web developer and browser. Sorry try as I might I could not capture screenshots and put them into this post. The problem is that web developer shows all the area (many lines high) with gray background and with the XXX text that I want to allocate for content in the 15 pages. Yet all the browser show is one line of text o a white background followed by the footer. It looks like the LabStyleSheet works in Web Developer but not in a browser.

Parent.master
<%@ Master Language="VB" CodeFile="Parent.master.vb" Inherits="MasterPage" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "[URL]">
<html xmlns="[URL]">
<head id="ParentHeader" runat="server">
<title>HX5</title>
<asp:ContentPlaceHolder runat="server" id="headerPlaceHolder" />
<link href="~/StyleSheetNew.css" rel="stylesheet" type="text/css" />
</head>
<body>
<form id="form1" runat="server">
<div id="wrapper" >
<div id="Header" >
<table class="hdrtbl1" >
<tr>
<td id="hdrtd1" style="width:175px; height:100px;" >
<img id="logo" alt="Logo" src="../Images/logo.png" style="width: 136px; height: 87px" />
</td>
</tr>
</table >
<table class="hdrtbl2" >
<tr><td id="hdrtbl2td1"><b> Providing Professional Technical, Manangement and Business Solution</b></td></tr>
<tr><td id="hdrtbl2td2"> <b> Services since 2004 </b></td></tr>
<tr> <td id="hdrtbl2td3" align="center" ><img id="rdln" alt="RedLine" style=" height:3px;" src="../Images/RedLine.png" /></td></tr>
<tr><td id="hdrtbl2td4" > <b>Committed to Excellence In All We Do</b></td></tr>
</table>
</div>
<div id="navbardiv">
<ul id="topnav">
<li><a href="../pages/about.aspx" >About Us <img style=" border: none; " src="../Images/arrow-down.gif" /></a>
<!--Subnav Starts Here-->
<span>
<a style="font-weight:lighter; " href="#" >Who We Are </a> |
<a href="#">Locations</a> |
<a href="#">Business Classifications</a> |
<a href="#">Contact Us</a> |
</span>
</li>
<!--Subnav Ends Here-->
<li><a href="../pages/services.aspx">Services <img alt="arrow" style="border: none; " src="../Images/arrow-down.gif" /></a>
<!--Subnav Starts Here-->
<span>
<a style="font-weight:lighter; " href="#" >Capabilities</a> |
</span>
<!--Subnav Ends Here-->
</li>
<li><a href="#">Customers <img style=" border: none; " src="../Images/arrow-down.gif" /></a>
<span>
<a style="font-weight:lighter; " href="#" >Subnav Link</a> |
<a href="#">Customer Locations</a> |
<a href="../pages/labs.aspx">Labs</a> |
</span>
</li>
<li><a href="#">Careers <img style=" border: none; " src="../Images/arrow-down.gif" /></a>
<!--Subnav Starts Here-->
<span>
<a style="font-weight:lighter; " href="#" >Joining the HX5 Team</a> |
<a href="#">Current Opportunities</a> |
</span>
</li>
</ul>
</div>
<div id="subnavbar" >
<!-- <asp:SiteMapPath ID="SiteMapPath" runat="server">
</asp:SiteMapPath> -->
</div>
<div id="topContent" style="border-bottom:solid 1px #191970;">
<table>
<tr><td style="height:30px; width:900px;" >
<asp:ContentPlaceHolder id="TopPlaceHolder" runat="server">
</asp:ContentPlaceHolder>
</td>
</tr>
</table>
</div>
<!-- <div id="mainContent"> -->
<asp:ContentPlaceHolder id="MainPlaceHolder" runat="server" />
<!-- </div> -->
<!-- <div id="lowerContent"> -->
<asp:ContentPlaceHolder id="LowerPlaceHolder" runat="server">
</asp:ContentPlaceHolder>
<!-- </div> -->
<div id="footerContent" style=" height:50px; width:900px; text-align: right; background-color: #ccc; ">
<span style=" font-family: Arial, Helvetica, sans-serif; font-size: xx-small; font-weight: bold; color: #000080; margin: 30px 20px 0px 0px;"> Copyright 2010 HX5, LLC All rights reserved</span></div>
</div>
</form>
</body>
</html>

View 4 Replies

Visual Studio :: Unable To Use Web Deployment MSBuild V10 With AspNetMerge .NET 4

Jul 8, 2010

I am using Web Deployment v10.0 RTW and .NET Framework version 4.0 MSBuild.

There were some problems with incorrect settings and resulting in errors. I had to pass in my own values in order to continue to the next step:

[Code]....

With the above setting, it builds in .NET 4.0 instead of 2.0, but I am having trouble with AspNetMerge:

[Code]....

I was able to solve the above error by changing this inMSBuildMicrosoftWebDeploymentv10.0Microsoft.WebDeployment.targets:

[Code]....

But soon came to another error:

[Code]....

So I changed some more to make it work:

[Code]....

But again hit with another error but this one I can't solve:

(AspNetMerge target) ->

aspnet_merge : error 1008: The PrecompiledApp.config file is missing. Make sure the application has been precompiled with the Aspnet_compiler tool.

View 3 Replies

How To Setup A Development Environment Using Msbuild And Continuious Integration

Jul 6, 2010

I need to set up a developement environment using msbuild and continuious integration, NUnit etc. I am quite new to this kind of thing as it is normally already set up in most environments ive worked in. I am quite short of time as well and dont have have the time to read huge volumes in order to get an understanding (developement starts Monday next week) so need to get this up and running asap in the shortest possible time. Does anyone have a working sample I can utilise or a short tutorial that breaks this process down?

View 1 Replies

Installation :: Include An External Script For Execution In MSBuild.exe?

Mar 3, 2011

I have onle xml file which contain msbuild tags, means few task and I want to execute this file rather then .csproj file.

View 2 Replies







Copyrights 2005-15 www.BigResource.com, All rights reserved