SharpStyle Labs

Creativity is coming up with new things. Innovation is doing new things. We make software that helps you do both.

  • Pages

  • a

  • Archives

Archive for the ‘Web Development’ Category

How to easily create "test users" using Gmail

Posted by mikeg on January 11, 2008

Whenever you release a new version of any application that requires login, you need to test account creation functionality. There are a few possible ways:

  • Most likely you already have a few accounts with your gmail, yahoo, etc personal emails. You can certainly delete those from your system, but sometimes you have some test data in there that you want to keep
  • You can continue creating email addresses at any of the web email providers — that requires a rather significant amount of time as they ask you for a lot of information

This is where Gmail and automatic labels come to to the rescue:

  • Let’s say my email is mike@gmail.com
  • Gmail has a very useful feature where you can send an email to mike+anythingYouWantHere@gmail.com and that email will end up in your mailbox
  • “+” helps mimic “email alias” functionality. You can then apply filters within Gmail
  • That pretty much provides you with unlimited number of email addresses without all the hassle of setting them up

This technique is useful to automatically file emails and can also help you figure out which of the million websites that you signed up for actually sold your email address. It will not help you stop spam, but at least you will know who is responsible for it — sign up to websites using some system like this: mike+websiteName@gmail.com.

Here is help page on this subject from Gmail: http://mail.google.com/support/bin/answer.py?answer=12096&topic=13271

Posted in Development, QA, Testing, Web Development | Tagged: , | 1 Comment »

How to easily create "test users" using Gmail labels

Posted by mikeg on January 11, 2008

Whenever you release a new version of any application that requires login, you need to test account creation functionality. There are a few possible ways:

  • Most likely you already have a few accounts with your gmail, yahoo, etc personal emails. You can certainly delete those from your system, but sometimes you have some test data in there that you want to keep
  • You can continue creating email addresses at any of the web email providers — that requires a rather significant amount of time as they ask you for a lot of information

This is where Gmail and automatic labels come to to the rescue:

  • Let’s say my email is mike@gmail.com
  • Gmail has a very useful feature where you can send an email to mike+anythingYouWantHere@gmail.com and that email will end up in your mailbox
  • “+” after your real address tells Gmail to “label” that email
  • That pretty much provides you with unlimited number of email addresses without all the hassle of setting them up

This technique is useful to automatically file emails and can also help you figure out which of the million websites that you signed up for actually sold your email address. It will not help you stop spam, but at least you will know who is responsible for it — sign up to websites using some system like this: mike+websiteName@gmail.com.

Posted in Development, QA, Testing, Web Development | Tagged: , | 1 Comment »

Setting up a Microsoft Web Development Machine — Part 1: Choosing OS

Posted by sharpstyle on August 26, 2007

This series of posts will talk about setting up a development machine for development of Web Applications using Microsoft Visual Studio 2005.

You have a choice of the following operating systems:

  • Vista/Vista 64 bit
  • XP/XP 64 bit
  • Windows 2003 Server/Windows 2003 Server 64 bit

Let’s discuss:

  • 64 bit is not an option:
    • At the time this was written, Visual Studio didn’t support Edit and Continue functionality under 64 bit.
    • I wasn’t able to install Firefox (or any of its cousins) on 64 bit and if you are developing web applications, testing in multiple browsers is a requirement
    • there are a few other programs that had a problem running under 64 bit
  • Vista:
    • Only recently ZoneAlarm started supporting Vista
    • I worked enough with Microsoft products to know that one should wait for SP1
  • XP
    • If you are using a laptop as your main development machine, this is probably your best option as 2003 Server doesn’t support many important “laptop features”: hibernation, etc
  • 2003 Server
    • If you are using a desktop, my recommendation to use this as your OS due to its stability

Mike Grushin
Partner, CTO

Posted in Development, Uncategorized, Visual Studio, Visual Studio 2005, Web Development | 1 Comment »

Flex, Ajax, JavaFX, Silverlight — our view on current state of affairs

Posted by sharpstyle on August 24, 2007

We were asked to comment on the recent offerings from Sun and Microsoft that are aimed to compete with Flex. Here is our current opinion:

While there are many excellent technologies on the server-side (.Net, PHP, Ruby, Java, etc), we believe that Flex is currently the technology of choice for delivering the client-side implementation of Rich Internet Applications. That doesn’t necessarily mean that client-side of every RIA has to be implemented fully in Flex – usually it makes sense to combine Flex with Ajax to deliver the best performance where it matters. With Flex applications running in ubiquitous Flash Payer in the browser and in Adobe Air on desktop on multiple operating systems, Flex developers can leverage the same skills to deliver cross-browser and cross-platform solutions. These solutions usually utilize highly efficient methods of communication (AMF/Flash Remoting) with the server that have proven themselves over many generations of Flash, thus delivering much higher performance than industry standard SOAP/XML Web Services. It is also worth mentioning that current version of Flex (Flex 2) was officially released over a year ago in June 2006 with a rather significant update released in January 2007 and Flex 3 currently in beta.

There are a number of competing/supplemental technologies that should be mentioned and explored.

Ajax combines a number of technologies based on various JavaScript frameworks. Because of JavaScript restrictions in terms of performance and security model, Ajax is best used together with Flex. While a large number of Ajax frameworks provide flexibility, such things as maintainability of projects over long development cycles and availability of resources with appropriate skills need to be considered.
 
