Prepping for Punxsutawney Phil

If I were to tell you that there is an octopus named Paul that is famous for predicting the German National Football League's 2010 FIFA World Cup wins and losses...

Would you believe me?

Well, its true. 

But I only discovered that because I went on a mission tonight to research Punxsutawney Phil...who....if you don't recognize the name is the infamous 120 year old groundhog from Punxsutawney, PA that accurately predicts whether we'll have 6 more weeks of winter or an early spring.

Next Thursday, February 2nd, Punxsutawney Phil will be peeping his head out at 7:25AM. 

At 8:07AM, the Canadian counterpart, Wiarton Willie, who is also a groundhog...only he's an albino groundhog, will be making the same prediction.

Hmmm...I'm not saying it outloud...I'm just typing it outloud, but is anyone else finding it fishy that the Canadian groundhog is waiting a full 42 minutes AFTER Punxsutawney Phil to make his own prediction?  You sneaky Canadians. 

Regardless.  I wanted to give you all a few days to prepare...

We made Punxsutawney Phil pop-ups...  Only because we're in Germany we've decided to call him GutenTag Gustav.  Hey...if the Canadians can have their own groundhog...so can we.


I call this one "toddler and Gustav in motion" - which is the only way that I seem to get a photo of this toddler these days...


Unless I catch her unawares with her groundhog...



Unfortunately, Gustav in his own version of "groundhogese" has let us know that we can expect more winter...any guesses as to how this brilliant animal figured that one out?


PS...that snow hasn't stopped me!  I dropped 3.6 pounds this week.  One more pound...and three days to lose it in to make an even 10 for the month of January.

Visit Top Mommy Blogs To Vote For Me
Read More...

When I grow up...

Madmad - "Hey mom...can you watch me for a minute?"

Me - "Sure."

I turn and see this...


Me - "What are you doing?"

Madmad - "I'm practicing being a mime.  Can't you tell?  Don't I look just like a mime?"


Me - "Oh Yeah, you look just like a mime.  Why exactly are you practicing being a mime?"

Madmad - "Well, when I grow up I want to be a mime.  If I can't be a mime I want to be a ventriloquist.  If I can't be a ventriloquist I will see if I want to be a veterinarian.  And if THAT doesn't work out then I guess I'll just have to be a lion tamer....." 

Long pause (while I try my hardest not to laugh outloud)

Madmad - "...or a chef.  I suppose that would be ok too."


When I was her age I was dead set on being a truck driver.  I figured that was the best way to see the world.  I really thought driving the big rig was a glamorous life.  I would get to go through all the states in the USA!  I would be my own boss!  I would get to drive large machinery.

Which is still a fascination today.  I've driven a big rig truck...I've steered a cruise ship...I've driven tractors...I actually considered going on a date with a scary guy while living in DC because he promised me he'd let me drive one of the Metro trains.  (I quickly came to my senses when he smiled and I realized he had no teeth.)

Still on my list include a zamboni, digging with a backhoe and a train. 

In the meantime I'm going to practice being a mime...


Read More...

Then and now...

I had a funny thought today.  I was thinking back to the year 2000...Actually, the year 1999 when it was going to become the year 2000 and there was all that speculation about what would happen with the change of the century...  There was widespread panic about computers crashing, missiles spontaneously ejecting themselves toward Russia/China/Middle East, bank accounts looted, stockmarkets crashing, and packs of wild dogs roaming the streets of Orem, Utah.

Yes...thats right...my mother was absolutely certain that there would be packs of wild dogs roaming the streets...And no...we have NEVER let her live that one down.

But, the reality is that we all got to live through something that is pretty cool...the change in a century!  And, if you are at least my age...the 80's...which is almost as cool as a change in the century.

Thinking back...I never ever would have guessed that today I would be sitting in Germany with a soldier for a husband, two kids under my roof, driving a subaru.  I even eat brocolli these days...which is a big deal for me.  I was absolutely certain that brocolli was the vegetable of Satan. 

Oh how wrong we can be...kind of like those packs of maurading dogs...right mom? 

I also never thought I (my life, my hopes, my dreams, my past) would be so transparently available to anyone and everyone via a written blog...  Of course...I also was alive and mostly grown up before Al Gore invented the internet...so its not like I was able to dream of being a blogger one day.

Which brings me to my blog...

Remember a while back when I mentioned that I wanted to upgrade my blog...make it a little fancier...try and get it noticed just a little more.  Well, I've slowly been researching and attempting to discover exactly what it is that will push me from the intimate circle of readers I now enjoy...out into the vast blogosphere...

In particular, perhaps you've noticed my OCD/ADD changes in my blog backgrounds.  I cannot find one that fits ME.  I think I've tried about 50 different backgrounds over the past week...and I've ended up with black and white because black goes with everything...right?

I'm just alerting you to the fact that you'll be seeing quite a few changes happening over the next few weeks...  Don't worry - I'm trying to make it easy to navigate.  No fancy things you HAVE to click, although if you happened to love me enough to click them or rate me or vote for me I'd surely appreciate it.

Plus, if you haven't noticed I've added "pages" to the top...I'll be adding a few more so keep an eye out.

And...if you have any suggestions or comments they would be greatly appreciated.  Even the ones that are considered "constructive feedback"...I promise not to pout or send you hate mail.  Not even anonymously.

And I promise not to sic any packs of wild dogs on you either. Read More...

I know you are but what am I...

Remember when you were like 26 8 years old and would taunt your brothers and sisters mercilessly with snappy comebacks like, "I know you are but what am I?", or "If you love it, marry it..." And my personal favorite from some joke book my sister brought home one day...

"A jerk is a tug, a tug is a boat, a boat goes in water, water is nature and nature is beautiful so thank you for the compliment."

Yeah - memorize THAT one for the next time someone calls you a jerk...

