cannot be used as an expression

Posted on 2009-05-13
Medium Priority
Last Modified: 2012-05-06
I encounter this error when i just done and upgrade from visual studio 2003 to 2008, 2.0 frameworks not 3.0 or higher.

Timer' is a type and cannot be used as an expression.      
'System.Timers' is a namespace and cannot be used as an expression.      S:\store\ViewSRP.aspx.vb      
Question by:Seven price
LVL 20

Accepted Solution

ddayx10 earned 1500 total points
ID: 24381899
Don't have a lot to go on here but it sounds like you are not implementing it correctly. Also not exactly sure thich language you are using, but...

Dim t as System.Timers.Timer = new System.Timers.Timer(1000)

System.Timers.Timer t = new System.Timers.Timer(1000);

Might want to look at this:

VS2k3 to VS2k8 is a huge jump both in codebase as well as software. If you are certain you are implementing it correctly and suspect that there was an issue upgrading Visual Studio that is causing the software to fail.... I cant help ya there.


Author Comment

by:Seven price
ID: 24385148
I just wondering do you know why this is happening.

After the upgrade from 1.1 to 2.0 frameworks.  I finally thought I had no more errors. But Now when i run the debug error I keep getting this error.

Error      34      Unable to open file 'S:\obj\Debug\A1S.Gecko_InsertTemplate_Frame.resources': The system cannot find the file specified.      
Error      35      Unable to open file 'S:\obj\Debug\A1S.Gecko_Page.resources': The system cannot find the file specified.      
Error      36      Unable to open file 'S:\obj\Debug\A1S.Gecko_Page_Frame.resources': The system cannot find the file specified.      


Featured Post

Free Tool: Port Scanner

Check which ports are open to the outside world. Helps make sure that your firewall rules are working as intended.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

Join & Write a Comment

As with any other System Center product, the installation for the Authoring Tool can be quite a pain sometimes. This article serves to help you avoid making these mistakes and hopefully save you a ton of time on troubleshooting :)  Step 1: Make sur…
Many companies are making the switch from Microsoft to Google Apps (https://www.google.com/work/apps/business/). Use this article to learn more about what Google Apps has to offer and to help if you’re planning on migrating to Google Apps. It is …
Viewers will learn the different options available in the Backstage view in Excel 2013.
The viewer will learn how to create a normally distributed random variable in Excel, use a normal distribution to simulate the return on an investment over a period of years, Create a Monte Carlo simulation using a normal random variable, and calcul…

624 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question