• SharePoint 2010 Managed Metadata Columns–Required Feature is not Enabled

    Posted on April 10th, 2012 AIS User No comments

    Every once in awhile, we run into a situation with SharePoint 2010’s Managed Metadata where the feature is not enabled and not available.

    Here is the scenario:

    • You are creating a new column of type “Managed Metadata”
    • When selecting the managed term set, you discover the following message:

    The required feature is not enabled for this column type

    image

    • You navigate to
      Site Actions –> Site Settings –> Site Collection Administration –> Site Collection Features
      … and discover there is *no* managed metadata feature…

    Ugh

    Solution
    (All steps below must be executed on the server hosting SharePoint 2010)

    1. Launch the SharePoint 2010 Management Shell from the start menu/All Programs
      Microsoft SharePoint 2010 Products –> SharePoint 2010 Management Shell
      (Wait for it… it is slow)
    2. Execute the following command line at the prompt
      (Remember to replace [URL] with your site’s URL)

    Enable-SPFeature -id “73EF14B1-13A9-416B-A9B5-ECECA2B0604C” -url  [URL]

    Root Cause
    In our experience, this has been the result of creating the top level site in the site collection using the Blank Site template.

     

    Now, go enjoy your meta data!

  • MonoDroid: How to determine if you are on a phone or tablet

    Posted on February 14th, 2012 AIS User No comments

    In a recent Android based mobile application using Mono, our customer requirements dictated two sets of screen layouts: one for Android phones and one for Android tablets.

    Easy right?

    Well… No.  The requirement statement “detect if the device is a tablet or phone using MonoDroid and display the appropriate layout” turned out to not be as trivial as we originally suspected.

    A quick Google search turned up several solutions using screen size and density to determine the answer to the phone vs. tablet question.  While workable, these solutions were far from fool proof due to the vast array of sizes and densities available on various Android devices.

    Ugh.

    During an offsite Red Solo cup session, the answer occurred to one of our senior developers:  Ask about IMEI!  If the device has an IMEI, its gotta be a phone (or a tablet with suspiciously phone like qualities).

    Our Solution
    A property exposed on a helper class which probes the IMEI and determines phone vs. tablet.

    EDIT 02/27/2012: Code updated to reflect API support for 4G phones

    public bool IsPhone
    {
      get
      {
        return ((this.GetSystemService(Context.TelephonyService) as
                    TelephonyManager).PhoneType != PhoneType.None);

       }
    }

     

    Quick, simple, solved!

  • Avast! Business Protection Plus: Administration console will not open in browser.

    Posted on October 23rd, 2011 AIS User No comments

    Here at AIS, we just completed a test install of Avast’s new “for business” centrally managed Anti-virus software (see this link for full details).  The installation went smoothly until we attempted to launch the Silverlight based administration console.  We expected to be greeted by a nice, new, shiny console with all the bells and whistles.  What we got was…. nothing.

    Our Environment

    • Windows server 2008 R2
    • Avast! Business Protection Plus (version 1.1.6164)
    • Standard install of Avast! Business Protection Plus
      (All defaults accepted except the SQL Server default.  We already had a SQL instance prepared and ready to go)
    • Test client running Windows 7

    Symptoms

    Using a default install, the administration console should be available at the following URL

    http://ServerUNCGoesHere/Avast/

    In theory, this link will redirect you to the Avast! administration console on port 8732 using ssl.  We attempt to launch the administration console from our Windows 7 PC using IE9.  After 1 – 2 minutes, we received an error simple stating

    Internet explorer cannot display the webpage

    Helpful….

    Root Cause
    It didn’t take us long to figure out we had a firewall issue.  Port 8732 was nonresponsive to traffic.  A quick look at the firewall settings demonstrated the Avast! installer had modified the firewall rules.  Two new rules had been added, one rule each for UDP and TCP connections referencing the program
    C:\Program Files\AVAST Software\Administration Console\Avast.Sbc.Server.exe

    That should work…  but Windows Firewall was not in agreement.

    We did not spend the time to figure out why the firewall association to the service level application was not working.  Our guess is Avast! is using some behind the scenes redirects which confuse the firewall.

    Solution
    We need to add port level firewall settings for Avast!

    1. Open Windows Firewall with Advanced Security on the server Avast! was installed on
    2. Highlight the Inbound Rules section
    3. From the menu select MENU: Action –> New Rule
      This will launch the new rule wizard
    4. Under Rule Type, select Port
      image
    5. Under Protocol and Ports, enter the specific ports 8731, 8732, and 25322
      NOTE: Your ports maybe different if you did not use the installation defaults
      image
    6. Under Action, select Allow the connection
      image
    7. Under profile, select the appropriate profile for you installation
      (In our environment, we selected “Domain” to reflection our network domain)
      image
    8. Under Name, give your rule a new name
      We recommend “avast! Administration Console (ports)” to prevent any confusion

     

    That’s it!
    We were now greeted with a nice, new, shiny console with all the bells and whistles.

  • Monotouch iPhone – Showing activity to the end (or how to create an iPhone wait cursor)

    Posted on October 7th, 2011 AIS User No comments

    One of AIS’s recent projects involved development of an iPhone application using MonoTouch. This application made significant use of web services, some of which could take 10’s of seconds to return (Yes, we were moving a lot of data for this particular application… there is just no easy way to deal with “historical data”).

    Rather than just locking the UI for the duration of the activity, we wanted to display a user notification that something was actually happening in the background. In addition, we wanted to disable the UI so the user did not inadvertently believe they could tap anything.

    Our goals:

    1. Display a “long running operation” notification to the user

    2. Lock the primary UI to prevent unwanted unexpected user interactions

    3. The component must be reusable

    To accomplish this feat of programming, we decided to use a UIAlertView with a UIActivityIndicatorView on it. We created the ActivityAlertView class to manage this for us. It allows you to use it in one of 2 ways:

    1. In a using statement. This will display the ActivityAlertView for the duration that the using statement is in scope:
    2. using(ActivityAlertView alert
                = new ActivityAlertView("Logging in, Please wait"))
      {
            //Code to do while ActivityAlertView is displayed to user
      }

    3. Normal instantiation
    4. ActivityAlertView alert = new ActivityAlertView;
      alert.Show("Logging in, Please wait");
      //Code to do while ActivityAlertView is displayed to user
      alert.Dismiss();

    Here are a few screenshots of the attached demo project.

    imageimageimage
    (Click image to enlarge)

    Download the sample project and source code from this link

  • Resetting passwords in Avast! ADNM Console

    Posted on October 1st, 2011 AIS User No comments

    Passwords get lost.
    It is a simple reality of the security conscious technology driven world we live in.  That and password complexity rules which make differential calculus look simple.

    So, imagine our surprise when we lost forgot an administrator password to one of our Avast! Antivirus ADNM console installs. 

    Fortunately for us, there is a quick and painless solution.

    Prerequisites
    You must have read/write access to the avast database created when you setup your Avast! corporate editions.

    How to change a password in Avast!

      1. Make sure the prerequisites are met
      2. Logon to the avast SQL database
      3. Execute the following query

    SELECT *
    FROM dbo.[User]

      1. Note the ObjectId for the user you wish to reset the password on
      2. Execute the following update query

    UPDATE dbo.[User]
    SET Password = ‘[Reset Password Goes Here]‘
    WHERE ObjectId = [ObjectId of User Goes Here]

    1. To re-encrypt the password, set the password via the ADNM console.

    Much easier than reinstalling!

  • SharePoint 2010 Service Pack 1 (You aren’t done yet)

    Posted on September 30th, 2011 AIS User No comments

    The engineers here at AIS have a love hate relationship with patch management.  When it works, life is wonderful… when it does not work… well…

    Which leads us to SharePoint 2010’s Service Pack 1 (available to download at this link).   When downloaded and executed against your server, this service pack updates the binaries NOT the database.  How will you know?  You will notice several errors in your event log similar to this one:

    The mount operation for the gatherer application [Guid goes here] has failed because the schema version of the search administration database is less then the minimum backwards compatibility schema version support for this gatherer application.  The database might not have been upgraded.

    So, what is happening here?
    The service pack has updated the SharePoint 2010 binaries (I.E. the software is up-to-date).  The service pack, however, does not run the Configuration Wizard.  This means the SQL database has not yet had the necessary scripts executed to update the database schema.  It seems the update is really a two step process.

    So, how do I really know I need to perform additional steps
    Ask SharePoint Smile

    1. Launch the SharePoint Management Shell
      Start Menu: All Programs –> Microsoft SharePoint 2010 Products –> SharePoint 2010 Management Shell
    2. Enter the following command
      (get-spserver $env:computername).NeedsUpgrade
    3. If the response is True, you server requires additional upgrade steps to be completed

    So, how do I fix it?

    1. Launch the SharePoint Management Shell
      Start Menu: All Programs –> Microsoft SharePoint 2010 Products –> SharePoint 2010 Management Shell
    2. Enter the following command
      psconfig –cmd upgrade –inplace b2b –wait
      NOTE: This command *must* be entered on every server in your SharePoint farm

    It is recommended to run IISRESET or (our personal favorite) reboot the server.

  • Creating SharePoint 2010 Themes: The Quick and Painless Guide

    Posted on July 3rd, 2011 AIS User 1 comment

     

    SharePoint 2010 Standard and Enterprise editions support changing themes directly from the SharePoint administration pages.  These theme pages are a very powerful tool which supports updating any theme color as well as previewing your changes directly from the browser.

    SharePoint 2010 Foundation edition users, however, do not have the ability to change themes directly from the browser.  While the lack of a theme editor in the Foundation edition is painful, all is not lost.  If you have PowerPoint 2010, you still have the ability to customize your portal’s themes.
    NOTE: The techniques discussed in this blog entry are targeted for SharePoint 2010 Foundation users, but will work equally as well with Standard and Enterprise editions.

    Prerequisites

    1. SharePoint 2010 (any edition)
    2. PowerPoint 2010
    3. You must be a site administrator within SharePoint 2010
    4. 10 minutes of your time

    We suggest starting with an existing SharePoint 2010 theme rather than using one of the provided PowerPoint themes.

    Step#1: Download an existing SharePoint 2010 theme for editing
    NOTE: If you are creating a new theme from scratch or wish to use the PowerPoint built-in themes, please skip to Step#2: Edit the theme.

    All of these steps take place within SharePoint

    1. Navigate: Site Actions –> Site Settings
      This will open the Site Settings page
    2. Locate the Site Collections Administration section within the Site Settings page.
      If you see the option “Go to top level site settings”, click it now!
    3. Now locate the Galleries section within the Site Settings page
    4. Click the Themes link to open the Theme Gallery (See image below)
      image
    5. Locate the theme you wish to use as your base theme.  Click the checkbox (I.E. check the box) located to the left of the theme you have selected.  This will open the SharePoint ribbon
    6. Click the Edit Document button within the SharePoint ribbon
    7. PowerPoint 2010 will open with the SharePoint 2010 theme loaded
      NOTE: PowerPoint can take several seconds to open

    Step#2: Edit the theme

    All of these steps take place within PowerPoint

    1. Click Design on the PowerPoint ribbon menu
    2. Locate and click Colors within the design ribbon
      The colors drop-down is located to the far right on the ribbon (see image below)
      image
    3. Select Create New Theme Colors (see image above)
    4. Using the Create New Theme Colors dialog, change the color palette to meet your style and branding needs
    5. Change the name to reflect the updated custom color palette
    6. Click Save on the Create New Theme Colors dialog to save the updated color palette
    7. Click File on the PowerPoint ribbon menu
    8. Select Save As
    9. Change the Save as type to “Office Theme” and save your updated theme (see image below).
      image

    Step#3: Upload the theme to SharePoint

    All of these steps take place within SharePoint

    1. Open the Theme Gallery. 
      (See steps 1 – 4 in Step#1: Download an existing…)
    2. Click Add new item located at the bottom of the list
    3. Browse to the theme file you created and saved from PowerPoint
    4. Complete the upload of the theme into SharePoint

     

    Additional Tips
    You can also update existing themes be saving your newly updated themes as the same name as an existing theme.  This will overwrite the existing theme’s colors with your new color palette.

  • Configure 3CX to use DIDforSale DIDs

    Posted on March 27th, 2011 AIS User No comments

    If you have not checked out DIDforSale and have any need for robust and inexpensive inbound DIDs… do so now.

    For those of you who have a 3CX PBX install in addition to DIDforSale DIDs and are having trouble configuring 3CX to correctly talk to the DIDforSale SIP Trunk, this blog entry will save you time and frustration.

    NOTE: This entry can also be used to configure multiple DIDs for most other SIP Trunk providers.

    Prerequisites

    • You have a fully functional install of 3CX version 9
    • You are not behind a firewall -OR- you have all required ports forwarded to support the SIP protocols
    • You have configured your DIDs to point to your external IP address for 3CX
    • Coffee is brewing

    Step#1: Setup a new VOIP provider for DIDforSale
    This step creates a generic VOID provider for DIDforSale and setups the basic parameters for the provider.

    1. Click the Add VOIP Provider Wizard button located on the toolbar of your 3CX management console
      image
    2. Give the VOIP Provider an appropriate name for your 3CX install and select Generic SIP Trunk
      image
    3. In the VOIP Provider Details screen, enter the SIP server hostname or IP as 209.216.2.211 (the IP for DIDforSale’s SIP server).  Leave all other data as the default
      image
    4. In the Account Details screen, set the value for the fields as follows:
      External Number: Your PIN number as supplied by your Trunk provider
      Authentication ID: Your login account (UserID) as supplied by your Trunk provider
      Authentication Password: Your password as supplied by your Trunk provider
      Maximum simultaneous calls: Whatever your license with 3CX allows
    5. In the Office Hours screen, select any extension you would like this to be forwarded to.
      NOTE: Anything you set in this screen will be overridden once we setup the inbound DID rules in the next section.
    6. The next screen will attempt to create an outbound call rule for DIDforSale.  Unless you are using DIDforSale as an outbound provider, click the Skip button.

    Step#2: Configure the provider’s inbound parameters
    This step configures the VOIP provider to properly extract the inbound DID # from the SIP request as sent by DIDforSale.  Without this step, 3CX will not be able to determine which phone number the inbound call is targeted for.

    1. Open and edit the VOIP provider created in Step#1
      image
    2. Select the Inbound Parameters tab
    3. Select and delete the To: User Part SIP Field (see highlighted image below)
      image
    4. Add a new SIP Field
      1st: Set the SIP Field combo box to Request Line URL: User Part
      2nd: Set the variable to “CalledNum” number that has been dialed
      3rd: Click Add/Update
      (See image for selection)
      imageNOTES: DIDforSale sends the destination phone # in the DIDNumber@YourIPAddress format.  This change tells 3CX to pull the CalledNum from the URI (I.E. the inbound phone number is the DIDNumber part of DIDforSale’s inbound request)
    5. Click Apply

    Step#3: Add and route your DID numbers
    This step setups each DID number and the internal routing associated with that inbound DID.

    1. Open the VOIP provider created in Step#1
    2. Select the DID tab
    3. Enter your DID number and click Add
      image
    4. Click Apply
    5. Select the Source ID tab
    6. Make sure the Source identification by DID is checked
    7. Click Add DID and select the DID you added in #3 above
      NOTE: If you do not see the DID number, you forgot to click Apply in #4 above
      image
    8. Select the inbound rule which was automatically created when you entered the DID number.
      image
    9. Change the office hours and routing rules to fit your organizations needs for the DID number being configured.
    10. Repeat these steps for each DID number you need to configure

    Step#4: Coffee Time!

    3CX
  • Creating Hyper-V virtual networks and the dreaded “Cannot bind to” error message

    Posted on March 21st, 2011 AIS User 2 comments

    Windows 2008 R2 Hyper-V server is an incredible tool in the IT pro’s test, backup, and recovery arsenal…. as long as everything meshes together nicely.

    One of the more interesting errors we see in the field is the dreaded message

    Error Applying New Virtual Network Changes
    Binding to the external ethernet [NIC goes here] failed.
    Cannot bind to [NIC goes here] because it is already bound to another virtual network.

    image

     

    We at AIS see this problem most often when dealing with multiple-NIC servers.  The failure scenario goes something like this:

    1. Provision and configure Hyper-V server 2008 R2
    2. Access the new Hyper-V server via Hyper-V Manager on a separate PC
    3. Provision the first NIC under a virtual network
    4. Provision the second NIC under a virtual network (At this point, something goes awry in the Hyper-V Manager due to a variety of RPC / COM issues… the list of which would fill a small book)
    5. The second NIC provisioning is partially active within Hyper-V but is not accessible via the Hyper-V Manager
    6. Any additional attempts to provision the second NIC will now be met with the dreaded “is already bound to another virtual network” error

    The quick and dirty solution

    1. Remote desktop into the Hyper-V server
    2. Find the command prompt window
      This is usually located behind the blue colored Server Configuration prompt window
    3. Type the following commands to uninstall and then reinstall the Microsoft Virtual Network Switch Protocols

    C:> netcfg –u vms_pp

    C:> netcfg –c p –i vms_pp

     

    These two commands will 1st uninstall the virtual switch protocols and then force a reinstall of the same protocols.  This simple two step process forces the invalid virtual network mapping to be cleared from the configuration.

    Happy (Virtual) Mappings!

  • SharePoint Alerts, External Users, and Exchange Relay

    Posted on February 1st, 2011 AIS User No comments

     

    One of SharePoint’s nicer features is a rich alert system which supports change driven e-mail based alerts.  Configuring SharePoint and Exchange Server 2007 to e-mail alerts is relatively straight forward for internal e-mail clients (I.E. those e-mail clients which are actually hosted by your Exchange Server).  Configuration becomes much more difficult if you are attempting to alert SharePoint users at e-mail addresses which are NOT hosted on your Exchange Server.  To accomplish this feat, you must relay the e-mail.

    This is where the fun begins!

    The Scenario
    Your e-mail address is internal@yourcompany.com.  Your SharePoint install at http://portal.yourcompany.com is setup to alert you of any changes to your document libraries.  All is well in the world!

    A new user is introduced to your SharePoint user list with an e-mail address of external@hotmail.com.  This new user reports he is not receiving any alerts from SharePoint.

    A quick review of the logs reveals the following error:

    #160009: The e-mail address ‘external@hotmail.com’ is unknown.

    Root Problem
    Your exchange server is setup to disallow relaying.  Under the hood, SharePoint is receiving the following error from Exchange:

    550 5.7.1 Unable to relay

    Solution
    Enable relaying for your SharePoint server.  Easy huh? Well… sort of.

    STEP#1
    Open Exchange Management Console and navigate to Server Configuration –> Hub Transport.  Find the Receive Connectors tab.  You should see something similar to the image below:

    image

    STEP#2
    Open the Receive connector and note all of the settings on each screen.  Take good notes as you will need the settings later.
    They will look similar to the images below:

    imageimageimageimage
    SCREEN#1              SCREEN#2              SCREEN#3               SCREEN#4

    STEP#3
    Remove the receive connector by right clicking on the connector and selecting Remove.
    Why do we do this?  Because Exchange Server 2007 appears to process the receive connectors in the order they were created.  In the standard install, the default Receive Connector is configured to receive e-mail from ALL IP addresses.  If you add the Relay Receive Connector AFTER the default connector, it will never be processed.  You want your Relay to process first.

    STEP#4
    Create the relay connector

    1. Click New Receive Connector on the Action Bar located at the right of the Exchange Management Console.
    2. Name the connector, click Next.
    3. On the Local Network settings screen, modify as necessary.
      NOTE: These will normally be the same as SCREEN#2 in STEP#2 above
      Click Next
    4. On the Remote Network settings screen, remove the default settings by click the red “X”.
    5. Add in the IP address of your internal SharePoint sever.
      NOTE: If your SharePoint server is hosted on the same physical box as the Exchange Server, be sure to enter in the loop back IP address (IPv4 127.0.0.1, IPv6 ::1) as well as the actual IP address of the server.�
      Click Next
    6. Click New to create the Receive Connector, then click FinishBut wait, you are not done just yet!
    7. Right click on the newly created Received Connector and click Properties to edit the Receive Connector
    8. Select the Permission Groups tab
    9. Check the Exchange Server check box
    10. Select the Authentication tab
    11. Check the Externally Secured check box
      Make sure all other check boxes are NOT checked.
    12. Click apply to save your changes

    Your new relay connector should look similar to the screenshots below
    (Double click to enlarge)

    imageimageimageimage
    SCREEN#5                  SCREEN#6               SCREEN#7                SCREEN#8

    STEP#5
    Recreate the original Receive Connector using the settings noted in Step#2
    Your receive connector list should now look like the following:

    image

    STEP#6
    Validate functionality

    1. Verify you can still send e-mail.
    2. Verify you can still receive e-mail.
    3. Verify SharePoint is now sending alerts to the external e-mail.
    4. Verify you have no open relays.  This can be completed via any of the available open relay tests on the internet.