Along with those taunts (at least in my childhood dwelling) came the numerous face twisting grimaces with tongues askew and eyes crossed and fingers stretching your cheeks to appear the most hideous you possibly could be just to Drive. In. Your. Point.

Because at 8- getting the point across was very important.

And what did you mother say to you?

"If you keep making that face...(say it with me now...) your face is going to freeze that way."

I never really believed my mom that  face could do that...and then I grew up and became an actual adult. (shudder...)

And I started reading blogs and one in particular caught my eye and has been a favorite read ever since.

Attack of the Redneck Mommy is funny and serious and very real and sometimes a little crass and she's made me laugh outloud and cry buckets of tears.  And in my little world thats the makings of a good blog. 

Today she wrote about her third-born who didn't live very long in this world and was born with a frozen face.  Just like my mama told me...  Only her little guy didn't get it from making faces.  He was simply born into the world that way.

Its called Moebius Syndrome...and her blog today is very much worth sharing...so I'm passing along the fact that today is National Awareness for Moebius Syndrome...and if you take a gander - go read about Shale who, "never blinked, never smiled, never frowned."

And then make it a point to smile today. Read More...

12 days and counting...

I'm sure I've mentioned at some point how much I long to be considered a woman of mystery... with smoky eyes that allude to deep secrets and incredible adventures.

Ok...side story...I love side stories so bear with me here...I have to tell you that I was madly in love at one point with a young man named Mika (pronounced mee-kah) who actually told me I was a very mysterious woman.  Sheesh...if I hadn't already had a case of a serious crush, I would have immediately developed one just for that comment.  Too bad he ran off to Israel with the foreign service before I had a chance to show him my smoky eyes too.  (bwahahaha...I make myself laugh)

Regardless...unfortunately my lot in life is to be a very organized practical individual.  And naturally that means I'm also a planner.  Now, I've worked very hard to make myself not be an anal rententive planner.  C'mon...all you anal retentive planners out there know EXACTLY what I'm talking about.  If its NOT on the calendar its not happening.  Period.

Well, I've been searching for decades for the perfect calendar to use and I've never found it.  For a long time I followed in my mother's footsteps and purchased this giant yearly calendar that had 3X2 inch spaces for each day of the month....and for a family with seven kids I can imagine that was an absolute necessity.  but for a family of two adults and 3 stepkids that came every other weekend it was good for lighting fires in the winter in our fireplace. 

Now, I've gradually downgraded to a calendar of my own making.  I drew it on a white board.  I used permanent marker and then each month I write the days and the activities...and there is room on the side for future upcoming dates that I transfer over when we get to that month.

Hey...it works for me.

Anywho...the whole point to this is that January is coming to a close...

February is going to be here soon.

And as I was getting ready to write in my February dates i realized that there is less than TWO WEEKS before I see my husband. 

**major overreaction alert**  EEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEK!

Its been nearly eight months since I last looked into his beautiful baby blues and rubbed my fingers through is hair - which if you haven't seen a recent picture...he's decided to go a little Kid-n-Play with his hairdo.  I suppose its the soldier's secret way to "stick it" to the Army?  Or maybe not...John has always been a do-wop sort of guy...now if he starts wearing a single glove with his uniform THEN I might get worried he's completely transformed back to the 80's... 


I love it, personally...his hair, that is...  Oh...and just in case you weren't sure...Kid-n-Play is on the left and John is on the right.  (bwahahaha...cracking myself up again.)

We actually get to celebrate Snookum's day together on the 14th - that would be Valentine's day for all you traditional holiday name-ers out there.  We being John, me and an 8 year old and a 2 year old...  Bed time might come reeeaaaallly early that day.  **wink wink**

And then 4 days later (after we've raided all the valentine's day stuff for 90% off to make ours the best and cheapest ever...) we get to celebrate our 5-year anniversary.  I've got childcare all lined up and we're spending 3 days and 2 nights in the romantic wintery wonderland of Passau, Germany...where the Danube and the Inn and the Ilz rivers all meet. 


I really wish you could all be there with us.  (bwahahahahaha....cracked myself up there again...)

Did I mention that he's home in LESS than 2 weeks?  My little calendar and I are going to be hanging out a lot together over the next 12 days...

PS!  I almost forgot my accountability promise...and had to come back and edit to add this.  It was weigh in day yesterday.  I GAINED 1.8 pounds.  How much does that suck?  I'm demanding it be a gain in muscle because I've been doing "it" all the right ways.  Think my bod will listen?  We'll see...another week...another pound...hopefully gone instead of gained.

Click me every day for 12 days and you'll lose a pound too!  I promise!  No really...I do.  :DTop Mommy Blogs - Mom Blog Directory Read More...

Automobile Modification

Automobile Modification
Automobile Modification
Automobile Modification
Automobile Modification
Automobile Modification

Read More...

Zoo dreams...

Sleep...ahhhhhh...the memory of a night of uninterrupted sleep is tantalizing as I imagine my head on my pillow, hair matted and all crazy looking, arm numb from sleeping on it wrong and cheek creases from my pillow because I literally haven't moved for 10 hours.

Alas....that truly is just a memory.  Nowadays if I get 3 hours of uninterrupted sleep I consider myself pretty darn lucky.  I don't know if it would be any better if my deployed soldier was here instead of bunking down in his little tent in Afghanistan.

My nightly wake up call is always the fault of little Bella.  She's got crazy animal dreams in her little head and right around 2AM she is shouting and hollering all about them. 

I'm guessing that even if John were home he'd sleep right through her hollering...especially now that he's learned to sleep through the noise of a chinook helicopter landing... 

Sheesh...the more I think about this I believe this deployment has brought me a lifetime of nightime toddler duty.  (Adding that to my list of reasons why deployments stink!) 

