Wednesday, March 30, 2011

Windows XP Run Command List



  1. Accessibility Controls – access.cpl
  2. Accessibility Wizard – accwiz
  3. Add Hardware – Wizardhdwwiz.cpl
  4. Add/Remove Programs – appwiz.cpl
  5. Administrative Tools control – admintools
  6. Adobe Acrobat (if installed) – acrobat
  7. Adobe Designer (if installed)- acrodist
  8. Adobe Distiller (if installed)- acrodist
  9. Adobe ImageReady (if installed)- imageready
  10. Adobe Photoshop (if installed)- photoshop
  11. Automatic Updates – wuaucpl.cpl
  12. Bluetooth Transfer Wizard – fsquirt
  13. Calculator – calc
  14. Certificate Manager – certmgr.msc
  15. Character Map – charmap
  16. Check Disk Utility – chkdsk
  17. Clipboard Viewer – clipbrd
  18. Command Prompt – cmd
  19. Component Services – dcomcnfg
  20. Computer Management – compmgmt.msc
  21. Control Panel – control
  22. Date and Time Properties – timedate.cpl
  23. DDE Shares – ddeshare
  24. Device Manager – devmgmt.msc
  25. Direct X Control Panel (If Installed)- directx.cpl
  26. Direct X Troubleshooter- dxdiag
  27. Disk Cleanup Utility- cleanmgr
  28. Disk Defragment- dfrg.msc
  29. Disk Management- diskmgmt.msc
  30. Disk Partition Manager- diskpart
  31. Display Properties (w/Appearance Tab Preselected)- control color
  32. Display Properties- control desktop
  33. Display Properties- desk.cpl
  34. Dr. Watson System Troubleshooting Utility- drwtsn32
  35. Driver Verifier Utility- verifier
  36. Event Viewer- eventvwr.msc
  37. File Signature Verification Tool- sigverif
  38. Files and Settings Transfer Tool- migwiz
  39. Findfast- findfast.cpl
  40. Firefox (if installed)- firefox
  41. Folders Properties- control folders
  42. Fonts- control fonts
  43. Fonts Folder- fonts
  44. Free Cell Card Game- freecell
  45. Game Controllers- joy.cpl
  46. Group Policy Editor (XP Prof)- gpedit.msc
  47. Hearts Card Game- mshearts
  48. Help and Support- helpctr
  49. HyperTerminal- hypertrm
  50. Iexpress Wizard- iexpress
  51. Indexing Service- ciadv.msc
  52. Internet Connection Wizard- icwconn1
  53. Internet Explorer- iexplore
  54. Internet Properties- inetcpl.cpl
  55. Internet Setup Wizard- inetwiz
  56. IP Configuration (Delete DNS Cache Contents)- ipconfig /flushdns
  57. IP Configuration (Display Connection Configuration) – ipconfi/all
  58. IP Configuration (Display DHCP Class ID)- ipconfig/showclassid
  59. IP Configuration (Display DNS Cache Contents)- ipconfig /displaydns
  60. IP Configuration (Modifies DHCP Class ID)- ipconfig /setclassid
  61. IP Configuration (Release All Connections)- ipconfig /release
  62. IP Configuration (Renew All Connections)- ipconfig /renew
  63. IP Configuration(RefreshesDHCP&Re-RegistersDNS)-ipconfig/registerdns
  64. Java Control Panel (If Installed)- javaws
  65. Java Control Panel (If Installed)- jpicpl32.cpl
  66. Keyboard Properties – control keyboard
  67. Local Security Settings – secpol.msc
  68. Local Users and Groups – lusrmgr.msc
  69. Logs You Out Of Windows – logoff…..
  70. Malicious Software Removal Tool – mrt
  71. Microsoft Access (if installed) – access.cpl
  72. Microsoft Chat – winchat
  73. Microsoft Excel (if installed) – excel
  74. Microsoft Frontpage (if installed)- frontpg
  75. Microsoft Movie Maker – moviemk
  76. Microsoft Paint – mspaint
  77. Microsoft Powerpoint (if installed)- powerpnt
  78. Microsoft Syncronization Tool – mobsync
  79. Microsoft Word (if installed)- winword
  80. Minesweeper Game – winmine
  81. Mouse Properties – control mouse
  82. Mouse Properties – main.cpl
  83. Nero (if installed)- nero
  84. Netmeeting – conf
  85. Network Connections – control netconnections
  86. Network Connections – ncpa.cpl
  87. Network Setup Wizard – netsetup.cpl
  88. Notepad – notepad
  89. Nview Desktop Manager (If Installed)- nvtuicpl.cpl
  90. Object Packager – packager
  91. ODBC Data Source Administrator- odbccp32.cpl
  92. On Screen Keyboard – osk
  93. Opens AC3 Filter (If Installed) – ac3filter.cpl
  94. Outlook Express – msimn
  95. Paint – pbrush
  96. Password Properties – password.cpl
  97. Performance Monitor – perfmon.msc
  98. Phone and Modem Options – telephon.cpl
  99. Phone Dialer – dialer
  100. Pinball Game – pinball
  101. Power Configuration – powercfg.cpl
  102. Printers and Faxes – control printers
  103. Printers Folder – printers
  104. Private Character Editor – eudcedit
  105. Quicktime (If Installed)- QuickTime.cpl
  106. Real Player (if installed)- realplay
  107. Regional Settings – intl.cpl
  108. Registry Editor – regedit
  109. Registry Editor – regedit32
  110. Remote Access Phonebook – rasphone
  111. Remote Desktop – mstsc
  112. Removable Storage – ntmsmgr.msc
  113. Removable Storage Operator Requests – ntmsoprq.msc
  114. Resultant Set of Policy (XP Prof) – rsop.msc
  115. Scanners and Cameras – sticpl.cpl
  116. Scheduled Tasks – control schedtasks
  117. Security Center – wscui.cpl
  118. Services – services.msc
  119. Shared Folders – fsmgmt.msc
  120. Shuts Down Windows – shutdown
  121. Sounds and Audio – mmsys.cpl
  122. Spider Solitare Card Game – spider
  123. SQL Client Configuration – cliconfg
  124. System Configuration Editor – sysedit
  125. System Configuration Utility – msconfig
  126. System File Checker Utility (Purge File Cache)- sfc /purgecache
  127. System File Checker Utility (Return to Default Setting)- sfc /revert
  128. System File Checker Utility (Scan Immediately)- sfc /scannow
  129. System File Checker Utility (Scan On Every Boot) – sfc /scanboot
  130. System File Checker Utility (Scan Once At Next Boot)- sfc /scanonce
  131. System File Checker Utility (Set Cache Size to size x)-sfc/cachesize=x
  132. System Information – msinfo32.
  133. System Properties – sysdm.cpl
  134. Task Manager – taskmgr
  135. Task Manager – taskmgr
  136. TCP Tester – tcptest
  137. Telnet Client – telnet
  138. Tweak UI (if installed) – tweakui
  139. User Account Management- nusrmgr.cpl
  140. Utility Manager – utilman
  141. Windows Address Book – wab
  142. Windows Address Book Import Utility – wabmig
  143. Windows Backup Utility (if installed)- ntbackup
  144. Windows Explorer – explorer
  145. Windows Firewall- firewall.cpl
  146. Windows Magnifier- magnify
  147. Windows Management Infrastructure – wmimgmt.msc
  148. Windows Media Player – wmplayer
  149. Windows Messenger – msmsgs
  150. Windows Picture Import Wizard (need camera connected)- wiaacmgr
  151. Windows System Security Tool – syskey
  152. Windows Update Launches – wupdmgr
  153. Windows Version (to show which version of windows)- winver
  154. Windows XP Tour Wizard – tourstart
  155. Wordpad – write

