25 December, 2012

Maximum characters of varchar max in sql server

Maximum 2^31-1 byte (2GB).

[2,147,483,647] Character

1 character = 1 byte


Variable-length, non-Unicode string data. n defines the string length and can be a value from 1 through 8,000. max indicates that the maximum storage size is 2^31-1 bytes (2 GB). The storage size, in bytes, is the value of the actual data entered + 2 bytes. The ISO synonyms for varchar are char varying or character varying.

Ref:

15 December, 2012

Remove Scrollbar from Textarea in IE

By default all versions of IE have a scrollbar on textareas, even when they are empty.









No other browsers do this, so if you want to remove it so IE can visually match other browsers, just:

textarea { overflow: auto; }

The scrollbar will return (rightfully) when the text in the textarea expands beyond it's bounds.








soruce:
http://css-tricks.com/snippets/css/remove-scrollbar-from-textarea-in-ie/

13 December, 2012

Disable Process Attach Warning in Visual Studio 2010

Problem:

We often debugging and we need to attach process like w3wp.exe, service process or any process in visual studio.Visual studio every time asks warning like "Attaching to this process can potentially harm your computer. If the information below looks suspicious or your are unsure, do not attach to this process."



We know that this process is not harmful and we want to disable that warning right?

Solution:

1. Close all instances of visual studio.
2. Update registry value:

HKEY_CURRENT_USER\Software\Microsoft\VisualStudio\10.0\Debugger
And set the value DisableAttachSecurityWarning to 1
OR
if you don't want to find registry and update value manually then just download this registry file from here and just open this file.