But...back to my little stars in the sky dreamy zoo keeper...Luckily these dreams are not nightmares.  She's not actually afraid of the animals.  She's only once woken up in tears and that was when there were monsters...but more often than not she's apparently had a great dream and wants to tell me all about it. 

Just take this past week as an example...

Sunday it was monkeys.  2AM my eyes pop wide open when I hear, "Mama! Mama! Monkey eating nanas!" 

Monday it was snakes.  2:45AM I am roused from my sleep with, "Mama!  Mama!  Snake SSSSSSSSSS!  Mama!  Snake SSSSSSSSSS!"

Tuesday it was elephants.  2:17AM a trumpeting, "Pbbbbbbbbbbbbt" followed by, "Mama!  Elephants!  Elephants!  Pbbbbbbbbbt"

Now here it is Wednesday and I'm wondering what animal from the menagerie in my daughter's little mind is going to waken me tonight.  I'm kind of hoping its crocodiles.  She's quite taken with crocodiles these days and I can imagine her excitment would come with lots of clapping and exagerrated gestures of a crocodile's mouth snapping closed

I probably didn't help anything by reading her "Two in the Zoo " (a fabulous book for toddler's in case you haven't ever seen it...) about 15 times before bed tonight...

And so when the shouting starts...what do I do?  I've tried rolling over and ignoring her...she amazingly just gets louder.  I've tried scolding...but really, its so cute when she's babbling about a penguin that even at 2AM I can't really be mad at her.

Instead, I roll myself out of bed, trip my way into her room and let her tell me all about her dream while I snuggle her back down in her bed, turn on her twilight turtle and lullaby CDs and send her back into dream land...

Goodnight...

Top Mommy Blogs - Mom Blog Directory Read More...

Just because...

You ever get one of those emails that came just at the right time and on the right day and with exactly the right sentiment you needed to hear?

I got one of those the other day.  It came from my sister and it put a big smile on my face and then a little tear dripped from my eye (crazy eyeballs just like to shed those occasionally)...

It wasn't a long email...but it reminded me of why I love my family so much. 

It doesn't matter how far away I am or how long its going to be until I see them next.  I can sit down next to any one of my five sisters.  Yes, you heard me right...FIVE sisters and talk to them like a best friend.

And lets not forget my big brother...  The one who was such a stud in highschool that when I skipped class and got caught I told my teacher I was "doing something for Ray" and got off scot free.  Of course I had to run like mad to make it to him before my teacher did to confirm he was going to uphold my alibi...

Yeah...that big brother who I trust completely...

The thing is... I've always had a fierce independent streak.  I was the kid in college that would go a month (or two) without calling home while my roommates would be on the phone at least every Sunday...  And you have to remember that I'm SO old that they didn't have cell phones way back in the early 90's like they have today.

Then my mom would track me down to make sure I was still alive and had enough top ramen noodles for the week...and she'd sneak a $100 bucks into my bank account so I could splurge a little...

And when I left home for good...it wasn't that I didn't miss home...or miss my family...its more that there was an adventure waiting for me that I just couldn't wait to experience.

And even now...I love being in Germany.  I look forward to the challenges of speaking another language, translating celsius into farenheit, driving like a mad woman on the autobahn... 

But then comes that "just because" email  that touches my heart and reminds me of home and reminds me of all the fun I had growing up and the rope swing in the backyard, and the pear and apple trees and hiding in the grape arbor and playing kick the can until late at night and torturing our neighbor kids with homemade bows and arrows and riding like wild banshees down the big hill on our bikes and playing king of the mountain on the sawdust pile and calling "not it!" and snuggling on the pillows watching every musical ever made, little house on the priarie, Jacque Cousteau and Dukes of Hazards, racing on foot up the hill every Sunday morning with nylons in hand while my mother, who firmly believes if you aren't 10 minutes early you are late, yells out the car window as she continues to inch along just fast enough to make it difficult to catch her, "You never know when you have to jump into a speeding car!", kneeling around our family prayer table each night and rolling my eyes and heaving big sighs when dad has to say AGAIN, "I love you.", and snapping out tunes with the elastic in my underwear so my sister and I can play "guess that tune"...and suddenly...I'm reminded exactly how lucky I am. Read More...

Clear and then disable controls in infopath

This is simple for reading, but difficult to implement in infopath forms. To disable controls we have to use “Conditional Formatting” option of a control. To clear content of a control then we have to use “Rules” option of a control. But, the sequence of execution of these two causes some problems. Take below scenario.
I have a table and each row the first column contains a checkbox and all other 4 columns are having date field, textbox, drop down and date field respectively. Now, the logic should be this.
  1. The default state of checkbox is selected.
  2. When user enter some data in all other 4 fields and now he thought the row should not allowed to enter data then he deselect the checkbox. When user deselects then the first thing should happen is clear the content in all the 4 controls and then all controls should be disabled.
  3. When again user select the checkbox then the controls should be enabled.
This is what to be happen and the first trail when I tried to implement I did below things.
  1. On all other 4 controls I added a rule that when checkbox selected state is false then set the current field to empty.
  2. And then I added a conditional formatting on them to disable when the checkbox state is unchecked.
I did deploy them to SharePoint and when I tested, surprisingly they are not working as expected. The controls are going to disable state but not clearing content in them when I deselect the checkbox. And researched and found that the Rules are not executing. [Didn’t find the reason yet.] And then thought about for alternatives and came up with reverse way. That is, applying rule on the checkbox instead of other controls.
Earlier, I have applied rules on the each and every individual control which needs to be cleared based on checkbox state – Which doesn’t work. Now, I have applied the same logic but applied rule on the checkbox [As there are 4 controls, 4 times I have added set field to empty] and which is working like charm.
So the conclusion I want to tell to you is, when I apply conditional formatting and then rules something is causing problems in the sequence of execution. So, depends on what your control, rules needs to be executed apply the rules on that control only. That should work perfect. Read More...

