WebMatrix 3 intellisense and publishing - intellisense

Does WebMatrix 3 support intellisense for css libs you add or a customer css file you create? For me this doesn't work. It would be nice to have intellisense when using say twitter bootstrap for instance.
I cannot figure out why when I publish sometimes it selects only the files I've changed but most of the time it seems to publish everything. Why does this happen?
Thanks

I had problems with publish too so I don't recommend using the publish feature in Webmatrix. I recommend that you copy it directly like this; Right click the app directory in IIS and select "Remove" then just copy and paste the entire project directory from your local machine up to the IIS inetpub/wwroot directory. Then from within IIS7 right click that directory and select "Convert to Application". Works every time.

Related

Publishing web app from Visual Studio doesn't update views

I'm trying to publish changes to a .NET Core 3.1 web app from Visual Studio 2019 using FTP, however the process doesn't update my .cshtml views.
The app works properly on my local machine, I deleted the contents of the 'bin' directory before publishing, and my publish settings delete all of the existing files on the server before copying new ones over, so this process appears to be somehow copying over views which are no longer available anywhere?! I've not changed any of the 'build action' properties and most of the configuration in Startup is the default MVC template.
Microsoft docs reference a NuGet package (Microsoft.AspNetCore.Mvc.Razor.RuntimeCompilation) and using AddRazorRuntimeCompilation() in Startup, but this didn't seem to have any effect.
I find it incredibly bizarre that views aren't updated during a publish by default. I also find it bizarre that in this day and age SFTP appears to be unsupported (wth). Hopefully I'm just doing something wrong rather than this process being silly. Any ideas?
Restarting the Kestrel service used by my server seems to have resolved it...there has to be a more obvious solution though as this method requires shell access.

How to disable local data cache in Windows Form?

I have a vb.net Windows Form that is launched from the .application file - no installing done. I have an issue on some users' machines where they can't launch the application unless they go into their C:\Users\%userprofile%\local settings\apps\ folder and delete folder "2.0".
How can I prevent the application from using/creating that cache? All user settings are stored server-side and pulled down on open.
I've found AN answer, maybe not the best, but it works.
Turns out, ClickOnce is the problem. I haven't been able to figure out how to deploy without it, however it can be bypassed. Within the deployment folder, you've got an Application Files folder, and a [Project Name]_[version] folder. Within that is the .exe for your application, within the ClickOnce wrapper.
If your application, like mine, doesn't use non built-in controls, you don't actually need ClickOnce, as far as I can tell. So having users run that .exe, rather than the .application file within the deployment folder will prevent the "2.0" cache folder, as well as preventing the ClickOnce install and loading form - resulting in a faster open.
Hope that helps someone.

Deploying a web app via TFS2010 only copies certain folders, not all folders, to our development server

My company uses TFS 2010 to deploy our web apps from our local environment to our development environment. Here's the compiled output in my local directory for one of our vended web apps, ProGet, (http://inedo.com/proget/overview) in question that isn't deploying correctly. I expect all of what I see below to deploy to our development server:
Here's my .xaml build file:
Finally, here's my solution in Visual Studio:
When I queue the build, this is what's built out to our development server - notice it's missing a bunch of files/folders, but it does include "Resources" and "bin" and web.config:
This app is a vended application, ProGet, an already developed corporate Nuget repository that we purchased a source code license for. Does anyone have any ideas what I might be doing wrong?
EDIT
Here's a screenshot of my local IIS and the window to the right is a result of right clicking the website and choosing "Explore". Notice the *.cs files. Weird they don't compile down.
The Default Build Template (DefaultTemplate.xaml) should output the same files you get when you compile locally.
However, from your screenshots it looks like you are using a custom build template xxxx_DeploymentProcess.xaml that is obviously doing something different with how it outputs the build files. There is no way for us (stackoverflow community) to know what your custom build process is doing.
You could try switching back to the default template, and we'd be able to help you then. But, there's a good chance that you are using a custom build template for a reason, and you might not want to eliminate it before you know what it's doing.

Using DLL for web project

I am a little new to VB.NET but I have downloaded and installed VS Express 2012 for web. I created a web application that is fairly simple. One page. mypage.aspx It runs perfect in studio and responses how I would expect.
What I want to do is make it run from the dll. Not from the mypage.aspx.vb. I see the dll for the project in the bin folder.
But when I move mypage.aspx and web.config, and bin with dll to the server it simply says its missing the code behind page. Do I just need to change the reference to the VB file?
If you want to use dll, Go to Build menu in your Visual Studio and click on Publish Web Site
Set Target Location, there your whole project will be get created with dll and without code behind files.
Use this project to deploy on your server.

What effect does the new precompile during publishing option have on MVC4 applications?

So I recently updated Visual Studio 2012 to Update 2. Lo and behold, the next time I go to publish my application (via File Publish in this case) I notice that there are three new options:
Delete all existing files prior to publish
Precompile during publishing (with a link to Configure)
Exclude files from the App_Data folder
The first and third options are pretty self-explanatory, but I can't find any documentation on the second option as it applies to MVC. When I check it, there doesn't seem to be any change in the files produced on the site and I don't see any real change in performance.
Using the ASP.NET precompiler can have the following impact on your MVC app:
If you have anything in App_Code, it will be precompiled into a DLL before deployment. Without precompiling, this would happen on the fly by the ASP.NET runtime.
If you choose the option to not make your pages updateable (i.e. uncheck the first checkbox in the advanced settings dialog), it will also precompile your views (ASPX and Razor) instead of compiling those dynamically at runtime as well. The default (checked) setting of "Allow precompiled site to be updateable" allows you to update your view content without needing to rebuild the entire project.
If you don't have any files in App_Code and you want your site to remain updateable, it doesn't seem to do much.
It is an old question, but I just encounter similar issue and feel something worth sharing.
My error message is same in this post. My project is MVC5, build with Visual Studio 2013 professional.
Compilation Error: The type 'ASP.global_asax' exists in both DLLs
In my case, with precompile option, there is a file, App_global.asax.dll, in bin folder, and cause above error message.
First, I remove App_global.asax.dll on server, restart application pool, issue is gone.
Then I tried another approach, uncheck precompile and republish, redeploy to server, issue is gone.