Archive

Posts Tagged ‘Do Stuff’

Using Power Pivot I discovered–Huston we’ve got a problem…

April 23, 2012 Leave a comment

New Toy! A new toy is always the best.  Old toys are OK, and certainly fun but there is nothing like a new toy.  So, I started playing with Power Pivot and found that the tool is really great at visibly showing issues.  Being able to visualize the data makes it easier to determine if there is a problem.  Traditionally, you could be down days, weeks even, before an issue like this could come to light and really slow down your whole process…

This is the story…

Ok, it was time to see what this puppy could do with my 39 million row record set.  Now, frankly I expect it to totally choke.  And I thought it had… but instead, it told me that the whole report would not fit on the sheet and then went ahead and produced one…

image

It didn’t freeze and it returned a pretty large set of data.  My set up was really basic:

image

The data was really raw.  So the next step is to do a little processing on the data and then return to PowerPivot. 

So, to start with I have total records of:

image

While I’ve proved that PowerPivot can work with this size of a data set, the limitations are the physical limitations of my system.  I’m running on a fairly beefy workstation as it is and it looks like I’ll need to reboot to recover some of the memory.   Things to keep in mind when working with large datasets.  What do I mean?  Oh, things like images stopped showing and the system just didn’t feel stable.

Next step, it’s time to think about some of the dimensions.  Sadly, the source database I’m working with is a pretty flat structure in many ways.  It’s what happens when you create a database that is to be all things to all people when it really should have been split apart.

Going on…

This is the staging table…

image

Description is the first Slicer.  It contains:

image

The numbers are pretty much what was expected except for City and County.   I’ll have to go back to the source draw to see why that is.

  • So first I looked at County: 528 rows
  • Ran the same check with City: 528 rows
    I sorted by the the “value” column to see if the counts varied by the value.  From a high level, that will be a sufficient test to proceed.  Actually, as I build out the dimensions I’ll be able to validate if the right data is coming across.

Hmmm… this is not looking good.  I retract that this is good enough for now.  It looks like the process needs to be re-evaluated.

After evaluating the data, I discovered the County and City Columns were reversed with each other.  So, I made the change on the back end.  Checked the results…

Now the data lines up but is it correct?  Cities and Counties still match.  Back to the source…

  • The first Slicer value returns 1993
  • The next ‘County’ returns 1523
  • Then ‘City’ also returns 1523
  • The last ‘Zip’ returns 2112
  • This all agrees with the Total Records picture.  Area and Zip have more records with a a slight edge to Zip.  That certainly plays true with the aggregated totals.  City and County do as well.  Now for the $64 question.  Is this correct?  My brain continues to argue that it is not…

    And then the light came on…
    Because of the way the query is structured, the following rule was applied:

Even if the filter (slicer) should return fewer rows, the minimum number of records returned will be the minimum that is determined by the uniqueness of the row returned.

To roll it all up:

Was there a problem?  Yes, two columns were reversed.  Did using power pivot help?  Yes, by showing a segment of data that intuitively looked incorrect  I discovered the error.  Part of this was user error also.  By relying on simple row counts, the picture presented was true but it did not have enough data.  Here’s the true picture…

image

Summary

While investigating PowerPivot, the right questions came up.  Would these questions have been asked later before the system went live?  Yes, as part of the Q&A process vetting the data is normal.  Using PowerPivot allowed me to save a lot of time by exposing issues and allowing the data to be visible without a lot of processing normally associated with large data sets.

Advertisements
Categories: Excel, Microsoft, PowerPivot Tags:

SharePoint – Act One

January 4, 2012 Leave a comment

Sometimes you just feel…  Well not happy.

It feels like I’ve done this a b-jillion times but back to the virtual world and crank up a new server.

First Steps…

  • Spin up a virtual system of windows 2008 r2
  • Stir in active directory and domain controller
  • Add in a heaping helping of SQL server (set up for SSRS)
    • Create a service account svc_SqlServer
  • Throw in a service account or three
  • Pour in the SharePoint binaries
    • Create service accounts for SharePoint
      • svc_SpAdmin – the installer

Shake, pour over rocks and serve… 