Date validation in Infopath forms

In SharePoint infopath forms I need to implement one thing which was a bit tricky as it is not the default supported by infopath forms. The requirement is like this: The date fields on form should not allow date plus/minus 5 years from current server date. For this, so many people recommended to implement validation events in c#. But, my form contains 40+ date fields. That is not possible to implement events for each control. But, when I looked into all option there is an option called “Data Validation”. But, there is no direct option available to implement this requirement.
After thought about sometime got wonderful ideas. Below is the implementation finally came up with.
  1. Select the date control and right click.
  2. Select the option “data validation”.
  3. Click on Add to add a new validation.
  4. From the window, the first thing we have to check is “Whether the field is blank or not.” Because once it is not blank then only we go further.
  5. And next thing is, validate the expression. User entered date is plus/minus 5 years from current date.
image
If you observe the first condition I have used is an expression as there is no direct way to validate the date according to my requirement.
Expression we have to use: msxsl:string-compare(., xdDate:AddDays(xdDate:Today(), 1825)) > 0 or msxsl:string-compare(., xdDate:AddDays(xdDate:Today(), -1825)) < 0
And second condition is just the field is not blank then only display “Invalid date” error on screen.
Note: Remember, the expression is very simple that adding/subtracting the 1825 days [5 years] to current date. Depends on your requirement please change the value accordingly.
The last reason why I have used the expression instead of the simple statements is the logical operators. The condition should be validated for this requirement is “((selected date > today + 5 years OR selected date < today – 5years) AND field cannot be blank)”. The brackets are very important, the sequence of executing conditions and logical operators are important. So, to achieve this in infopath forms the only way is implementing expressions. Then only it treats it as the way we want. Enjoy the complex and nice series of posts on infopath and sharepoint coding. Read More...

Delete event receiver from a SharePoint list

In my previous post, we saw how we added an event receiver to a list. Now, we will see how to delete the existing event receiver on a list.
private void DeleteEventReceiverFromAList(string siteUrl)
{
using (SPSite site = new SPSite(siteUrl))
{
using(SPWeb web = site.OpenWeb())
{
try
{
SPList list = web.Lists["myList"];
if (list != null)
{
string className = "EventReceiverClass";
string asmName = "EventReceiverAssemblyName, Version=1.0.0.0, Culture=neutral, PublicKeyToken=a865f0ecc234ea51";
web.AllowUnsafeUpdates = true;

int receivers = list.EventReceivers.Count;
bool isAddedReceiverExist = false;
bool isUpdatedReceiverExist = false;
for (int i = 0; i < receivers; i++)
{
SPEventReceiverDefinition eventReceiver = list.EventReceivers[i];
if (eventReceiver.Class == className && eventReceiver.Type == SPEventReceiverType.ItemAdded)
{
eventReceiver.Delete();
break;
}
}
}
}
catch { }
finally
{
web.AllowUnsafeUpdates = false;
}
}
}
}
In this code also, there is nothing to explain very detail. Please let me know if you have any questions.
Read More...

Add event receiver to a SharePoint list

This is very generic and everyone knows how to add an event receiver. But, usually we attach the event receiver on a list template, site etc. This post deals with adding event receiver to a specific list.
private void AddEventReceiverToAList(string siteUrl)
{
using (SPSite site = new SPSite(siteUrl))
{
using (SPWeb web = site.OpenWeb())
{
try
{
SPList list = web.Lists["myList"];
if (list != null)
{
int receivers = list.EventReceivers.Count;
string className = "EventReceiverClass";
string asmName = "EventReceiverAssemblyName, Version=1.0.0.0, Culture=neutral, PublicKeyToken=a865f0ecc234ea51";
web.AllowUnsafeUpdates = true;
bool isAddedReceiverExist = false;
for (int i = 0; i < receivers; i++)
{
SPEventReceiverDefinition eventReceiver = list.EventReceivers[i];
if (eventReceiver.Class == className && eventReceiver.Type == SPEventReceiverType.ItemAdded)
{
isAddedReceiverExist = true;
break;
}
}
if (!isAddedReceiverExist)
list.EventReceivers.Add(SPEventReceiverType.ItemAdded, asmName, className);
}
}
catch { }
finally
{
web.AllowUnsafeUpdates = false;
}
}
}
}
This is very straight forward code and hope you got it. Read More...

Hide content types from a SharePoint library through coding

Please read the post here.

Read More...

Change content type order in NEW button of a SharePoint library

This is continuation of my previous post. After you read that post you get clear understanding of how we added the content types to a library through coding. But, what if there is a requirement we need this content type order to be shown when I select the NEW button from the list tool bar or hide some content types? Then again we need some sort of code which does that for all existing lists as we cannot change manually if there are plenty of webs in a site.
private void ChangeOrHideContentTypesInALibrary(SPList list)
{
list.ContentTypesEnabled = true;

SPFolder folder = list.RootFolder;

List<SPContentType> orderedContentTypes = new List<SPContentType>();
foreach (SPContentType ct in folder.ContentTypeOrder)
{
if (ct.Name.Contains("ContentType1") || ct.Name.Contains("ContentType2"))
orderedContentTypes.Add(ct);
}

folder.UniqueContentTypeOrder = orderedContentTypes;
folder.Update();
}

If you observe the above code, then the variable orderedContentTypes is what having the content types of which we need to show in the NEW button of the list toolbar. In which order we add the content types to this variable, that order they will be added to the list and shown on the toolbar. And second thing is out of 3 content types available in the above logic we have added only two to the variable. So the third content type will be hidden from the toolbar. And the last two lines in the above function are to update the list with the latest content types order.

Hope this gives you clear idea on how to order and hide content types on a list/library. Read More...

