Welcome to .net2go Sign in | Join | Help

Emad on Web Technologies

A technical blog focusing on .net and Microsoft technologies. Topics such as asp.net, AJAX, SQL, InfoPath, SharePoint and many others are covered.
Best WordPress Theme Ever

This has got to be the best WordPress theme I have seen so far.  The theme name is WP-Vybe and was created by Solostream.  I have bought several themes from solostream before and used them at www.thetechbrief.com and www.sofachip.com.  I have been very happy with them but it is type to upgrade to WP-Vybe.

vybescreen

WP-Vybe has the following features:

  • Theme settings page in your Wordpress control panel (see screenshots below).
  • 2-column or 3-column layouts.
  • 10 different color options with control panel setting for further customization.
  • Optional featured article glider for home page.
  • Gravatar integration.
  • Optional banner ad integration.
  • Optional built-in post thumbnails.
  • Optional logo/header image integration via control panel.
  • Built-in site search.
  • Built-in drop-down navigation for sub-categories and sub-pages.
  • Built-in author page and author profile with Gravatar support.
  • Widgetized sidebars.
  • Comment and trackback separation.
  • Post author comments highlighted.
  • Basic SEO techniques integrated.
  • Original Photoshop files (PSDs) available for download via control panel.

It is also reasonably priced at $99 for a single license, $199 for a multiple use license and $299 for a developer license.

The best feature though that really makes this worthwhile for me is the control panel.  You are able to customize pretty much everything in the theme through the control panel without having to ever edit the themes.

image

If you own a blog you should get yourself a copy of this theme or you can get it for free by writing a review

Technology Blogs and News Overload

There are so many technology related blogs and websites out there that it is hard to keep track with all of them tech crunch, engadget, mashable, etc...  If I don't check my RSS feed for a day, it gets filled up with 500+ posts from 2 or 3 sites...  That is just too much.

That is why I decided to create my own technology reviews and news website The Tech Brief.  It is meant to have short and to the point articles covering software, websites, gadgets and pretty much anything digital or technology related.  We try to publish 5 or less articles a day and you can subscribe by email or to the RSS feed

I think 5 short posts a day about thecnology is reasonable.  We will keep you up to date with all the new things and we won't waste your time or take over your mailbox and rss reader.

I hope you will visit the site at www.thetechbrief.com and let me know what you think about it either through comments on the posts or through the contact form on the site.

PS: All the content is original and we don't aggregate other sites. 

New blog

My main blog will now be at www.emadibrahim.com and it's RSS feed is at www.emadibrahim.com/feed.  I will keep dual posting .net/developments posts here.

ASP.NET AJAX: Rendering a Gmail-like 'Loading' Indicator

http://www.emadibrahim.com/2007/08/04/aspnet-ajax-rendering-a-gmail-like-loading-indicator/Here is an interesting article on how to display Gmail-like progress indicator: Matt Berseth: ASP.NET AJAX: Rendering a Gmail-like 'Loading' Indicator over a Specific ASP.NET Control

But I have a much easier method to do that, which I use in www.yongazonga.com:

First, add your UpdateProgress control like this:

<asp:UpdateProgress ID="UpdateProgress2" runat="server" 
    AssociatedUpdatePanelID="pnlNewUser"
   DisplayAfter="0" DynamicLayout="True">
      <ProgressTemplate>
         <div class='progresspanel'>
                Loading...
         </div>
      </ProgressTemplate>
</asp:UpdateProgress>

And then apply this style to the div:

.progresspanel
{
    background-color: RED;
    color: White;
    top: 1px;
    color: white;
    position: absolute;
    right: 16px;
    z-index: 999;
}

Do you have a better/easier way of doing this?

Calling the WordPress XMLRPC API from VB.net

As an example, I will call the getCategories API method.

Add a reference to the XML-RPC.net library.

Create a struct for the return result

Public Structure category
    Public categoryId As Object
    Public parentId As Object
    Public description As Object
    Public categoryName As Object
    Public htmlUrl As Object
    Public rssUrl As Object
End Structure

Create the interface for the API

<XmlRpcUrl("http://myblog.blogstogo.com/xmlrpc.php")> _
Public Interface IWP
    Inherits IXmlRpcProxy

    <XmlRpcMethod("wp.getCategories")> _
     Function getCategories(ByVal args() As String) As category()
End Interface

Call the API

Dim proxy As IWP = XmlRpcProxyGen.Create(Of IWP)()
Dim args() As String = {"http://myblog.blogstogo.com", "username", "password"}
Dim categories() As category
categories = proxy.getCategories(args)

That's it... Pretty straight forward.

Claiming my blog

This post is just to active my claim on Technorati.

Technorati Profile
Object and Array Initializers in VB 9

You can create a new object and initialize some of its properties in one shot.  Most examples online are in C#, so here is an example in VB:

Dim mycar As New Car() With {.HasWheels = 4, .NumberOfAirbags = 2, .Passengers = 4}
As for array initialization, it looks like this:
Dim cars() = {New Car With {.Passengers = 4}, New Car With {.Passengers = 2}}
According to MSDN it says I can do it this way:
Dim cars = {New Car With {.Passengers = 4}, New Car With {.Passengers = 2}}
But that didn't work for me and it gave the error: "Array initializers are valid only for arrays, but the type of 'cars' is 'Object'" So I guess type inference doesn't work with array initialization. This also doesn't work with collections or array lists - ONLY arrays.
Automatic Properties and VB

