Asp.net 2.0 compiler tool

12. October 2006 08:56 by Mquiros in General  //  Tags:   //   Comments (0)

If you are starting to develop Asp.net application with Visual Studio 2005 and learning about the thousands of new cool features of  asp.net 2.0 you will find that the compilation model is really different.

To me was very confusing in the beginning understand the new compilation model or features. Playing around -before reading documentaion first- I find that there some command line tools that  you can use to understand the different ways to do it, however it's difficult to understand if you don't read the new compilation model documentation.

I want to share about a tool I used since I found it, it's called West Wind Web ASP.NET 2.0 Compiler Utility, it's very simple to use and in my case, it helps me to understand better the compilation options I have with the asp.net 2.0 model.

So give it a try and I hope you like it.





Joining a Machine to a Windows Domain that won't Budge

12. October 2006 04:57 by Csaborio in General  //  Tags:   //   Comments (0)
During our VT labs, we are constantly messing around with domain controllers due to the fact that in order for Virtual Server's API and Carmine to work correctly, the hosts need to be on the same domain.

Everything has worked quite fine until a day in which we were trying to add a machine the domain we had.  I got the following message:

The system cannot log you on due to the following error:
The specified domain either does exist or could not be contacted.

Please try again or consult your system administrator.

Hmmm...well...trying again certainly did not work and we are our own sys admins ;)  I sent a desperate cry for help to our awesome Virtua team, and Jose hinted me on how to fix it.

All it takes is to change the Primary DNS of the machine that won't logon to the IP address of the domain controller.  Doing this fixed the issue.

As far as why this works, I really don't know and to a certain extent, I am not sure I want to. :D

Hope this helps someone in distress in the future!

MSDN Webcast on moving from VB6 to VB.NET

11. October 2006 10:44 by Jaguilar in General  //  Tags: , ,   //   Comments (0)

My coworker Hendel Valverde will be presenting a webcast called Complete Methodology for Migrating Microsoft Visual Basic 6.0 to Visual Basic .NET, tomorrow at 1:00 PM Pacific. It covers all the steps necessary to prepare and perform migrations from VB to VB.NET, from what to look for during the analysis and planning stages to the final testing of the migrated application.

Link: MSDN Webcast: Complete Methodology for Migrating Microsoft Visual Basic 6.0 to Visual Basic .NET (Level 200)

And here’s the link to ArtinSoft’s press release: ArtinSoft and Microsoft Announce New Webcast on VB6 to .NET 2005 Migration Methodology.

 

Virtual PC 2007 Beta is out

11. October 2006 09:34 by Jaguilar in General  //  Tags:   //   Comments (0)

Virtual PC 2007 Beta is now available for download from http://connect.microsoft.com. As with other beta software, you need to register for the beta first.

This is a long overdue upgrade that finally supports hardware virtualization. It includes:

  • Hardware-assisted virtualization (both AMD and Intel)
  • Support for Vista both as host and guest OS
  • Support for 64–bit Hosts
  • Bug Fixes and Performance Enhacements

Multicore lab Thread Checker mystery error... solved!!

9. October 2006 04:08 by Jaguilar in General  //  Tags: ,   //   Comments (0)

Some of you may recall that on some events, we got an error message on Intel Thread Checker during the Multicore lab. No matter what we did, even if we solved all the concurrency issues related to our code, the Thread Checker would always log this message:

Write -> Read data-race Memory read at [PrimesInstrumented.exe, 0x2468] conflicts with a prior memory write at [PrimesInstrumented.exe, 0x16816] (flow dependence)

During the labs, we have said that we've been working out the solution with the Intel support people - and now we have an answer!!The thing is that you can work with Thread Checker in two ways:
  1. Use compiler based instrumentation. With this, you basically need to add the /Qtcheck flag to the compiler command line to instrument the binary. Once it is instrumented and you run it, it will create a file called "Threadchecker.thr", that you can then load in the VTune Thread Checker. To do this, you need to use the following command lines: (using the primes example from the lab)

    icl /c /Zi primes.cpp /Qopenmp /Qtcheck /Od
    link primes.obj /out:PrimesInstrumented.exe /fixed:no /DEBUG


  2. Use Thread Checker to intrument the application. In this scenario, you don't intrument the binary at compile time, but have Thread Checker intrument it when running the application. For this, you need to build the application with the following command lines:

    icl /c /Zi primes.cpp /Qopenmp /MD /Od
    link primes.obj /out:PrimesInstrumented.exe /fixed:no /DEBUG


    And then load it in Thread Checker.