Add content type to a SharePoint list or library through code

In one of my SharePoint projects, there is a requirement like a SharePoint site has 140+ sub sites and each web has 2 lists which I need to update. There are 2 content types which are inheriting by each list and now I have to add another through coding. It is very difficult to go through all webs and each list in each web and manually add it. So, thought of writing a simple script which will loop through them and update them. So, here is the code I came up with.
private void AddContentTypeToLibraries(string siteUrl)
{
List<SPContentType> contentTypes = new List<SPContentType>();
using (SPSite site = new SPSite(siteUrl))
{
using (SPWeb web = site.OpenWeb())
{
contentTypes.Add(web.ContentTypes["ContentType1"]);
contentTypes.Add(web.ContentTypes["ContentType2"]);
contentTypes.Add(web.ContentTypes["ContentType3"]);
}
foreach (SPWeb web in site.AllWebs)
{
try
{
web.AllowUnsafeUpdates = true;

foreach (SPList list in web.Lists)
{
if (!list.Title.Equals("MyList", StringComparison.InvariantCultureIgnoreCase))
continue;

for (int i = 0; i < contentTypes.Count; i++)
{
AddContentTypeToList(contentTypes[i], list);
}
}
}
catch { }
finally
{
web.AllowUnsafeUpdates = false;
web.Dispose();
}
}
}
}

void AddContentTypeToList(SPContentType ct, SPList list)
{
if (list.ContentTypes[ct.Name] == null)
{
list.ContentTypes.Add(ct);
list.Update();
}
}
The first method is what we are looping through all webs and go to each list and try to add a content type. And the second method is before adding a content type to a list, we are checking whether the content type is already there or not for that list. So, we are checking for that condition and if find the content type is not already attached to the list then only we are adding to the list.

Hope you understand the logic and how we need to implement it. Read More...

Rain Rain Go Away...

I feel like that little girl in the Cat and the Hat that is sitting at the window peering outside just watching and waiting for the raindrops to go away....and still they pound down....raining and raining and raining...

I grew up in the Pacific Northwest so I should be used to this weather, right?  I mean...its not really raining unless there are puddles...if its light we say its misting...and who needs an umbrella when its misting?  I grew up thinking 50 degrees was shorts weather...  winters meant ice and not snow...  burkenstocks ARE worn with socks... the ocean is supposed to be freezing cold, but once you're numb you don't really think about it anymore...I grew up feeling guilty for throwing anything actually into the trash (recycle!)...I had no clue what humidity meant....to me it was more misting...dressing up means jeans with no holes in them...and my mom has actually made salmon meatloaf.... (DO NOT, I repeat, DO NOT inflict that same torture meal on your children I beg of you.)

So when I look out the window and see the rain here and feel...well...depressed...  I figure I've got to put on a

DANCE PARTY!

If we took a holiday...Took some time to celebrate...Just one day out of life....It would be, it would be so nice

Everybody spread the word...We're gonna have a celebration...All across the world...In every nation....It's time for the good times...Forget about the bad times, oh yeah....One day to come together....To release the pressure...We need a holiday

You can turn this world around...And bring back all of those happy days...Put your troubles down...It's time to celebrate...Let love shine...And we will find...A way to come together...Can make things better...We need a holiday

I normally would have just put a line or two of a song, but Madonna just seems to require a whole paragraph or two.  Not that her lyrics are extraordinarily meaningful, unless you think you need a holiday and I DO.

Plus, who would have ever thought Madonna would have the answer?  Actually - thats a rhetorical question because I think I can distinctly remember thinking Madonna was (and is) the bomb.  Madonna came right after my Michael Jackson phase.  My sister had a poster of him in our room - the one where he's in his black pants and wearing the yellow jacket.

PS...I kissed that Michael Jackson poster every night before bed....

PSS....just to keep in mind my accountability requirement.  I lost 2.6 pounds this week.  Go me. Read More...

UDCX files in Sharepoint Infopath and dynamic queries