Ok, so it’s simply not just putting in a dvd and waiting.  Who’d thunk it.

Back to spinning up a virtual system of windows 2008 r2.

Since just happen to have one laying around (scary right), time to clone it. <—I like clones.  They’re easy to make and save oh so much time, unless you are rebuilding a whole SharePoint system.

Hmm… current state is good:

SNAGHTML258bb733

I’ll even make it a full copy…

SNAGHTML258c011e

Done and done.

Yup… latest updates..

image

Lessee… this is a demo, all in one environment… so first things first is to create the dc role.

In goes active directory first…since it is greedy, by itself.

image

Love those little green checks…

image

Now time for DCPROMO…

Run dcpromo.exe

image

Read or skip the next bit on OS Sys Compat.  I’d recommend reading it.

image

Here, we are going to create a new forest.

image

Type in the FQDN like foo.company.com

image

As this is a virtual system, go with the 2008 R2 level.

image

Add in the DNS server

image

DHCP Challenge

here you’ll get some grief if you’re running on a dhcp system.  Again, this is demo mode so go with the DHCP option.

image

File Locations

Defaults are fine unless your environment needs another location.  Then give it a strong p@SSw0rd!  Note: Make sure you right it down.  when you have a lot of demo systems up, using the same password for all works very well.  Saves headaches later.

image

Click next and you get this…

image

When it is done, click Finish and Restart.

image

So far so good….

Time for SQL Server 2008 R2

Here I’ll be using the SQL Dev Version.  Time for more install fun.  Now, I could just go with a singleton install of SharePoint but that would defeat some of the issues you’ll find.  Plus, there are some cool tools and stuff.  I’ll have to do the same thing with 2012.  Also, it is not best practice to install everything on one server but hey, it’s a demo.  Typically for sites less than 10,000 users, a single web front end (SharePoint) and a separate database server (SQL) is what you need.

The StartUp Screen

image

Pretty much a one stop shop for notes and documentation.  Click on installation.

The Install Screen

Go with New Installation

image

Support files installed, click on OK

image

Click next on the product Key,  Dev version preloads this.

Accept the License Terms and check send features, etc. to Microsoft.

Install Support Files

image

Support Rules Warnings

image

Here you need to note to items (the warnings).  The one about the domain controller, you can ignore.  In the real world, the DC would be managed by the IT staff and they aren’t going to let some SharePoint dude within 100ft.  So that will never be an issue.  Unless you’re the SA, then you’ll have to deal with yourself.  I was going to say “play nice” but that just didn’t sound right.

Next, the Firewall thing.  Be aware that this may impact what you are trying to do.  We’ll come back to this later.

image

A cart horse thing

Next its time for features.  The cart horse thing is the PowerPivot.  SharePoint isn’t installed yet so this is not an option.

image

Features?  Give ‘em to me!

On the next screen select them all then… Please Wait…

image

At this stage, no rules should fail so click next.  If you have errors, resolve them and continue.

Instance or Default? Default is fine…

image

Space Check

image

Account Check..

Did you plan your accounts?  Well, if you are following through this blog, the current answer is no.  Do you cheat and use one and only one account?

image

Some blog thoughts are found here on accounts and best practices

Microsoft’s documentation on SQL Security BP on TechNet

For the “demo system”, we’re going to cheat and use one account only.

Back to AD

image

Navigate to Managed Service Accounts

image

Create a new user

image

Be a minimalist…

image

Give it a strong password that never expires… (remember or write it down!)

never expires, cannot be changed…

image

Back to SQL

image

  • Use one account for all services
  • type svc_ in the object name box and click check names
  • The fully qualified name returns, click OK
  • Enter the super secret password n the all account box and click OK

image

It’s magically populated:

image

Windows or Mixed – More Choices…

Mixed is my preference and I add the current user.

image

SSAS Account provisioning… Add Current User and accept default data directories

image

image

SSRS : Yes, SharePoint Integrated Mode

image

Tell Microsoft

image

Rule Check

image

Here the summary screen follows.  Click Install… Please Wait…

You’re done…with SQL

image

A word from the sponsors