The error we were doing on the lab is that we were using both compiler and "Thread Checker" instrumentation, and that caused Thread Checker to report conflicts that are outside of the program and in the runtime libraries. Now, using either option (BUT not both at the same time) the strange error is gone!

Thanks to Vasanth Tovinkere at Intel who really helped us out with this problem!!

BTW, this is repeating an old blog post I did for the 64–bit Advantage Blog. The post was deleted for some reason. Since I consider this information to be important, I am re-posting it here.

Demo Photo

5. October 2006 10:44 by Admin in General  //  Tags:   //   Comments (0)
The description of the picture

OpenMP on Visual Studio

5. October 2006 08:57 by Jaguilar in General  //  Tags: ,   //   Comments (0)

You can create C++ application in Visual Studio that use OpenMP. When you run an application created with OpenMP and VS.NET, however, you may get this annoying error message: “This application has failed to start because vcompd.dll was not found. Re-installing the application may fix this problem.”:

omp-error

When we tried this, we were puzzled by this error message, especially since it works with the Intel Compiler flawlessly. Well, it turns out that you need to include omp.h in your files ALWAYS when you use OpenMP from Visual Studio. This is not required on other compilers if you’re only using the OpenMP pragmas, but it is an issue with Visual Studio.

Thanks to Kang Su for pointing this out in his blog – I was going crazy trying to figure out what was wrong.

Also remember to enable OpenMP support in the C++ Project properties. This setting is in Configuration Properties->C/C++->Language->OpenMP Support.

Expading or Shrinking your disks

5. October 2006 06:52 by Mrojas in General  //  Tags:   //   Comments (0)
    If you have been using VMWare for a while you'll end up having space problems.
Either your virtual machine disks are TOO big or TOO small.
To handle that VMWare Workstation has a tool (Notice that VMWare Server does not have it)
Called vmware-vdiskmanager.exe (Virtual Disk Manager you can google it with "Virtual Disk Manager vmware")
you will find it in C:\Program Files\VmWare WorkStation\

to Expand a Disk you just do vmware-vdiskmanager.exe -x 40GB mydisk.vmdsk

To Shrink files there are more steps to take. You must remove all snapshots if you had any. Then start the virtual machine, and install the vmwareTools and once you have installed then you go to the control panel Click in Vmware Tools and use the Shrinking features.

Then you can use the vmware-vdiskmanager.exe -k command.

You can find more details intructions in the VMWare site! Good Luck

Use VTune to Catch Alignment Faults

5. October 2006 02:50 by Csaborio in General  //  Tags:   //   Comments (0)
So there is a quick hack method you can use to catch alignment exceptions on your code, but this approach - although effective, is not a very elegant solution. It turns out that VTune can help you find alignment faults very easily. I tested VTune using my MacBook running Windows XP and it had an event called: Misaligned Data Memory References By focusing on these events, you can find places in your code where alignment faults are happening. No more guessing, no more hacks, plain and simple. On some processors, this event counter might not be present. In cases like this, you would need to focus on the Split Stores Retired and Split Loads Retired events to find this information. We have added this extra information on our VTune labs as part of Artinsoft's continuing effort to support in-house customized 64-bit training .

Microsoft Support Lifecycle for VB6

4. October 2006 13:11 by Fzoufaly in General  //  Tags:   //   Comments (0)
Are you wondering what's Microsoft support policy for Visual Basic 6?  Here is the information:

Link to Microsoft Support Lifecycle

QUIZ: What do you know about VB 6 migration?

4. October 2006 11:18 by Fzoufaly in General  //  Tags:   //   Comments (0)

SearchVB website just published a QUIZ to test your knowledge about VB6 migration.

I read the questions, the answers and the pointers to more resources.  It is a fun way to learn a bit more about the process.  I do agree with most answers and pointers even if sometimes the comments on why to move or how to move are a little away from what I believe.  I still think you can find this useful.

Webcast: How to upgrade legacy VB 6 applications