Tuesday, March 29, 2011

GRID VIEW BINDING WITH TEMPLATE FIELDS DYNAMICALLY - ASP.NET with C#


using System;
using System.Web.UI.WebControls;
using System.Data;
using System.Web.UI;

namespace SomeName.Classes
{
    public class GridViewTemplate : ITemplate
    {
        private DataControlRowType templateType;
        private string columnName;
        private string columnNameBinding;
        private string controlType;
        private int ctrllength;

        public GridViewTemplate(DataControlRowType type, string colname, string colNameBinding, string ctlType,int length)
        {
            templateType = type;
            columnName = colname;
            columnNameBinding = colNameBinding;
            controlType = ctlType;
            ctrllength = length;
        }

        public void InstantiateIn(System.Web.UI.Control container)
        {
            switch (templateType)
            {
                case DataControlRowType.Header:
                    Literal lc = new Literal();
                    lc.Text = columnName;
                    container.Controls.Add(lc);
                    break;
                case DataControlRowType.DataRow:
                    if (controlType == "Label")
                    {
                        Label lb = new Label();

                        lb.ID = "lbl_" + columnNameBinding;
                        lb.DataBinding += new EventHandler(this.ctl_OnDataBinding);
                        container.Controls.Add(lb);
                    }
                    else if (controlType == "TextBox")
                    {
                        TextBox tb = new TextBox();
                        tb.ID = "tb" + columnNameBinding;
                        tb.DataBinding += new EventHandler(this.ctl_OnDataBinding);
                        tb.Width = ctrllength;
                        container.Controls.Add(tb);
                    }
                    else if (controlType == "CheckBox")
                    {
                        CheckBox cb = new CheckBox();
                        cb.ID = "cb1" + columnNameBinding;
                        cb.DataBinding += new EventHandler(this.ctl_OnDataBinding);
                        container.Controls.Add(cb);
                    }
                    else if (controlType == "HyperLink")
                    {
                        HyperLink hl = new HyperLink();
                        hl.ID = "hl1";
                        hl.DataBinding += new EventHandler(this.ctl_OnDataBinding);
                        container.Controls.Add(hl);
                    }
                    else if (controlType == "HiddenField")
                    {
                        HiddenField hf = new HiddenField();
                        hf.ID = "hf" + columnNameBinding;
                        hf.DataBinding += new EventHandler(this.ctl_OnDataBinding);
                        container.Controls.Add(hf);
                    }
                    break;
                default:
                    break;
            }
        }