JavaFX is a recent announcement from Sun and it looks to compete with Flex in providing yet another framework for building RIAs. While there is a rather limited information available at this time, Sun’s inability to establish Java as a client-side technology in the past, combined with introduction of another “java flavor” (JavaFX Script) that developers need to learn, leads us to believe that this initiative will not be a serious competitor to Flex in the near future.

Sliverlight
is Microsoft’s endeavor into extending its Windows Presentation Framework into non-IE browsers and potentially non-Microsoft operating systems (currently there are no plans to support cross-platform desktop applications). While Silverlight benefits from being a subset of the Microsoft’s core framework, it is not a framework that is currently widely used. There are a number of positive things going for Silverlight: Microsoft recognized the importance of supporting cross-browser, cross-platform RIA development and made it available to a very large community of Microsoft developers. We also know how effective Microsoft is at marketing its products. We certainly see Silverlight as a competitor to Flex in the future, but don’t know how close that future is.

SharpStyle Labs saw a need in the marketplace to allow .Net developers to integrate Flash/Flex projects into the next generation of Rich Internet Application built using Visual Studio. SharpStyle Labs is currently shipping SharpStyle Neutron – Visual Studio add-in for ActionScript 2 development. SharpStyle Labs is also in a private beta of SharpStyle Neutron FLX, which allows development of Flex/ActionScript 3 projects within Visual Studio. With these offerings, SharpStyle Labs provides the opportunity to develop RIAs using a leading server-side technology (.NET) and a leading client-side technology (Flash/Flex) all within a common IDE. For more information please visit: http://neutron.sharpstyle.com.

Mike Grushin
Partner, CTO
 

Posted in Flex, Microsoft, Silverlight, Web Development | 2 Comments »

Firebug — web development evolved

Posted by sharpstyle on April 9, 2007

It is not often that I find software where in the first 5 minutes of using it, I know that it will save me a lot of time. Meet Firebug:

Firebug integrates with Firefox to put a wealth of web development tools at your fingertips while you browse. You can edit, debug, and monitor CSS, HTML, and JavaScript live in any web page.

Think of Firebug as Web Developer extension on steroids. Here are some of the features:

  • Live editing of HTML, JavaScript, CSS with immediate result
  • Visual representation of the layout for each element including margin, border and padding — this will certainly save me a lot of time
  • Monitor network activity
  • Debug and profile JavaScript
  • Powerful JavaScript console

Make sure to read documentation as there are a number of keyboard shortcuts and console macros that will save you time

Firebug is open source.

If you are looking for similar functionality in IE, there are a number of options:

~Mike

Posted in ajax, Development, JavaScript, Web Development | 1 Comment »

Flash OCX control and Visual Studio 2005 issues

Posted by sharpstyle on March 28, 2007

Cross posted here SharpStyle Neutron blog.

As I was preparing for tutorial of using SharpStyle Neutron to develop an ActionScript project and Windows Forms within one solution, I ran into the following issue: while there are a number of references on the web on how to use Flash OCX within Visual Studio 2003, there are only a handful of results related to Visual Studio 2005 and most of them document the problems that people are having.

Following the steps from this article (Macromedia – Developer Center Embedding Macromedia Flash Player in a C# Application) produce the following errors:

  • There is a popup stating that VS ”Failed to import the ActiveX control.  Please ensure it is properly registered
  • If you examine Error List, under Warnings, you will see the following

Could not resolve dependent COM reference “stdole, Version=7.0.3300.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a”.  

Failed to create the wrapper assembly for type library “AxShockwaveFlashObjects”. Exception of type ‘Microsoft.Build.Tasks.ComReferenceResolutionException’ was thrown.

The referenced component ‘AxShockwaveFlashObjects’ could not be found. Failed to create the wrapper assembly for type library “AxShockwaveFlashObjects”. Exception of type ‘Microsoft.Build.Tasks.ComReferenceResolutionException’ was thrown. 

I found the following Unable to add Flash 8 control in VS2005 – Tentative workaround blog post from 2005-12-07, but the instructions there didn’t work. After doing a few more searches I found the following forum page in French (translated page / original page)

Here is what needs to be done:

  • Open Visual Studio 2005 command prompt and execute the following:
    • aximp.exe – source “C:\WINDOWS\system32\Macromed\Flash\Flash9b.ocx”
  • This will generate the following files. Items in bold are the important ones:
    • AxShockwaveFlashObjects.dll
    • AxShockwaveFlashObjects.pdb
    • ShockwaveFlashObjects.dll
    • AxShockwaveFlashObjects.cs

  • In Visual Studio, add the references to the 2 dlls generated by aximp (I copied them from “C:\Program FIles\Microsoft Visual Studio 8\VC” to the root of the project): 

  • Add namespaces to the imports section

using AxShockwaveFlashObjects;
using ShockwaveFlashObjects;

  • And here is some sample code to display SWF
AxShockwaveFlash axShockwaveFlash = new AxShockwaveFlash();
axShockwaveFlash.Location = new System.Drawing.Point(50, 50);

this.Controls.Add (axShockwaveFlash);
//this.Show(); // Avoids InvalidActiveXStateException.

axShockwaveFlash.Movie = "D:\\test.swf";
//* it is important to set Size after specifying Movie property
//* if Size is specified before, it is ignored
axShockwaveFlash.Size = new System.Drawing.Size(20, 20);
axShockwaveFlash.Play();
 
References:

~Mike

Posted in Flash, Flash Player, Visual Studio, Visual Studio 2005, Web Development, Winforms Development | 18 Comments »

 
Follow

Get every new post delivered to your Inbox.