4. October 2006 10:59 by Fzoufaly in General  //  Tags:   //   Comments (0)

-- "It's not tremendously exciting stuff and we'd all like to be able to start from scratch, but there's a huge investment in these legacy applications," said Keith Pleas, MVP architect and head of Keith Pleas & Associates. --

There is a fundamental question in the software world.  Are applications like cars? Do we use them a few years and then we throw them away?  Or are applications like buildings?  We treat them as important assets and we try to extract as much value as possible from them?  Nobody blows away a building just to build a new one from scratch ( well... maybe in Vegas!) , on the other hand we tend to do exactly that with software applications.  Should we???

You ought to yourself and the company you work for to evaluate Automatic Migration as an option to bring new life to VB6 applications.  As Keith points out, there is a huge investment and we need to maximize the ROI.

This web cast about the VB Migration Guide gives you a nice overview of the content of the book and some essential guidance to make decisions.

Link to Webcast: How to upgrade legacy VB 6 applications

OpenMP is your friend

4. October 2006 08:42 by Jaguilar in General  //  Tags: ,   //   Comments (0)

OpenMP is very easy-to use API that you can use to very rapidly add multi-threading to your C/C++ applications. OpenMP allows you to parallelize the execution of a region of code by just adding a few pragmas to the code. For example, take this code:

   for(int i = 0;i<=100;i++){
       a[i] = a[i]*10;
       ...
   }

The code above performs a for loop sequentially. Since each iteration could be executed independently, we can easily add multi-threading to the application by adding these simple pragmas:

#pragma omp parallel for
   for(int i = 0;i<=100;i++){
       a[i] = a[i]*10;
       ...
   }

The omp pragmas tell the compiler to generate code to parallelize the execution of the for loop. That means that if you run this code on a 4 core machine, it will create 4 threads, and each one will execute 25 iterations of the loop. Just by adding those pragmas, you now have a multi-threaded application that takes advantage of multi-core systems.

Yes, it's that simple.

VB Migration in Japanese: パートナー情報

3. October 2006 11:15 by Fzoufaly in General  //  Tags:   //   Comments (0)

My friend Chazu Lee from Microsoft in Japan shared this page with me.  It contains lots of resources in Japanese for VB Migrations.  Thank you Chazu!!

 

Link to パートナー情報

ArtinSoft News And Events: ArtinSoft and Microsoft Announce New Webcast on VB6 to .NET 2005 Migration Methodology

3. October 2006 11:05 by Fzoufaly in General  //  Tags:   //   Comments (0)

In this webcast, we present a complete and proven methodology for semi-automatically upgrading a Microsoft Visual Basic 6.0 project to Microsoft Visual Basic .NET 2005. We cover all of the phases involved in migrating to Visual Basic .NET 2005, from initial assessment and return on investment (ROI) calculation to final testing and deployment of the application. Tune in to learn about ArtinSoft’s proven expertise, including actual statistics from real-world migration projects.

Presenter: Hendel Valverde, Senior Consultant & Trainer, ArtinSoft

Link to ArtinSoft News And Events: ArtinSoft and Microsoft Announce New Webcast on VB6 to .NET 2005 Migration Methodology

Centro de Excelencia en Migracion MSDN (Center of Excellence for Migrations)

3. October 2006 10:56 by Fzoufaly in General  //  Tags:   //   Comments (0)

 Si usted habla español este sitio es un excelente repositorio de información acerca de las migraciones a .NET en general.  Por el momento el enfoque es más hacia Visual Basic.

Link to Centro de Excelencia en Migración MSDN

 

"El CEM.Net es un programa de apoyo a clientes en Latinoamérica, que busca asegurar el éxito en los proyectos de migración de software hacia la plataforma .Net. "

El CEM tiene cómo meta \de compartir conocimiento, dar soporte y apoyar el creciente número de clientes con necesidades de migración a .Net. ¡Actividades como eventos en línea y capacitaciones en sitio están disponibles!

-----

The Center of Excellence for migration is a Microsoft program targeted at LATAM customers to help them make the JUMP to .NET.  If you speak spanish this is an excellent repository of information.

VB6 to .NET apps migration given a jolt or Microsoft Tool Brings VB6 Developers to .NET