Now it’s time to break away from the install process for a minute.  Before installing SharePoint, it’s a good idea to create a few service accounts, logging out of your current user id and logging back in with the SharePoint install account.  You can keep it around after the install to manage the administrative side of things or get rid of it after granting those right to a specific user group.  Take a look at this web site page for more details.

Install and Farm Accounts

svc_SpAdmin

svc_SpFarm

Original Naming right?

svc_SpAdmin

This one is a bit of a heavy hitter.  We’ll start with it.  Go ahead and repeat the same process with svc_SqlServer for the two additional accounts.

image

Feel free to add in descriptions…

Add svc_SpAdmin to db_owners

You start up SQL server management studio and ??? – where is it?

image

All the pieces are there but no server…navigate to SQL Server Configuration Manager

image

This is what you see…

image

Ok, everything looks right?  What was wrong?

The first time you went in, because the server had yet to be restarted after the install, the service wasn’t running.  Going into configuration manager shows that now it is.  By starting up sql server management studio, Windows got the notice to fire up sql.

Navigate to Security

image

add svc_SpAdmin

  • right click on logins, click new
  • click search and type svc

image

  • click check names
  • select svc_SpAdmin

image

  • click OK
    image
  • Click on Server Roles

image

  • Grant dbcreator and securityadmin access at this time and click ok

image

  • Add svc_SpAdmin to the local administrators group

It’s SharePoint Binaries Time – Finally!

Are we done with service accounts and such?  No, the fun is just beginning but enough is now in place to allow SharePoint to be brought up and installed.

A note for sanity sakes…

  • close all open applications
  • install updates and shutdown to clone

image

Here a snapshot clone is sufficient.

Bring up your shiny new machine.   Heck might even activate it…

Pop in your shiny SharePoint DVD and away you go…

image

Review the Prepare Stuff.  Especially take a look at Initial deployment administrative and service accounts (SharePoint Server 2010)

Install – Prereqs…

image

******* Log Out and Log in as svc_SpAdmin *******

Taking the shiny new administrator out for a drive and installing binaries…

  • Click on Install SharePoint
  • enter in your msdn Product key…
  • Accept the license terms
  • Accept default file locations
  • Click on Install Now … Please Wait …

Once the prereqs are done, run the Configuration Wizard

image

Restart Services

image

Create a new server farm

This is demo world so letting the wizard do its thing is ok. 

image

Database connection

  • enter the name of the server (computer name)
  • enter the service account
  • click next

image

  • provide a passphrase (write it down)
  • Specify port and security settings

image

Using Kerberos will bring up this dialog box

image

NOTE: Don’t ignore this.  You will have to manually configure SPNs in AD.

Finished

image

It’s SharePoint Central Admin

image

And here you go…

image

A couple of fun commands…even if it is simply a command line action, run it from PowerShell.   For example, you can get a list of the Kerberos tickets on the machine using klist…

image

Any form of the help command works fine…

image

Categories: Microsoft, SharePoint Tags:

The Type Shifting Dilemma…

August 19, 2011 Leave a comment

The Setting:

It’s 4:45pm and a single word in a document needs to be changed.  You’ve put it off because it was only a minor change.  Now the deadline is 5:00pm and you’ve double clicked on the link and you’re presented with:

image

A quick scan of the document and everything looks fine so you click on Enable Editing.

SNAGHTML10b8851e

The page shifts… Nothing looks right anymore.

Quick… just a couple of minutes have gone by, you call the originator of the document.

The call goes something like this…

The Call…

“Hey, Sam, what’s the deal with this document?  The formatting is all messed up.”

Sam replies “not sure what you’re talking about, it looks fine here…”

You can even walk over to Sam’s machine to check it out.  Even have them open the email link just like you did and click on “Enable Editing” as well.

The Light Bulb

Comes on… It must be the font.  Yet, the font in the window is the right font…

image

At this point, do yourself a favor…  open and scroll through the available list of fonts.  Even if it shows in this window, it probably is not on the machine.

Symptoms to look for

The format changes just a little bit.  Maybe it is a page break or alignment.

Fixes

1st you can install the missing font:

