Wednesday, July 12, 2017

Install/Uninstall windows service manually


To uninstall your service manually

  1. Windows Start menu or Start screen, choose Visual StudioVisual Studio ToolsDeveloper Command Prompt.
  2. Go to your service project folder
  3. Find the service exe
  4. command: installutil /u <yourproject>.exe  

To install your service manually


  1. Windows Start menu or Start screen, choose Visual StudioVisual Studio ToolsDeveloper Command Prompt.
  2. Go to your service project folder
  3. Find the service exe
  4. command: installutil <yourproject>.exe  

Sunday, July 9, 2017

Add Trace to SP

declare @tracedata varbinary(8000);
SET @tracedata = cast(@EncCCNumber AS varbinary(8000));
EXEC sp_trace_generateevent 82,
N'@EncCCNumber',
@tracedata ;

SET @tracedata = cast(@Token as varbinary(8000));
EXEC sp_trace_generateevent 82,
N'@Token',
@tracedata;

Wednesday, June 28, 2017

CSS bundleconfig doesn't work in asp.net mvc?

When using Bundle, do not append the .min

bundles.Add(new StyleBundle("~/Content/bootstrap").Include(
    "~/Content/bootstrap.css", 
    "~/Content/bootstrap-theme.css"));
Based on the debug setting, (mostly web.config)
  • debug="true" - the non minified version will be used.
  • debug="false" - *.min.css will be searched, and if not found, the current will be minified
web.config setting:

<system.web>
  <compilation debug="true"...

Ref: https://stackoverflow.com/questions/20869907/adding-bootstrap-in-bundleconfig-doesnt-work-in-asp-net-mvc