Confused? Can we use dynamic queries in the infopath and UDCX combination? UDCX are meant for not writing any code to get data from database and to show it up the retrieved data on the infopath form. They allow only STATIC queries. Just straight SQL or SPROC names  and parameters to it. But, I got a requirement where I need to pass some dynamic values to the query/SPROC at runtime and gets the data and loads the data on the form. Can I achieve that with same UDCX connections and same architecture?
YES, There is a way to do this. The things to note here are:
  1. Using UDCX connections, we have saved all the connection data, query data and credentials data on a single file in SharePoint list/library.
  2. Query should be correct and executing without any issues [Otherwise infopath cannot download the resulted schema]. For example, you want to get the user by user name then you may created SPROC with name "GetUserByUserName" and in your UDCX file you give the query tag as "<udc:Query>EXEC "dbo.GetUserByUserName" 'DEFAULT'</udc:Query>". We know there is no record in database with the name "DEFAULT". But, this is what we have to give as default query. [This is what we will change in the c# code dynamically.]
  3. Read this connection, query in the infopath c# code.
  4. Change the query information in which way you want in code.
  5. Execute the query.
  6. Reset the UDCX connection information back to original.
  7. It will automatically refresh the control data depends on the latest result set after we executed from the C# logic.
So, I believe you got complete picture of what we are going to do. This is very simple but difficult to get the idea. With this implementation I solved the big problems what I had.
To execute the below code I am assuming there is a UDCX connection file available in a SharePoint library and your infopath form is allowing c# code.
//Get the connection details by connection name 
AdoQueryConnection adoConnection = (AdoQueryConnection)DataConnections["Get_User_Details"];
if (adoConnection != null)
{
string orgCommand = adoConnection.Command; //To read original command
int index = orgCommand.IndexOf("DEFAULT"); //Find where the keyword "DEFAULT" in the command string
string SPROC = string.Empty;
if (index > -1)
{
try
{
SPROC = orgCommand.Substring(0, index); //Get only the SPROC name.
adoConnection.Command = string.Format(SPROC + userName + "'"); //Append user name to the query.
adoConnection.Execute(); //Execute the final query. This is what the command which contains actual parameter value instead of DEFAULT string.
}
catch { }
finally
{
adoConnection.Command = orgCommand; //Should not forget to write this. We have to do this.
}
}
}
Things to note:
  1. The connection name "Get_User_Details" is the connection name from infopath form [Managed Data Connections option].
  2. As we are reading from existing UDCX connection file, we are not hard-coded any of the connection strings or queries.
  3. userName is the string variable which holds the user name which comes at run time. You have to write some logic to get these in your code.
  4. Read the query and replace the dummy parameter values with the original values.
  5. Execute the connection.
  6. In finally block, we are resetting the command back to original.
That's it!!! If you are binding this information to the textbox then you should do one final thing as shown in below figure.
image
The checkbox in above figure "Update this value when the result of formula is recalculated" and applies to only if you use the formula.

We are done. The data now comes from database and passed the parameters to database dynamically, used UDCX connection file and did not hard-coded any of the connection, query information in code. Very clean right?

Hope you understood it well and liked it. Read More...

Using Variables in TOP clause in T-SQL

This is what I want to post as I heard so many people are facing this issue. We can use variables in T-SQL queries but, there are requirements that we may select only the top 5 rows or 10 rows or n rows from the result set and use them wherever needed. So, below is the implementation we have to use to achieve that.

  1. One way could be using a variable, which saves the complete t-sql query in it and execute that total query.
  2. Second way will be pass the variable dynamically to TOP clause.

I do not think the first way is feasible. So, I prefer to go to second way and below are the implementation details.

SQL SERVER 2005:

DECLARE @TOP INT;
SET @TOP = 10;
SELECT TOP (@TOP) * FROM [User]

If you observe the variable is what storing the value of how many values we need to select. from the table And the last statement is what the final query which does what we needed. Remember the brackets () around the @TOP variable are what must and should. I also failed to write the query very first time as I forgot to place the brackets around the @TOP variable.

Earlier Versions: SQL SERVER 2000:

DECLARE @TOP INT;
SET @TOP = 5;

SET ROWCOUNT @TOP;
SELECT * FROM [User];
SET ROWCOUNT 0; --DO NOT FORGET TO WRITE THIS. VERY IMPORTANT

There is nothing tricky here. Just setting the ROWCOUNT internal variable to the required value is what works for us. And the very important thing is do not forget to reset the value of ROWCOUNT back to 0. Otherwise it effects the other result sets which comes after these T-SQL statements.

I think you got what I am trying to say here and enjoy the nice tips and posts. Read More...

Chug it!

I'm sending kudos out to my mom tonight.  Why?  She made me drink water.  Thats right.  Water. 

I love the stuff.  I hear people say, "I hate water."  or "Water is boring."  These, I fear are those that perhaps are searching for eternal excitement even in their beverage selection?  Maybe?  Perhaps I'm being unfair? 

All I know is that I'm drinking about a gallon a day right now.  Yes, literally a gallon.  I know this because I fill the jug up at night and drink it down all day and my last glass of water before bed empties it to be refilled. 

So - just a few little things about water.

1.  When I am really grumpy - offer me some.  It most likely is the problem.  Especially if we are out and about and I didn't bring a water bottle.  And if I snap at you for suggesting it don't feel bad.  My mood will change after I get some in me.  Oh, and sorry in advance for snapping at you.

2.  Snopes.com debunks the myth that you need to have 8 glasses per day to not be chronically dehydrated, but they DO tell you to take in as much as you put out in sweat and spittle and other forms of leakage from your bod...  I'd say the 8-10 glasses is a good rule of thumb.

3.  Water is supposed to make your skin super soft.  I'm gonna test that theory when John gets home for R&R in THREE WEEKS.

4.  Your brain is made up of 75% water, your blood 82% and your lungs nearly 90%.**

5.  If you don't drink enough water your body holds onto it like a cactus would in your hips and thighs.  Unfortunately I can't use that as an excuse for the extra plumpage emanating from either of those areas, but it does make sense for why when people finally DO start to drink it they drop water weight pounds.**

6.  A gallon makes you have to pee.  A. Lot.

The end.

**Discovered while reading an article on Sparkpeople.com.



Drink Water and click me!
Vote for me @ Top Mommy Blogs - Mom Blog Directory Read More...

Art Therapy

I signed Madmad up as a test subject for a college student's master's thesis on art therapy.  Essentially all she had to do was draw three pictures and then answer a few questions about them.  The idea behind the thesis is whether there are similarities in children of deployed soldiers in the themes that might be found in the drawings - thus leading to similar psychological issues found in children of deployed soldiers...

First, Maddie got to draw whatever she wanted...she chose to draw a sick elf.  HA!  I can just imagine what THAT says about the psychosis of our family.  ha ha ha

"Dear crazy family,

Your daughter's idea of something to draw was an elf with the chicken pox.  Have you ever heard of counseling?"

Second she had to draw a picture of our family doing something together.  She drew John in an airplane waving at Maddie, Bella and I  who were on some green grass playing soccer.  Veeeerrrrryyyy interesting.  At least, when I put on my armchair phychology hat...why wasn't John part of our family activity?

Instead of kicking a goal he was up in a plane waving at us while WE played.  Its a definite sign that he's not "here" in the sense that he's an active part of our family.  At least he was hovering around in mid-air in an airplane and not with angel wings or some sinister thing like that.

And at least we were out doing something active and not sitting around the latest episode of Elmo's world...which seems to be all we watch these days on the tube.  That could have been embarrassing, but it would have been harder to have John in an airplane while we're sitting around snacking on popcorn watching a little red furry monster sing la la la la...la la la la....Elmo's World!

Third, she got to choose what she wanted to draw again.  She chose to draw a princess with a bunch of hearts around her...fairly standard fare for an 8 year old girl, I think.

I don't get to know the results until the master's paper is written, but I'll be interested to learn what she has to say about the mind of children of deployed soldiers.  I think Maddie is pretty well adjusted as far as that goes, but when you add in that I'm STEPmom ...then you start to think that this kid is far away from BOTH her birth parent. 

I can't bring myself to say "real" parents...because the truth is I AM her real parent.  Now I could embark on a long lecture on stepmoms (and dads) and the recognition they deserve for playing a parenting role regardless of the stupidity of the court system or the negativity in birth parents toward stepparents and vice versa...  I don't want to undermine how HARD it can be for us adults to get along, but the truth is that if you allow a stepparent to be a parent it will almost ALWAYS be a good thing for your kids.  They will feel loved and cherished and secure in both homes and by both sets of adults in their lives...  And yes, I know there are always exceptions...just like there are birth parents that I could point out that have never been allowed to reproduce.  Ok...off my soapbox and enough said.
Just know that I love that little girl.  I'm glad she knows that.


C'mon...give me some love clicks...
Top Mommy Blogs - Mom Blog Directory Read More...

Visual Studio get pubic key token through external tools

This is very needful post. Most of the times in general development we work on class library projects which outputs DLL at the end. To use them we may need to know the Public Key Token of the DLL and use it wherever needed. We can know the Public key token either through the command prompt SN.EXE or by deploy it to GAC. But, what if you have some tool available and displays the Public key token within Visual Studio?

  1. In Visual Studio, go to Tools, and chose External Tools option as shown.'image
  2. You will be open up with a new window and enter the details as shown below.
    1. Title as “Get Public Key Token”
    2. Command as “C:\Program Files\Microsoft SDKs\Windows\v6.0A\Bin\sn.exe”. Remember, if you installed Windows SDK then the above location works, otherwise please chose the location where SN.EXE presents.
    3. Arguments as “-Tp "$(TargetPath)"”
    4. And uncheck all checkboxes at bottom and check only the option “Use Output Window”.
  3. At the end the settings should look as shown below.
    image
  4. Now, click OK button and go to tools, you will see there is a new menu item added in the list as shown below.image
  5. So, we are all set to use the tool now. Once you build the class library project, then just click on this “Get Public Key Token” option.  From the output window, you will see the BLOB of the DLL and public key token as shown below.image

That’s it. This is very helping one to me. Hope you also like it. Reference

Read More...

The first of many...

The first of many blogs about my fatness.  Oh yeah.  I said it.

In case you didn't already know, I'm a sparker.  What that means is that I identify myself in part by a website I like to frequent and a website that has done great things for me in the past.  Its kind of like being a "trekkie" or a "tubie" or something like that.  (P.S...I totally just made up tubie...as in youtubie...did you get it?  ha ha ha)  Only for me - its Sparkpeople. 

So, I have some good friends on that sight and we essentially motivate each other to lose weight.  Only the thing is that unless you are really feeling it - you yo-yo...which, I hate to have to admit this now....is what I did all last year.  Up and down ...up and down.

But at the new year I decided to scare myself straight.  So, I got online and read all about Type 2 Diabetes.  I'm prone to being diagnosed with it.  I had gestational diabetes...I am overweight...I like carbs...  And scare me it did.

So - here I am at the end of week one and I lost 4.6 pounds this week!  Wooohooo!

How did I do it? 

1. I ate right.
2. I exercised daily.

Sheesh.  I hate it that those back to the basic methods are the ones that work.  But they do.

I checked myself out in the mirror today to see where the "nearly" 5 pounds left from.  I'm thinking it was my left foot.  Weird, right?  But my left foot slipped into my boots much easier today than it did yesterday.  And I was wearing thicker socks.  (Aren't my powers of deduction stupefying?)

