How to Check if jQuery is loaded

by ebarcza 1/25/2013 1:10:00 PM
function testScript() {
  alert('test');
  if (jQuery) {  
    // jQuery is loaded  
    alert('loaded');
  } else {
    // jQuery is not loaded
    alert('not loaded');
  }
    $("#MSDS").show();
   
}

Tags:

Umbraco make Rich Text Editor bigger

by ebarcza 1/25/2013 10:21:00 AM
Go to the developer section, and select the richtext datatype. There you can edit the available features of the text editor as well as setting the width and height.

Tags:

Umbraco

.NET State DropDown

by ebarcza 1/22/2013 5:04:00 PM
   1:  <asp:DropDownList id="ddlStates" runat="server">
   2:  <asp:ListItem Value="">-- Select --</asp:ListItem>
   3:  <asp:ListItem Value="AL">Alabama</asp:ListItem>
   4:  <asp:ListItem Value="AK">Alaska</asp:ListItem>
   5:  <asp:ListItem Value="AZ">Arizona</asp:ListItem>
   6:  <asp:ListItem Value="AR">Arkansas</asp:ListItem>
   7:  <asp:ListItem Value="CA">California</asp:ListItem>
   8:  <asp:ListItem Value="CO">Colorado</asp:ListItem>
   9:  <asp:ListItem Value="CT">Connecticut</asp:ListItem>
  10:  <asp:ListItem Value="DC">District of Columbia</asp:ListItem>
  11:  <asp:ListItem Value="DE">Delaware</asp:ListItem>
  12:  <asp:ListItem Value="FL">Florida</asp:ListItem>
  13:  <asp:ListItem Value="GA">Georgia</asp:ListItem>
  14:  <asp:ListItem Value="HI">Hawaii</asp:ListItem>
  15:  <asp:ListItem Value="ID">Idaho</asp:ListItem>
  16:  <asp:ListItem Value="IL">Illinois</asp:ListItem>
  17:  <asp:ListItem Value="IN">Indiana</asp:ListItem>
  18:  <asp:ListItem Value="IA">Iowa</asp:ListItem>
  19:  <asp:ListItem Value="KS">Kansas</asp:ListItem>
  20:  <asp:ListItem Value="KY">Kentucky</asp:ListItem>
  21:  <asp:ListItem Value="LA">Louisiana</asp:ListItem>
  22:  <asp:ListItem Value="ME">Maine</asp:ListItem>
  23:  <asp:ListItem Value="MD">Maryland</asp:ListItem>
  24:  <asp:ListItem Value="MA">Massachusetts</asp:ListItem>
  25:  <asp:ListItem Value="MI">Michigan</asp:ListItem>
  26:  <asp:ListItem Value="MN">Minnesota</asp:ListItem>
  27:  <asp:ListItem Value="MS">Mississippi</asp:ListItem>
  28:  <asp:ListItem Value="MO">Missouri</asp:ListItem>
  29:  <asp:ListItem Value="MT">Montana</asp:ListItem>
  30:  <asp:ListItem Value="NE">Nebraska</asp:ListItem>
  31:  <asp:ListItem Value="NV">Nevada</asp:ListItem>
  32:  <asp:ListItem Value="NH">New Hampshire</asp:ListItem>
  33:  <asp:ListItem Value="NJ">New Jersey</asp:ListItem>
  34:  <asp:ListItem Value="NM">New Mexico</asp:ListItem>
  35:  <asp:ListItem Value="NY">New York</asp:ListItem>
  36:  <asp:ListItem Value="NC">North Carolina</asp:ListItem>
  37:  <asp:ListItem Value="ND">North Dakota</asp:ListItem>
  38:  <asp:ListItem Value="OH">Ohio</asp:ListItem>
  39:  <asp:ListItem Value="OK">Oklahoma</asp:ListItem>
  40:  <asp:ListItem Value="OR">Oregon</asp:ListItem>
  41:  <asp:ListItem Value="PA">Pennsylvania</asp:ListItem>
  42:  <asp:ListItem Value="RI">Rhode Island</asp:ListItem>
  43:  <asp:ListItem Value="SC">South Carolina</asp:ListItem>
  44:  <asp:ListItem Value="SD">South Dakota</asp:ListItem>
  45:  <asp:ListItem Value="TN">Tennessee</asp:ListItem>
  46:  <asp:ListItem Value="TX">Texas</asp:ListItem>
  47:  <asp:ListItem Value="UT">Utah</asp:ListItem>
  48:  <asp:ListItem Value="VT">Vermont</asp:ListItem>
  49:  <asp:ListItem Value="VA">Virginia</asp:ListItem>
  50:  <asp:ListItem Value="WA">Washington</asp:ListItem>
  51:  <asp:ListItem Value="WV">West Virginia</asp:ListItem>
  52:  <asp:ListItem Value="WI">Wisconsin</asp:ListItem>
  53:  <asp:ListItem Value="WY">Wyoming</asp:ListItem>
  54:  </asp:DropDownList>

Tags:

SQL script to enable or disable trigger

by ebarcza 1/17/2013 6:41:00 AM

If you try and follow the documentation provided by Microsoft to enable/disable a trigger you'll end up with this error:

ENABLE TRIGGER triggerName
Incorrect syntax near 'triggerName'.


The following code will work, at least it does on SQL 2008:
ALTER TABLE dbo.tblApp ENABLE TRIGGER trgInsApp
Or, To disable
ALTER TABLE dbo.tblApp DISABLE TRIGGER trgInsApp

Tags: ,

Report Viewer - 404 Error - File or directory not found

by ebarcza 1/11/2013 11:01:00 AM
When utilizing ASP.NET Report Viewer you may receive a 404 File or directory not found error. This is because the managed handler is missing in IIS for the domain serving your .NET application.

To resolve this issue:

  1. Open IIS 7 or 7.5
  2. Select the site to modify by double clicking, revealing all options.
  3. Double click on Handler Mappings
  4. Click Add Managed Handler
  5. Request path: Reserved.ReportViewerWebControl.axd
  6. Type: Microsoft.Reporting.WebForms.HttpHandler
  7. Name: Reserved-ReportViewerWebControl-axd
  8. Click OK to complete


Refresh the application or web page using the Report Viewer, it should work properly now.

Tags:

SQL Server Reporting Services

RadcomboBox type ahead

by ebarcza 1/7/2013 2:07:00 PM

Set the MarkFirstMatch property to true

<telerik:RadComboBox ID="rcbPOC1" runat="server" EmptyMessage="Select Contact" MarkFirstMatch="true">
                                                                        
</telerik:RadComboBox>

Tags:

Powered by BlogEngine.NET 1.5.0.7
Theme by Mads Kristensen

About the author

Name of author Author name
Something about me and what I do.

E-mail me Send mail

Calendar

<<  November 2017  >>
MoTuWeThFrSaSu
303112345
6789101112
13141516171819
20212223242526
27282930123
45678910

View posts in large calendar

Recent comments

Tags

Disclaimer

The opinions expressed herein are my own personal opinions and do not represent my employer's view in anyway.

© Copyright 2017

Sign in