        public void ctl_OnDataBinding(object sender, EventArgs e)
        {
            if (sender.GetType().Name == "Label")
            {
                Label lb = (Label)sender;
                GridViewRow container = (GridViewRow)lb.NamingContainer;
                lb.Text = ((DataRowView)container.DataItem)[columnNameBinding].ToString();
            }
            else if (sender.GetType().Name == "TextBox")
            {
                TextBox tb = (TextBox)sender;
                GridViewRow container = (GridViewRow)tb.NamingContainer;
                tb.Text = ((DataRowView)container.DataItem)[columnNameBinding].ToString();
            }
            else if (sender.GetType().Name == "CheckBox")
            {
                CheckBox cb = (CheckBox)sender;
                GridViewRow container = (GridViewRow)cb.NamingContainer;
                cb.Checked = Convert.ToBoolean(((DataRowView)container.DataItem)[columnNameBinding].ToString());
            }
            else if (sender.GetType().Name == "HyperLink")
            {
                HyperLink hl = (HyperLink)sender;
                GridViewRow container = (GridViewRow)hl.NamingContainer;
                hl.Text = ((DataRowView)container.DataItem)[columnNameBinding].ToString();
                hl.NavigateUrl = ((DataRowView)container.DataItem)[columnNameBinding].ToString();
            }
            else if (sender.GetType().Name == "HiddenField")
            {
                HiddenField hf = (HiddenField)sender;
                GridViewRow container = (GridViewRow)hf.NamingContainer;
                hf.Value  = ((DataRowView)container.DataItem)[columnNameBinding].ToString();
            }
        }
    }
}
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
///////////////Place the above class seperately and
//////////////Use the Following code in aspx.cs,
///////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
 string strColName="Some DaField Column Name";
                string strColLabel = "Header text";
  TemplateField tField = new TemplateField();
                tField.HeaderText = strColLabel;
                tField.HeaderTemplate = new GridViewTemplate(DataControlRowType.Header, strColLabel, strColName, "", 0);
                if (Some Condition) 
                    tField.ItemTemplate = new GridViewTemplate(DataControlRowType.DataRow, "", strColName, "Label", 100);
                else
                    tField.ItemTemplate = new GridViewTemplate(DataControlRowType.DataRow, "",strColName, "TextBox", 100);
                grdMapValues.Columns.Add(tField);
            }
            if (dtMapData.Rows.Count > 0)
            {               
                grdMapValues.DataSource = dtMapData;              
                grdMapValues.DataBind();
            }

///////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
///////////In Code Behind, the Gridview is like this
//////////////////////////////////////////////////////////////////////////////////////////////////////////////////////


<asp:GridView ID="grdname" runat="server"
 CssClass="GridStyle" ShowHeader="true" AutoGenerateColumns="false">
   <Columns>
    <asp:TemplateField><ItemTemplate></ItemTemplate></asp:TemplateField>
   </Columns>
</asp:GridView>