Sparkie McSparkster signing out...4.6 pounds skinnier... Read More...

Seven with one blow...

Remember the story about the little tailor who killed seven flies with one swat and it got turned into seven giants with one blow?

Well, our 7th giant fell today.  Seven months of deployment behind us...commemorated with a morale call from John where he told me he loved me and missed me and was proud of me...

...and the tears started rolling.

Seven months sounds so...well, so do-able when you type it out like that, but lest anyone not realize how LONG deployments really feel - we're talking about  28 weeks - two semesters of college - over 1/2 year - 7 major holidays - 217 days... 

Pick your poison...  I personally like to count the days when I'm feeling bitter or lonely or sad and want to wallow a little bit.  TWO HUNDRED SEVENTEEN DAYS. 

I just yelled that at you.  Thats how I wallow.  I may have even done a little heavenward fist shaking for emphasis...

In one month from today he should be home for R&R.  In one month he should be laying on the couch with his head in my lap letting me play with his hair while the girls snuggle beside him or play near us.   THAT sounds like heaven to me.  THAT sounds like the best day in the whole world.

My outlook on what Heaven is has changed drastically since this deployment...it used to include bonbons,  a perfect body that never required shaving or exercise, the ability to fly and Pantene hair - you know...the hair that shines and swirls around your face?

Now I just want to hold John in my arms and play with his hair.  Thats good enough for me...let me be lumpy, plumpy, hairy,  whatever...as long as I've got him close to me. 

So, if you can't tell, I'm lonely tonight.  I'm in the mood to cry.  I don't feel strong.  I don't WANT to do this anymore.  I just want it to be DONE already.,

But until then...and for today...at the very least I can say that I killed 7 with one blow... Read More...

Time out!

Potty training - Check!
Temper tantrums - Check!
Time outs - Check!

