Tuesday, December 29, 2015
How to add command to crystal report
under data tab
on the right side, select my connections, the sql db, then click on add command, then click on ">" button. It will prompt "Add Command to report" window.
Then you add SQL and Parameter
after you finish, if pass the syntax check, then you get it back to the Database Expert window, then you have to right mouse click on the "Command" to view the options to Edit, View or add to repository.
If you have two commands, then you have to link then using the link tab.
Visual studio view crystal report field explorer
Go to view, other windows, document outline
Thursday, December 17, 2015
Tuesday, December 15, 2015
Monday, December 14, 2015
configuration transform extension for app config file
https://visualstudiogallery.msdn.microsoft.com/579d3a78-3bdd-497c-bc21-aa6e6abbc859/view/Reviews/0?showReviewForm=True
Wednesday, December 9, 2015
Common Web.Config transformations with Visual Studio 2010
First, A Tiny Iota (That guy was great!) of XDT Review
- Transform: What you want to do with the XML element
- You might want to Replace it, set an attribute (SetAttribute), remove an attribute (RemoveAttribute), etc.
- Locator: Where is the element that needs transformation?
- You probably want to transform an element that matches (Match) a specific attribute value
Case 1: Replacing all AppSettings
<appSettings>
<add key="KeyA" value="ValA"/>
<add key="KeyB" value="ValB"/>
</appSettings>
<appSettings xdt:Transform="Replace">
<add key="ProdKeyA" value="ProdValA"/>
<add key="ProdKeyB" value="ProdValB"/>
<add key="ProdKeyC" value="ProdValC"/>
</appSettings>
<appSettings>
<add key="ProdKeyA" value="ProdValA"/>
<add key="ProdKeyB" value="ProdValB"/>
<add key="ProdKeyC" value="ProdValC"/>
</appSettings>
Case 2: Replacing a specific AppSetting’s value
<appSettings>
<add key="KeyA" value="ValA"/>
<add key="KeyB" value="ValB"/>
</appSettings>
<appSettings>
<add key="KeyB" value="ProdValA" />
</appSettings>
<appSettings>
<add key="KeyB" value="ProdValA" xdt:Transform="Replace" xdt:Locator="Match(key)" />
</appSettings>
<appSettings>
<add key="KeyA" value="ValA"/>
<add key="KeyB" value="ProdValA"/>
</appSettings>
Case 3: Replace Compilation Debug=”true”
<system.web>
<compilation xdt:Transform="RemoveAttributes(debug)" />
</system.web>
To Infinity – And Beyond
find out pdf file size
Tuesday, December 8, 2015
how do I format SQL in SQuirrel?
Monday, December 7, 2015
Asp.net javascript read application settings
Thursday, December 3, 2015
avascript Function Declaration vs Function expressions
Tuesday, December 1, 2015
Wednesday, November 25, 2015
“Micro-libraries”: the future of front-end development?
Sunday, November 22, 2015
Dual boot
http://mac-how-to.wonderhowto.com/how-to/dual-boot-windows-10-mac-os-x-your-mac-0162616/
Thursday, November 19, 2015
Jslint
Code quality tool for javascript
Wednesday, November 18, 2015
How do you auto format code in visual studio?
Tuesday, November 17, 2015
Pd4ml pdf rendering missing images
If pd4ml could not get image files from an URL, then check IIS server
Monday, November 16, 2015
Javascript book
http://eloquentjavascript.net/
Javascript interview
http://www.toptal.com/javascript/interview-questions
IIS log location
%SystemDrive%\inetpub\logs\LogFiles
http://stackoverflow.com/questions/6426375/where-can-i-find-the-iis-logs
http://programming4.us/website/3684.aspx
Thursday, November 12, 2015
jquery.blockUI.js blockUI
The difference between + and & for joining strings in VB.NET
There's no difference if both operands are strings. However, if one operand is a string, and one is a number, then you run into problems,
Thursday, November 5, 2015
Wednesday, November 4, 2015
IIS Express authentication changes
select project and press F4
Friday, October 30, 2015
if CSS style sheet changed
http://stackoverflow.com/questions/2263096/css-file-is-not-refreshing-in-my-browser
<link rel="stylesheet" type="text/css" href="styles.css?version=51">
Tuesday, October 27, 2015
run asm on visual studio
http://www.cs.virginia.edu/~evans/cs216/guides/x86.html
Wednesday, October 21, 2015
IIS relative path
<img src="Images/logo.png">
if web site setup on virtual directory, you can use web browser F12 key console to see if it can load image file. 'Images" is a folder in the VS project directory,
below dose not work:
img src="../images/logo.png"
img src="/images/log.png"
img src="../../images/log.png"
below worked:
img src="Images/logo.png"
img src="./Images/logo.png"
Friday, October 2, 2015
Assign value to session
Session(Util.ATTR_FORM_XML) = xml
Session(Util.ATTR_FORMNAME) = New Forms.xxx.xxx(xml)
Session(Util.ATTR_FORM_XKEY) = xKey
Response.Redirect("./formx.aspx?app=forms")
Thursday, October 1, 2015
The Road to Angular 2.0 part 6: Migration
Tuesday, September 22, 2015
Wednesday, September 16, 2015
facebook react
IE logged in user id could not pass to the link web page triggered from the parent page
Monday, September 14, 2015
Notepad
http://www.technipages.com/add-reminder-notes-to-android-home-screen
Tuesday, September 8, 2015
The URL 'http://localhost:port#/' for Web project 'xxx' is configured to use IIS as the web server but the URL is currently configured on the IIS Express web server.
http://rickgaribay.net/archive/2012/11/08/the-url-x-for-web-project-y-is-configured-to.aspx
To fix the above following section must be in project file.
<ProjectExtensions>
<VisualStudio>
<FlavorProperties GUID="{349c5851-65df-11da-9384-00065b846f21}">
<WebProjectProperties>
<UseIIS>False</UseIIS>
<AutoAssignPort>True</AutoAssignPort>
<DevelopmentServerPort>51854</DevelopmentServerPort>
<DevelopmentServerVPath>/</DevelopmentServerVPath>
<IISUrl>
</IISUrl>
<NTLMAuthentication>False</NTLMAuthentication>
<UseCustomServer>False</UseCustomServer>
<CustomServerUrl>
</CustomServerUrl>
<SaveServerSettingsInUserFile>False</SaveServerSettingsInUserFile>
</WebProjectProperties>
</FlavorProperties>
</VisualStudio>
</ProjectExtensions>
Friday, September 4, 2015
Angular js Web Api problem solver
blogs.msmvps.com/deborahk/angular-front-to-back-with-web-api-problem-solver/
Monday, August 31, 2015
Angular JS testing
E2E testing - Protractor
Friday, August 28, 2015
Angular js mistakes
https://www.airpair.com/angularjs/posts/top-10-mistakes-angularjs-developers-make
Microsoft report viewer
Thursday, August 27, 2015
registry change to open GAC
- Launch regedit.
- Navigate to HKLM\Software\Microsoft\Fusion
- Add a DWORD called DisableCacheViewer and set the value to 1.
Wednesday, August 26, 2015
asp.net and crystal reports
Asp.net virtual path
http://www.codeproject.com/Articles/723668/ASP-Net-How-to-map-virtual-path-to-physical-path
Tuesday, August 25, 2015
upgrade to .net 4.5 Iframe issue
<asp:HtmlIframe>
System.Web.UI.HtmlControls.HtmlIframe
<controls>
<add tagPrefix="asp" namespace="System.Web.UI.HtmlControls" assembly="System.Web"/>
</controls>
Monday, August 24, 2015
cannot-assign value to member xxx it does not define a setter
Friday, August 21, 2015
webpack vs browserify
Return of false for onkeypress event no longer blocks input
http://forums.asp.net/t/1118932.aspx?Return+of+false+for+onkeypress+event+no+longer+blocks+input
Return of false for onkeypress event no longer blocks input
Thursday, August 20, 2015
refresh css need to use crtl-f5
Tuesday, August 18, 2015
Source tree - can't commit after starting a merge
Sourctree errors - Could not update one or more files, please check that no other application is locking your files
Wednesday, August 12, 2015
Wednesday, August 5, 2015
Code review hosting
Branch
then click on branch on the tool bar under file menu bar to create a branch
modify then commit, (then if want to patch then click on "" to do patch)
after commit then do push
select the push from and the remote want to push to
Tuesday, August 4, 2015
Wednesday, July 29, 2015
Lexus will officially unveil its hoverboard on August 5th
Tuesday, July 28, 2015
Unrecognized attribute 'targetFramework'. Note that attribute names are case-sensitive
Check the .NET version of Application pool in IIS. If application pool is running on .NET version 2 and the web.Config file specify .Net version 4, you get this error.
Note this may not be the only cause for your error. But check this.
How to enable assembly bind failure logging (Fusion) in .NET
Windows Registry Editor Version 5.00
[HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Fusion]
"ViewerAttributes"=dword:56300949
"ForceLog"=dword:00000001
"LogFailures"=dword:00000001
"LogResourceBinds"=dword:00000001
"LogPath"="D:\\Logs\\bind\\"
"EnableLog"=dword:00000001
Monday, July 27, 2015
Show visual studio output window
ASP.NET Web Deployment using Visual Studio: Deploying to Test
Saturday, July 25, 2015
Wiwo-s20
Wiwo-s20
http://www.cnx-software.com/2014/07/31/orvibo-wiwo-s20-wi-fi-smart-socket-features-us-eu-uk-or-au-plug-types/
Friday, July 24, 2015
SourceTree tutorial
pull down rep
stages files (ready to go file)
commit , snapshot of staged file
then push to master
https://www.youtube.com/watch?v=srXdUml4_HM
git for age 4 and up
https://www.youtube.com/watch?v=3m7BgIvC-uQ
https://answers.atlassian.com/questions/244429/unknown-user-in-sourcetree
git config --global user.name
"Jennifer Connor"
git config --global user.email
"your@email.com"
Sunday, July 19, 2015
ipad
iPad air with 64 GB memory, protect jackket, key board for sell.
Model MD790LL/A
Amazon link Amazon price $525, sell price $349
Rugged Tough Jacket Amazon price $67.76, sell price $39
Keyboard Amazon price $54.99, sell price $29
Please contact me if you are interested. I work at IT department. Swiching to Microsoft Surface Pro 3, so no longer need this device.
|
Saturday, July 18, 2015
change actionlink color
@Html.ActionLink("Details", "Details", new { _id = item._id }, new { style = "color: #000"}) |
@Html.ActionLink("Register", "Register", new { _id = item._id }, new { style = "color: #000" })
</td>
</tr>
Wednesday, July 15, 2015
Unable to retrieve NT credentials. Make sure 'Anonymous Access' is disabled within IIS.
<authentication>
<anonymousAuthentication enabled="false" userName="" />
<basicAuthentication enabled="true" />
<clientCertificateMappingAuthentication enabled="false" />
<digestAuthentication enabled="false" />
<iisClientCertificateMappingAuthentication enabled="false">
</iisClientCertificateMappingAuthentication>
<windowsAuthentication enabled="false">
<providers>
<add value="Negotiate" />
<add value="NTLM" />
</providers>
</windowsAuthentication>
</authentication>
Monday, July 13, 2015
Friday, July 10, 2015
VB.net Why reference not showing up?
Reason being the DLL was compiled to framework 4.5.2 and my project is 4.5.0, so that's the reason why it does not see it.
Thursday, July 9, 2015
.webinfo file needed when Can't open my VS2003 project: The project you are trying to open is a Web project. You need...
Re: Can't open my VS2003 project: The project you are trying to open is a Web project. You need...
To fix this error all you need to do is add a webinfo file. If your using VSS for source control, it's probably a good idea to add the webinfo file to SourceSafe as well as this is not done for you automatically.If you have a project file c:\Inetpub\wwwroot\Folder\fred.csproj then you need a corresponding webinfo file fred.csproj.webinfo. The contents of the webinfo file looks like this:<VisualStudioUNCWeb><Web URLPath = "http://localhost/Folder/fred.csproj" /></VisualStudioUNCWeb>When you go to add this web project to your solution file you actually don't specify “Add Existing Project From Web”, but simply “Add Existing Project”, then browse to c:\Inetpub\wwwroot\Folder\fred.csproj
Visual studio 2013 missing convert to web application
Rest soap
[BasicHttpBinding = Soap 1.1], [WsHttpBinding = Soap 1.2], [WebHttpBinding = Rest] – Frank Myat Thu May 19 '14 at 4:49
SetSite failed for package [JavaScriptWebExtensionsPackage]
Depends on which version of visual studio
C:\Users\[user]\AppData\Roaming\Microsoft\VisualStudio\1x.0\ActivityLog.xml
In order to fix the issue one needs to clear the VS cache under:
%LOCALAPPDATA%\Microsoft\VisualStudio\1x.0\ComponentModelCache
Wednesday, July 8, 2015
Replace code one line with multiple lines
Tuesday, June 30, 2015
Friday, June 26, 2015
Thursday, June 25, 2015
ERROR: Failed to backup website http://localhost
just delete that project from solution and added it back from the correct file folder.
Wednesday, June 24, 2015
Troubleshooting 503 "service unavailable" errors
Saturday, June 20, 2015
Friday, June 19, 2015
Fix MHT if missing two "-" at the end of file
Sub Main()
Dim inputfile As String = "c:\6.mht"
FixMht(inputfile)
End Sub
Private Sub FixMht(ByVal tempFileName As String)
Dim all As String = File.ReadAllText(tempFileName)
Dim last As Integer = all.LastIndexOf("------=_NextPart_000_00")
Dim newall As String = all.Remove(last)
Dim builder As New StringBuilder
builder.Append(newall)
builder.Append("------=_NextPart_000_00--")
File.WriteAllText(tempFileName, builder.ToString, Encoding.UTF8)
End Sub
Tuesday, June 16, 2015
Execl can not take one ', you have to use two ''
Tuesday, June 9, 2015
Control space bar
Type db.
Then control space bar
Monday, June 8, 2015
DB2 SQL needs less than 80 characters for mainframe FTP whatever
Imports System.IO
Module Module1
Sub Main()
'Dim inputfile As String = "c:\aurorasql.txt"
'Dim outputfile As String = "c:\out.txt"
Dim inputfile As String = "c:\printer.txt"
Dim outputfile As String = "c:\outprinter.txt"
' split SQL statement into less than length 80
' first separate by ","
' the first line has SQL command "insert" and it is default lenght is less than 80 so no need of comma
' others than need comma
Using sw As StreamWriter = New StreamWriter(outputfile, True)
For Each line As String In File.ReadLines(inputfile)
'Console.WriteLine(line)
Dim len = 80
Dim arr = line.Split(",")
For Each Str As String In arr
If Str.Length > 80 Then
sw.Write(",")
Dim arr1 = Str.Split(" ")
Dim str2 As String = String.Empty
For Each str1 As String In arr1
str2 = str2 & str1 & " "
If str2.Length > 70 Then 'this is just make sure total is less than 80
sw.WriteLine(str2)
str2 = String.Empty
End If
Next
sw.WriteLine(str2)
str2 = String.Empty
Else
If Str.Contains("INSERT") Then
sw.WriteLine(Str)
Else
sw.WriteLine(" ," & Str)
End If
End If
Next
Next
End Using
Console.WriteLine("done")
End Sub
End Module
Saturday, June 6, 2015
SPA examples
http://jaliyaudagedara.blogspot.com/2014/06/creating-empty-aspnet-project-powered.html?m=1
Friday, June 5, 2015
Friday, May 29, 2015
Angular js filters
Ng-repeat | orderby 'field name'
$scope.sortorder
You can use a drop down list
So user
Thursday, May 28, 2015
unit test private methods by creating private accessor
- Goto the class definition's source code
- Right-click on the name of the class
- Choose "Create Private Accessor"
- Choose the project in which the accessor should be created => You will end up with a new class with the name foo_accessor. This class will be dynamically generated during compilation and privides all members public available.
// Wrap an already existing instance
PrivateObject accessor = new PrivateObject( objectInstanceToBeWrapped );
// Retrieve a private field
MyReturnType accessiblePrivateField = (MyReturnType) accessor.GetField( "privateFieldName" );
// Call a private method
accessor.Invoke( "PrivateMethodName", new Object[] {/* ... */} );
The author name and e-mail is configured in Tools -> Options -> General.
In Repository -> Repository Settings -> Advanced it does not matter if 'Use global user settings' is checked or not.