Solved

Invalid expression term '>' in an if statement

Posted on 2008-09-30
4
1,689 Views
Last Modified: 2012-08-14
Can someone guide me to what I am missing here.  I am trying to do a simple if statement and keep getting this error message.

if (int.parse(Oct1)) > 9)------------------------------Line errors out here with squiggly under the >
{
  Ozip1 = Oct1 + OriginZip.Substring(1,3);
}
0
Comment
Question by:kwh3856
  • 2
4 Comments
 
LVL 23

Accepted Solution

by:
Roshan Davis earned 250 total points
Comment Utility
if ((int.Parse(Oct1)) > 9)
{
  Ozip1 = Oct1 + OriginZip.Substring(1,3);
}
0
 
LVL 8

Assisted Solution

by:rambovn
rambovn earned 250 total points
Comment Utility
if ((int.parse(Oct1)) > 9)
{
  Ozip1 = Oct1 + OriginZip.Substring(1,3);
}
0
 
LVL 23

Expert Comment

by:Roshan Davis
Comment Utility
Or you can remove one level bracket also , like...

if (int.Parse(Oct1) > 9)
{
  Ozip1 = Oct1 + OriginZip.Substring(1,3);
}
0
 

Author Closing Comment

by:kwh3856
Comment Utility
Thanks for such a quick response
0

Featured Post

How your wiki can always stay up-to-date

Quip doubles as a “living” wiki and a project management tool that evolves with your organization. As you finish projects in Quip, the work remains, easily accessible to all team members, new and old.
- Increase transparency
- Onboard new hires faster
- Access from mobile/offline

Join & Write a Comment

Summary: Persistence is the capability of an application to store the state of objects and recover it when necessary. This article compares the two common types of serialization in aspects of data access, readability, and runtime cost. A ready-to…
It was really hard time for me to get the understanding of Delegates in C#. I went through many websites and articles but I found them very clumsy. After going through those sites, I noted down the points in a easy way so here I am sharing that unde…
It is a freely distributed piece of software for such tasks as photo retouching, image composition and image authoring. It works on many operating systems, in many languages.
You have products, that come in variants and want to set different prices for them? Watch this micro tutorial that describes how to configure prices for Magento super attributes. Assigning simple products to configurable: We assigned simple products…

772 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

Need Help in Real-Time?

Connect with top rated Experts

11 Experts available now in Live!

Get 1:1 Help Now