I am PISSED...  Why doesn't VB 9 have automatic properties???  VB has always been about simplicity and speed of coding.  How can you give that feature to C# on VB...  :(

If you don't know what I am talking about automatic properties in C#, let's you do this:

        public string FirstName {
            
get; set;
        
}

Instead of this:

        private string _firstName;
       
 
        public string 
FirstName {

            
get {
                
return _firstName;
            
}
            
set {
                _firstName 
= value;
            
}
        }

 

Type Inference in VB.net 9.0

I typed Dim x = New List(Of String) but on the next line I realized that the implicit type inference didn't work and Intellisense treated x as Object.  It turns out, it was an easy fix.  You have to open the project properties and turn "Option infer" to On.  Or type

Option Infer On

at the top of your class.

 
Visual Studio 2008 "Orcas" and Visual SourceSafe (VSS)

[workaround below]

I just installed Beta 2 for VS 2k8 and everything went well.  Then I installed VSS and tried to open a project from VSS and it wouldn't work...  If I open a solution or a project, it just takes me back to "My Computer".  I tried both VSS over the Internet and over VPN.

image

When I click to open the solution, I get:

image

Opening a web site works fine...  I tried both a solution and a project file... same thing.  Anyone have an idea on what's wrong?

[update]

I found a workaround...  Get latest version (recursively) through the VSS client then open the project in visual studio and it will work just fine.  You will have to be connected over VPN/network i.e. not over the Internet for this to work because the VSS client doesn't support Internet access.

Ultimate file synchronization between multiple computers

My Problem

Here is the problem, I want to synchronize files between:

  1. Home Desktop (Vista)
  2. Home Media Center PC (Vista)
  3. Laptop (Vista)
  4. Mac Mini (OS X)

Some folders I want synced between all computers like My Pictures.  Other Folders, I want synced between some machines and have access to from other machines.  For example I want my music collection to be the same between my media center and desktop but want to have access to it from my laptop.

I was using FolderShare and was very happy with it but quickly reached its limits of 10 folders and 10k files.  I tried BeInSync which looked very good but again it only has 3 folders in the free version and I didn't want to pay for it (personally, file sync should be built into the OS).

After a long and painful search, I finally found the perfect software PowerFolder.  It's free, open source, works on Mac, Windows and Linux.  The only problem is that it requires Java (which I hate) and the UI is blast from the 90s.  But it works and works well...  So far, I have synced a few folders and things are going well...  I haven't installed on the mac yet; but will report back once I do.

image

The software was straight forward and easy to use.  I didn't really read any of the help documentation other than to read up on the different types of synchronization methods which were pretty well named in the first place. 

Sync a Folder

To sync a folder, you simply:

  1. Right click on it and select Add to PowerFolder
    image 
  2. That will open the create new folder window
    image
  3. Click Ok to get the Send Invitation window
    image
  4. My HP laptop was online so it showed up.  I selected it and clicked Next.
  5. On my notebook I got a join folder prompt
    image
  6. I chose my sync method and clicked Ok and that was it both computers are now sync.

Things I haven't tested yet:

  1. Connecting over the Internet (only over LAN)
  2. Syncing over the Internet
  3. Accepting an invitation over the Internet
  4. Synchronization on the Mac
  5. File sharing with others

Feedback

Has anyone tried this on Linux?

Windows Live Writer

Testing window live writer with an image...avatar .  If you don't see a picture then it failed :(

Implicitly type local variables in VB 9.0

I love this new feature of VB 9 (Orcas). It lets you declare local variables without explicitly declaring the type, but the compiler (and intelli-sense) will infer the type from the assignment. So it is STILL strongly typed (type safe). For example, these 2 statements are the same:

Dim aStr As String = "Test string"

Dim bStr = "Test string"

Take a look at the intelli-sense:

In both instances the IDE understood that the variables are strings, even though bStr was not explicitly declared "as string". I like this because sometimes I declare a variable as an arraylist and then decide I want to use a generic collection or something else. This way I don't have to go and change the type, I just change the assignment, so instead of:

Dim implicitArray = New ArrayList

I use

Dim implicitArray = New Generic.List(Of String)

And voila, I am done.

Remember, the variable is strongly typed i.e. it is not just declared as "object".

Visual Studio Window Manager

This is a great productivity plug-in and time saver… Have you ever wanted to have different window layout in visual studio when you are doing a demo, developing in a multi-monitor, writing code, debugging, etc…? Now, you can with this VS power tool. Get it at http://www.codeplex.com/Wiki/View.aspx?ProjectName=VSWindowManager

This tool adds a simple toolbar to your VS2k5 that lets you configure different layouts for design, code and 3 others:

It's a little a picky and doesn't save/load the way you would expect it, but once you figure out how to work around it. It's a great tool.

Add Telerik Controls to your Visual Studio 2005 Toolbox

If your Telerik controls disappeared from you VS2k5 toolbox, just run this command to reinstall them:

"C:\Program Files\telerik\radcontrolsQ1 2007\DeploymentActions\toolboxinstallernet20.exe" /install "C:\Program Files\telerik\radcontrolsQ1 2007" "C:\Program Files\telerik\radcontrolsQ1 2007\DeploymentActions\ControlsToolboxNet20.config"

More Posts Next page »