Pages

Tuesday, February 19, 2008

VS2008 Toolbox is gone

I had this happen before and had to delete my user profile from Vista. It is caused by a known issue in Windows Vista.

I found a workaround here but I still have missing menus. I'll probably have to delete my profile anyway but will need a day to copy documents to temp folder {again}

This is bogus

Wednesday, January 30, 2008

how to solve a puzzle by Micahel Hunter the Braidy Tester

I got the obvious solution as I read this puzzle

I wouldn't have gotten the other solutions because I didn't know that information, until now. Thanks Braidy Tester, I learned something useful today.

Monday, January 21, 2008

Number of Days to Copy Files

I was copying some files to a Virtual Machine the other day and a message said it would be complete in 5 days and 22 hours. It actually took about 20 minutes; good thing I didn't believe the message.

Here's a screenshot with the filename and directory erased:

Thursday, December 6, 2007

Web Service Testing

Here's some notes about testing a web service:

Web Service Request has a URL that points to .asmx; the Web Service Request has a Query String Parameter, String Body, and Header

1) open a webtest

2) right click the web test name and slect Add Web service Request; an empty request is added to localhost with an empty String Body

3) open a seperate browser window and browse to the asmx to get the details of the SOAP request for each operation (http://server/example/test.asmx)

4) View properties of request and change the URL from http://localhost/ to point to the asmx

5) Expand the request to select the String Body; enter text/xml under Content Type; in the other browser select the operation to be tested; copy the xml request from "?xml version="1.0" encoding="utf-8"? through "soap:Envelope"; go back to the String Body and click the elipsis beside String Body and paste the xml request under the HTTP body string. Then change placeholder values to actual data and click OK to save. Use arrows to navigate since this dialog does not contain a scrollbar. Enter dates in this format: 2006-03-10T07:42:00Z

6) Go back to the browser to get a copy of the URL (without quotes) http://example.com/app/UpdatePerson (located above the start of the XML request). Go back to the Web Service Request; right click and select Add Header. Enter SOAPAction under Name then paste the URL under the Value http://example.com/app/UpdatePerson.

7) Go back to the browser to get the name of the operation UpdatePerson. Go back to the Web Service Request; right click and select Add URL Query String Parameter. Change the name of the Query String Parameter from Parameter1 to some other value like op and enter the name of the operation under Value (UpdatePerson).

8) Add Validation Rules to check for text in the HTTP Response

This MSDN article explains creating a web service test in more detail

Friday, November 30, 2007

Sara Ford's Tip of the Day Sidebar Gadget

Sara Ford works at Microsoft as a Program Manager and blogs about Visual Studio. There's a VS2005 Tip of the Week and a VS2008 Tip of the Day. She used to be a test dev and has some video interviews on MSDN channel 9.

Rob Caron wrote a sidebar gadget for Visual Studio 2008 Tip of the Day. You can download it here.

This is a great resource for people like me who are new to the development environment.

Wednesday, November 14, 2007

ASP.NET __VIEWSTATE in recorded web tests - Validation of viewstate MAC failed

I'm not a developer, so I wasn't sure what was happening at first. I got a new machine, but couldn't run recorded web tests on it. There were error messages when I tried to run the recorded web tests on the new machine that were recorded on the old machine. Here's how I figured out what was happening.

The original error message didn't make sense to me until later. It said "Validation of viewstate MAC failed. If the application is hosted by a web farm of cluster, ensure that configuration specifies the same validationKey and validation algorithm. AutoGenerate cannot be used in a cluster"

At first I thought something was wrong with machine.config or web.config. I searched for the error message and read this forum post about adding changing web.config to add entries to the pages tag:
validateRequest="false"
enableEventValidation="false"
viewStateEncryptionMode ="Never"

That didn't work, so I found the request where the errors happened and tried deleting the Form Post Parameters that referred to __VIEWSTATE=

That didn't work, so I read about __VIEWSTATE this article explained that Viewstate contains user entered information encrypted in a hidden POST form field so users don't have to re-enter information after moving to another page.

Then I recorded a web test to get the updated encrypted VIEWSTATE=/whGSTdfdbdjdfy and copied the updated value to the other web tests. I also found a post that tells how to make the viewstate dynamic, but I only have Visual Studio installed on one machine now.

Monday, November 12, 2007

Don't forget to Run as Administrator on Vista

For Recorded Web Tests; the recorder bar will show up in IE but the controls are disabled unless you run Visual Studio as Administrator. Right click the Start Menu shortcut to select "Run as Administrator".

There's also check box to always run as administrator under the Compatibility tab of the shortcut. My boss told me about that today.

Here's a blog post about troubleshooting the Web Test Recorder bar: