how to test code in a wpf user control library

Im trying to figure out how to debug some code I created in a wpf user control library.

Because wpf user control libraries have no startup object Im not sure how to step into my code.

Error running from wpf user control library
The code is a simple validation of a text box.

Code Im trying to reach in wpf user control library.
I just want some way to invoke it.  Maybe a windows form with a button and a text box that references it and calls it.
Steve HougomDeveloper IIAsked:
Who is Participating?

[Product update] Infrastructure Analysis Tool is now available with Business Accounts.Learn More

I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

Éric MoreauSenior .Net ConsultantCommented:
Create a WPF application project, add a reference to your other project and then you will be able to test it.
Russ SuterSenior Software DeveloperCommented:
You need to embed the usercontrol in a form and run the application.

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
Steve HougomDeveloper IIAuthor Commented:
I added a windows form project to mine and Im trying to figure out how to invoke it.

Here is what my solution explorer looks like now.

Im just using a form1 button click to attempt to invoke my validation.  Im just not sure how to code the object that allows me to step through my validation.cs in the referenced project.
test form
Here is a button click event that I would like to use invoke the validation class in validation.cs.  Im just not sure how to code it.
Here is the validation.cs file in my wpf user control library project.

windows form used to test wpf user control that is in the dll i referenced

Here is the xaml from the user control.

<UserControl x:Class="SoftwareAssetFormValidationControl.ValidationControl"            
             Width="Auto" Height="Auto" DataContextChanged="FormControl_DataContextChanged" >
    <Grid Height="Auto" Width="Auto">
        <TextBox Height="0" Margin="0,0,0,0" Name="textId" VerticalAlignment="Top" Width="0" Text="{Binding Path=$Id$, Mode=OneWay}" Visibility="Collapsed" />
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
.NET Programming

From novice to tech pro — start learning today.