In Windows 7 – open the font location
  1. Click the start button
  2. Type ‘Fonts’ in the search box
  3. Double click the fonts folder to open it and you get:
  4. image
  5. Drag and drop the missing font here

In other versions of windows, Fonts are access through the control panel.  You can get there from the Control Panel in Windows 7 too but I like the quick search feature myself.  I believe the same process will work in Vista but not sure.

If you want to know what font Windows was substituting?

  1. Open up the back stage view by clicking on the File Tab
  2. Click on Options
  3. Click on Advanced

Scroll down n the selections until you find:

image

Click on Font Substitution and you see what fonts in your document are being substituted and with what font….

SNAGHTML10c85307

It may be the default font or Word may try for a better match.

Deploying SharePoint … the beginning…

August 16, 2011 Leave a comment

First and the most important item here is that this will be based on a Very Small SharePoint implementation.  The service is to support less than 100 users.  If there was more trust of the cloud based products, the web based version of SharePoint would have been a likely choice.  Not so much for us though.  Even though we are a small company, we’ve employed the enterprise version of SharePoint.  This was after running through Foundation, and then Standard versions.  With Microsoft, all the good stuff comes in the Enterprise version.  No a la carte here…Hello?  Microsoft?  A La Carte model please???

One of the first lessons learned was that SharePoint is more of a concept than a concrete object you can put your hands on.  Sure, it has that element but…like that piece of dense chocolate cake that goes thunk… it’s heavier than you think.  SharePoint is a server product that can have a inclusive SQL Express server or access an external server.  Depending on which model you opt for, be prepared to create a lot of AD entries if you go for the more than a single server model.

SQL Server is a critical element of SharePoint

When isn’t SQL Server a critical element?  While SharePoint does provide functionality to access external content, SQL Server is a central and critical piece of the SharePoint solution.  In our deployment, I set it up so that we used an external, dedicated SQL Server to support SharePoint first.  Secondary databases were added after the solution was in place and evaluated for their impact.  The SQL Server is a bare metal server.  While it has been documented that SQL will run virtualized, we did not want to take the chance and dedicated a server.  Hardware is getting cheaper by the day.

What version?  Since it is well known the the future of Microsoft products is going to be on 64 bit servers, we went with the latest version of SQL on a 64 bit box (SQL 2008 R2 x64).

image

Servers and Web Roles…More fun

Start up a Windows Server (2008 R2 x64 please) and you’re confronted with ROLES.  Well, SharePoint needs a ROLE or two to function.  Since it is an application the Application Server Role would be good.  Web?  I think SharePoint has “some” web parts to it, so IIS would probably be a good idea.  Go to this PowerShell and SharePoint link for PowerShell stuff.

In addition to the roles mentioned, some other stuff should be set up ahead of time:

NOTE: I’ve tried to pull in the latest links but please double check as things to change and it’s always best to get stuff fresh.

In the small scenario, all of these components and roles are on one server.  The only separation used is that the SQL Server is on a different box.

Looking around my office and thinking about this project, I have four books on SharePoint 2010 that I’ve collected over the past year or so (see below).  Most of these were not even in Print when I started this project.  It’s been a long an interesting road for sure.  Some are dog eared.  Others a full of sticky notes and yellow highlighter.  Go figure…

SharePoint has a lot of Service Applications that can be enabled

image

Not all of the services should be activated just because.  Only activate what you need.  Just because you’ve activated it doesn’t mean you’re done either.

To get familiar with PowerShell support, go to the Microsoft SharePoint 2010 Products on the server menu:

image

Open up the SharePoint 2010 Management Shell and type Get-Command.

You will see a long list…

image

SharePoint Search:  As mentioned in other blogs, there are two SharePoint search facilities, SharePoint Search and Fast Search.  For fast, you want a different server.  We’ve not implemented Fast.  Normal search will suffice for now.  When we need thumbnails and other fancy stuff, we’ll get another server for Fast.

One of the roles that will need to be enabled for our server will be Email Integration.  This will require some separate steps but is necessary for records and content management.

Again, since this is a limited server farm, the default of having server administration role on the same server is not an issue.  When our farms grows HUGE, then it might make sense to put the role on it’s own dedicated server.