I've recently been giving Bella time outs when she is really stubborn and refuses to do what I ask.

Yes, I know I'm really stubborn and if you tell me to do somthing I will most likely refuse (if I'm irritated at you...), but I'm not TWO.  And I'm sure when i was two my mom put me in time out once or twice.

So, its been going great...She's actually only had to sit in time out three times total.  The very threat of it makes her scowl and say, "Ok mama."

Until tonight.

Me:  Isabella, we already read Sooo Big Elmo three times and I told you no more stories because its bedtime.

Bella:  No mama!  Nooooooooooooooo!

Me:  Yes, Bella.  Lets put the books away...

(imagine grown woman struggling desperately for control of Soo Big Elmo storybook with toddler when its very apparent toddler is winning the struggle.)

Me:  Bella!  Let mama have the book!

Bella: NO!

Me:  Do you want to sit in timeout?

Bella:  (thinks for a minute, unzips her pajamas and sticks Sooo Big Elmo inside) Yes Mama!

(Toddler jumps off couch and sits in her time out chair, happily removes Sooo Big Elmo from her pajamas and starts to read it again.)

Me: (laughing)  Ok, ONE more time...

I'm such a pushover.  I'll bet my mom was too.  No wonder I'm still so stubborn today. Read More...

Accountability...

ac·count·abil·i·ty noun \ə-ˌkaun-tə-ˈbi-lə-tē\

Definition of ACCOUNTABILITY
: the quality or state of being accountable; especially : an obligation or willingness to accept responsibility or to account for one's actions.

And in my case I'm talking about New Year's Resolutions.

Normally I spend a bunch of time writing down a long list of things I need to improve, but I'm taking a different approach this year.  This year I have TWO resolutions.

1.  I will learn German...  Ok...so thats really all I need to say about that one.  I was going to write a paragraph about the who what when where and why's, but I think this one is pretty self explanatory.  What I WILL say about this one is that its pretty embarrassing to squeak out my germenglish language...perhaps you remember my faux paux about ein leetle shpoona?   I will never live that down.  Its almost as bad as when I pronounced chihuahua as chi hooah hooah...I had no idea thats how you spelled the Taco Bell dog.  Or...how about this one...I was playing online scrabble against someone and said to John, I know what a tictac is, but whats a tactic?  Oh man...he still teases me about that...but I digress and my resolution is to learn German...not English.  I'll keep that one for another year.

2.  I will get healthy.  Woah...I know...right?  Thats a BIG one.  See why I only have two resolutions this year?  I've broken it down into some mini-goals that I'm tracking by week and month...the two biggest being eating better and exercise.  Yeah yeah yeah... I KNOW I put this resolution every year, but I've got some big plans riding on it this year.  AND...just to be accountable I plan on once per week marking my progress...right here on this blog...for all the world to see. 

Lucky you. 

Happy New Year!



And your resolution is to CLICK ME!
Visit Top Mommy Blogs To Vote For Me! Read More...

Virgin America tackles cross-identity marketing

I just took a flight on Virgin America from San Francisco to Toronto. With the holidays, Google Chrome and Virgin America have teamed up to provide inflight WiFi for free, so I was more productive on the flight than any flight I have taken before. I’ve become a big fan of Virgin America as they seem to be innovating quite a bit on the inflight experience. At the same time, an interesting thing happened that caught my attention and made me wonder about their innovations in the marketing realm also. While it might have been a coincidence, I suspect that it was not and they are pushing the frontiers of cross-identity marketing.

I purchased a meal on the flight (seat-back TV with touch-screen food ordering, nice.), and as part of that I asked for a receipt, and typed in my email address. I’m always a fan of seeing what various companies do with their marketing, so I provided permission to include me in their marketing database. Sure enough, within 30 minutes, Twitter notified me that Virgin America was following me. As I had just engaged with them, this was not something I saw as intrusive, so I of course followed back. Now they have opened up a new channel of interaction with me.



Technologically, I’m guessing this was fully automated. Their follow notification says they use Sprinklr, which may offer this capability, I’m not sure. Regardless of the exact technology used by Virgin America in this case, the concept is simple. All that is needed is to recognize the match between different identities (my email address and my Twitter handle), and then follow.

The point, however, is interesting. People today exist, and communicate across many different identities. The role of marketing is essentially one of communicating based on understanding of a person and their identity. If you, as a marketer, in B2B or B2C are not doing your best to jump on opportunities to identify different identities, and then take the needed steps to engage, you may be missing a significant opportunity to broaden your engagement with your buyers throughout the overall revenue engine.

Are you, as a B2B marketer, exploring techniques similar to this? Do you identify and engage with your buyers across a broader set of identities than you did before? Is it working for you? Read More...

2 going on 16

I got "the look" from her today.  Yep - THE LOOK.  Of course...the fact that she's not wearing any pants really kind of kills the effect... wouldn't you say?


Plus...I had to give her the look a little later that day when I discovered little nibbles taken out of every mini-muffin in the house...

Oh little mousy.......



Top Mommy Blogs - Mom Blog Directory
Read More...

Happy New Year!

I would like to announce that as of 10:49PM on January 1st I have succeded in keeping ALL of my New Year's Resolutions!  Just 364 more days of this and you will be amazed at the increased beauty, wit, style, intelligence and dramatic flair I exude.

Seriously.

Hey...stop laughing.

The reality is I rang in the New Year watching X-files with a little glass of bubbly fanta and a kazoo.  Yep - we got really wild around here.

The girls had a long day and made it until the late hour of 8:36 where the crying and drama got to be so much that Madmad actually ASKED to go to bed.

So, let me lift my glass of Fanta and blow a little love through that kazoo and wish you all a very happy new year.  May 2011 bring you magic and wonder! Read More...
Related Posts with Thumbnails
GiF Pictures, Images and Photos