C# code

Hi, this is working in the VS2015, How to modify below code to 2012?  (job?.Id > 0)
var job = await c.CreateJob(42626, 52.24525033130513, -0.8287811279296875);
 (job?.Id > 0)

I tried using below
 (job.Id > 0)
But no results
LVL 2
lankapalaAsked:
Who is Participating?

[Product update] Infrastructure Analysis Tool is now available with Business Accounts.Learn More

x
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

zephyr_hex (Megan)DeveloperCommented:
This has nothing to do with the version of Visual Studio.

We can't answer the question unless we know what c is, and what c.CreateJob does.
0
lankapalaAuthor Commented:
it's ok i solved the issue.
0

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
käµfm³d 👽Commented:
This has nothing to do with the version of Visual Studio.
Sure it does. He's using the null-conditional operator. This became available in VS 2015. The equivalent syntax would be:

(job != null && job.Id > 0)

Open in new window

0
Exploring SQL Server 2016: Fundamentals

Learn the fundamentals of Microsoft SQL Server, a relational database management system that stores and retrieves data when requested by other software applications.

zephyr_hex (Megan)DeveloperCommented:
@käµfm³d 👽

Isn't that a dependency on C# (the language) and not VS (the IDE)?
0
käµfm³d 👽Commented:
Well, yes and no. MS often releases versions of the language in conjunction with the IDE. If a version of an IDE doesn't support the syntax, then it will not know how to treat it. Try using async/await in VS 2008 and you'll see what I mean : )
0
lankapalaAuthor Commented:
I solved the issue
0
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
C#

From novice to tech pro — start learning today.