2. October 2006 13:07 by Fzoufaly in General  //  Tags:   //   Comments (0)

I find it always interesting that new ways to postpone the VB6 migrations are introduced. the title of this post is the combination of an Infoworld and an Eweek article on the subject.  I understand where a tool (Microsoft InteropForms Toolkit 1.0 ) that attpepts to tempt VB6 developers use .NET while retaining a safety net in VB6 is coming from. The whole idea is to reduce the risk, to make a transition smoother. But are we really achieving the business benefits by doing it? I think it goes all back to the fact that people do not believe an automatic migration from VB6 is possible. I firmly believe it. If you have followed this blog, you probably believe it too.  In any case, every effort in the direction of helping customers move is laudable!

 

Look at the Infoworld article: http://weblog.infoworld.com/techwatch/archives/008022.html

or the Eweek article: http://www.eweek.com/article2/0,1895,2019386,00.as...

Upgrading Visual Basic 6 to C#?

2. October 2006 12:49 by Fzoufaly in General  //  Tags:   //   Comments (0)

This is another big overlook of mine.  ArtinSoft's VB Companion has been able to directly generate C# for ages.  How come I have not told about it here?

Anyway, maybe the question to ask is: Should I move to VB.NET or C#?  Of course the answer is not obvious.  From the technical perspective both languages give you pretty much the same power.  Microsoft is positioning VB.NET more as a RAD environment and C# more for Systems programming.  However, in my opinion it is more a question of preference.  If your company has chosen C# for .NET development then the VB Companion can help you go straight there.

What do you prefer? C#? or VB.NET? Which one do you think is easier for the VB6 Programmer?

Upgrading Visual Basic 6.0 Applications to Visual Basic .NET and Visual Basic 2005

2. October 2006 04:44 by Fzoufaly in General  //  Tags:   //   Comments (0)

I cannot believe I just overlooked this link for so long.  I have announced back in May that the VB Upgrade Guide is available in print, but I forgot to mention that it is also available for download at MSDN. 

Link to Upgrading Visual Basic 6.0 Applications to Visual Basic .NET and Visual Basic 2005

This is a great resource to understand how to perform the upgrades.  In addition, if you are looking for the VB Companion mentioned in the guide please go to: http://www.artinsoft.com/pr_vbcompanion.aspx it substantially reduces the cost of an upgrade.

 

I'd like to hear comments on the usefulnness of the guide.  Let me know!

SCVMM Guest OS Profiles

27. September 2006 06:33 by smurillo in General  //  Tags:   //   Comments (0)

As you may know already System Center Virtual Machine Manager can be used to create virtual machine templates. Templates have three main elements: a VHD file to use as a base for the template, a hardware profile and a guest OS profile. If you are familiar with Virtual Server you will have no problem understanding the first two, but the guest OS profile will be news to you.

The guest OS profile contains Sysprep information. When you create a virtual machine based on a template it will copy the selected VHD to it, use the hardware profile you select, and sysprep the virtual machine using the guest OS profile. Clive Watson makes an introduction to Templates and Profiles in his blog, but I just wanted to clarify a couple of things you need to have in mind before trying to make this work.

When you create a virtual machine based on a template the creation process includes a few additional steps:

On step 3 a Sysprep Virtual Floppy Disk is created, and then on steps 8, 9 and 10, that disk is attached, the VM is started and the disk is released. By then the VM should have been started and Sysprep'd, after which it is just shut down and ready to go.

Two important things you should consider for this to work are:

  1. When SCVMM starts the VM it doesn't just move on to step 10, it waits for a heart-beat. That means the image you use needs to have VM Additions installed first. Therefore a blank VHD will never work for this.
  2. SCVMM will not really Sysprep the machine, it will simply use the Virtual Floppy Disk to enter the guest OS profile as the Sysprep data. This means that the VHD will have to be Sysprep'd first by the Administrator, and that it should be ready to run fully automated, so that the OS can start and so that the VM Additions can send a heart-beat back to SCVMM. Jose Aguilar explains how to fully automate sysprep on his blog.

If your VHD is not pre-sysprep'd the virtual machine will still be created, but the guest OS profile will simply be ignored. The VM Additions are completely necessary, otherwise the creation process will fail.

Categories