Development Needs: Say what you will, having your own personal SharePoint server to do development is a good thing.  Having it as a virtual system is even better.  To facilitate this, I leveraged VMware Workstation to build separate SharePoint environments to mimic the three systems we have in place: Foundation, Standard and Enterprise.  Why go through the trouble of setting Virtual Environments for SharePoint?  In a word – SNAPSHOT.  SharePoint is a large environment that can go sideways on you in an instant.  Not all sideways events are easy to recover from either.  By using a virtual environment, you can test stuff out without risking your sanity.  I follow the same process for almost any additional tweak to the system:

1. Snapshot

2. Develop

3. Confirm

4. Snapshot

If only the server was running with a similar facility!  I’d have fewer gray hairs…

Notice the VMware reference?  Well, I have to admit that I’m a bit confused on Microsoft’s virtual pc offerings.  Eventually, I’m sure I’ll find a concise HOWTO and start using it.  So far, mostly due to lake of time, the resources on MSDN and Virtualization seem, detailed but scattered.  <—opinion!!!

Recap:

Server acquired

Pre-requisites installed

At least one installation of SharePoint using VMware completed and a snapshot taken

Ready for the plunge, bringing up the server…taking down the server…bringing it back up.  Crud, it isn’[t working as expected and what is this about Kerberos anyway?

Books Used…

http://www.wrox.com/WileyCDA/WroxTitle/Beginning-SharePoint-2010-Development.productCd-0470584637.html

http://book.pdfchm.net/microsoft-sharepoint-2010-unleashed/9780672333255/ – the overall reference book

http://blah.winsmarts.com/2009-12-Microsoft_SharePoint_2010__Building_Solutions_for_SharePoint_2010.aspx <- a great reference for setting that all important Development Environment.

http://www.wrox.com/WileyCDA/WroxTitle/Professional-SharePoint-2010-Development.productCd-0470529423.html

Of course various .Net and SQL server references as well.

SharePoint takes a plan and other requirements…

August 15, 2011 Leave a comment

SharePoint is not a system that you can just deploy.  Basically, if you compare SharePoint 2010 with SharePoint 2003 it would be the same as Comparing a 2010 Dodge Challenger with one built in 1975.  The may look similar on the outside but the insides are all different (scratch that… you can make SP2010 look like 2003 but why?).  In 75, you could tweak or replace a carburetor for better performance but with the 2010 model, it’s a setting managed by the onboard computer system.  Even changing the light bulb on the new Challenger is a challenge (trust me, you have to pull the front bumper off…)!  Sorry, back to SharePoint.

With Improvement Comes Complexity

Under the hood, SharePoint is all new.  While there may be some remnants hanging around the new beast is really comprised of a bunch of independent services.  Something you discover pretty quickly after the bits are installed and you’ve visited both sides of the administration points.  Both sides?  Well, that depends on the the number of folks working on the project, who’s on first, what’s on second and so on.

image

The thing that’s nice about the service model is the ability to scale out over multiple servers.  This adds a nice bit of scalability to the platform and reduces the strain on the crystal ball.

Search

Now promoted and does more.  Check…SNAGHTML1799997  Well, a little more than that.  Native search is one of the new services.  Now, just because you’ve enable the service doesn’t mean it just works…  There are a few steps and site particulars that need to be addressed before search is usable.  See Post-installation steps for search…

But just talking about search brings up some interesting points.  Which version of SharePoint you run will largely be dependent on the budget available.  Enterprise builds upon Standard that builds upon Foundation.  In fact, Foundation may be all the SharePoint you need at this time. See SharePoint Products.  For some additional content, see SharePoint Server 2010 Operations Framework and Checklists.

SharePoint is a large ecosystem with deep features.  Great stuff but be prepared for a learning curve.

Heath and Well Being of SharePoint

This one gets a bit sticky.   It was also the most challenging point to convince the IT department to set up a sufficient number of service accounts.  What really doesn’t help is the challenge of finding a concise list of what accounts are needed.  You are going to love to learn to hate this:

image

You’ll spend a lot of time going through messages like:

image

Now, the ability to get help from within the application has improved.  When I first started clicking on the links,  the web page that opened was the general SharePoint landing page with no reference to the error provided the link…

Now, 9 time out of 10, you land on a page with helpful information:

image

The following figure shows that there is just one or two accounts that can be specified for SharePoint:

image

First, as far as accounts go, you need a specific administration account to set up and configure the server.  After that is done, you’ll use that account to log into the server to specify the individual DOMAIN accounts to use for SharePoint.  Some services can use the same account while others it is best to specify their own account.

One of the nice features to plan for is Automatic Password Change.  Your domain accounts are going to be subjected to password expiration rules unless you override that policy.  Since SharePoint can manage its own password change process, it’s a good thing.

image

A good document that addresses the accounts is Account permissions and security settings.    Basically the list is as follows:

Account Used for Comments
sp_Admin Server administration / Farm administration Domain account, used when the server is created.  Gets many of it’s permissions through components.
sp_SetupUser used to setup each server in the farm Must be a domain account, a member of the local admin, and must be able to access the SharePoint server database.  If PowerShell is used the account must be a member of db_owner on the database server and have security admin and dbcreator rights.  You’ll want to keep this account around.  Removing it can cause all sorts of chaos.
sp_FarmService (database access account) application poll identity for central admin,  process account for SharePoint foundation and runs the TimerService Must be a domain account with user account permissions
Granted additional permissions through SharePoint tools.
sp_SearchService SharePoint basic search features Must be a domain account with user account permissions
Granted additional permissions through SharePoint tools.
sp_SearchContentAccess crawls across sp content sites Must be a domain account with user account permissions
Must be a member of the Farm Admin group
Granted additional permissions through SharePoint tools.
sp_ApplicationPool application pools Given machine level permissions through SharePoint tools or configured separately through PowerShell
sp_MySiteAppPool application pool Must be a domain account with user account permissions
Must not be a member of the farm admin group

That’s a start.  for additional information, see the provided link above.  For all accounts listed that need to be a domain account the format is <domain>\<user account>.  ex: Domain\sp_Admin

Access says I

July 14, 2011 Leave a comment

Here I sit before a mostly empty screen.  Mostly because on the left hand side are a bunch of objects I created on SQL 2008 R2.  The data warehouse side of the system I’m working on.  Why access, why not .Net?  Granted, behind the scenes I am working on a SharePoint 2010 BCD project regarding the same data.  The reason is simple, I need to create a web-able application that can be used right now.   Having used Access for a long time keeping up skills with the new version is also important.  Viva la multi-task!  Or was that Multi-Pass?  Can you say the 5th Element?

The One Liner Report and other requirements

For this project to meet the minimum functionality requirements it needs to produce a one liner report and a detail report.  Report in this sense is not necessary an actual report (though with Access that structure is certainly within bounds) but of a data grid and detail view of a single record.

image

And the Detail form similar to:

image

Simple right?

Background Noise

Ok, before we can get to the One Liner and all the goodness there, some background notes on the data warehouse staging database is needed.  First, notice that this is the staging database that is being used.  I wish time allowed for the DW to be fully vetted into a cube but that definition and design effort is still a ways off.  The mandate is that the data needs to start producing results now.  I can only dream about the eventual cube.  The basic design around data collection into the staging database is a forward moving dataset.  What I mean by that is that records are only appended so that the historical state of a given transaction is preserved.  The requirement for this report is that it is a snapshot in time reflecting the current state of all transactions at that given point.  This is easily facilitated through using the primary key on the data table that combines the unique id of the transaction plus the date of the transaction .

The One Liner Definition

There are three sources of data for this report.  Public records, and records from two internal systems.  Step one, develop a one liner form that matches the top diagram.  So I start with this…

image

I already have a view from SQL I want to use so that will be my data source.

Since this is a wide view, I’ll use a query within access to filter down to just the data required.  The view has already been flattened out to some degree so it will be necessary to restrict the data down to only the master list.  Easy to accomplish through the query property view.

image

The query now returns only about 2k records instead of the 27k returned the first time.  Pretty close to the one liner definition.  A little formatting and then I’ll create the detail form before finishing the one liner report.  Saved off the query with a distinctive name and it is now an available object to use.  I can use the Unique Values property in this query against the query that I set up in SQL because I already scoped the data using only the latest values for each distinct master record.

Something like…

image

This means that the query that is set up only returns a list restricted to the Master Data Record dataset.

image

The Detail Report…

Next an additional query needs to be set up that takes a parameter and returns…

image

I test the query first.  I expect that even though I only put in a single office number, I should get more than one row back.  This is expected and the properties should be changed as above so that only unique data comes back.

The parameter box pops up as expected;

SNAGHTML4526177

Using a known Office number that will have multiple entries, the query is executed.

image

Setting properties to Unique changes 1 of 24 to;

image

The query is saved and now there are two.  Notice the original query, One Liner Source name has been changed to One Liner Source View for consistency.

image

Still no forms yet.

Form Story

The first form to be created will be the form for the one liner report.  The concept for this form is a table with some formatting.

image

By simply having the dataset selected and clicking on the form Multiple Items form selection, Access automatically builds the form.

SNAGHTML45ac613

For the Detailed view, the Form Wizard will be used…

SNAGHTML45ea4ec

Using all the fields and a Justified form template…

SNAGHTML45e5bad

And giving it a nice name…

SNAGHTML45f4060

Clicking on Finish results in the challenge box…

SNAGHTML460761f

The wizard will make it’s best guess on how to set up the form but you’ll probably need to go into design mode to set it up how you want it to look.

image

Make sure to grab the move box if you want to separate the data field  from the label field.

image

Depending on your Mouse to Hand to Eye coordination, the Size and Order features really help cleaning up the form.

Applying an input mask can help format the data.

image

Long Story Short

The current prototype has been well accepted.  Next article will be utilizing the same prototype and pushing it up to SharePoint.

.Net Again…VS2008 touching an old project

June 26, 2011 Leave a comment

Request for the permission of type ‘System.Web.AspNetHostingPermission, System, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089’ failed.

Don’t you just love it?

How I got here:

Fired up VS 2008 and opened up the project from a network location.

SNAGHTMLbf0531

Ok, not a trusted location.  If you continue and try to run the project you will get a security issue.

Now this just seems wrong to me.  I’m on a VPN connection…

Yet I get…

[SecurityException: Request for the permission of type 'System.Web.AspNetHostingPermission, System, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089' failed.]
   System.Reflection.Assembly._GetType(String name, Boolean throwOnError, Boolean ignoreCase) +0
   System.Reflection.Assembly.GetType(String name, Boolean throwOnError, Boolean ignoreCase) +42
   System.Web.UI.Util.GetTypeFromAssemblies(ICollection assemblies, String typeName, Boolean ignoreCase) +145
   System.Web.UI.TemplateParser.GetType(String typeName, Boolean ignoreCase, Boolean throwOnError) +73
   System.Web.UI.TemplateParser.ProcessInheritsAttribute(String baseTypeName, String codeFileBaseTypeName, String src, Assembly assembly) +111
   System.Web.UI.TemplateParser.PostProcessMainDirectiveAttributes(IDictionary parseData) 

 

OK OK

So, I copied the project to a local folder.  Tried VS again…

No change to the file but no warning message either…

No problem either.  The app fired up in VS just fine.

Now why didn’t it work?

One thing is Windows 7.  Windows 7 has trust issues!  Well, not really but the security is certainly increased.  Security state is persisted down so if you open a non-trusted location the files remain so.

Second thing… the credentials I used to access the network location through the VPN are different then the credentials I used to log on to the PC.  Again, there are certainly ways you can get around it but that’s another story.

So, will the copy fit the needs?

Well, hmmm.  …

A remote application NOT under source control can be copied down to a location where source control is used. 

The copy remains untouched until the changes are complete and tested.

A new copy can be put back up in the network location as the next rev.

Thanks to local source control, the changes are persisted.

We’re done here…

Ok, this is a quick and dirty way around a security challenge.  While perhaps not the most elegant solution it fit the bill.  Call it guerilla coding or what not, when you’re in the trenches, a simple copy paste keeps the hourly rate down.