Wrox Programmer Forums
|
BOOK: Professional ASP.NET 3.5 : in C# and VB ISBN: 978-0-470-18757-9
This is the forum to discuss the Wrox book Professional ASP.NET 3.5: In C# and VB by Bill Evjen, Scott Hanselman, Devin Rader; ISBN: 9780470187579
Welcome to the p2p.wrox.com Forums.

You are currently viewing the BOOK: Professional ASP.NET 3.5 : in C# and VB ISBN: 978-0-470-18757-9 section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old February 11th, 2010, 07:20 AM
Registered User
 
Join Date: Feb 2010
Posts: 1
Thanks: 0
Thanked 0 Times in 0 Posts
Default Expected Expression

My code is below

Dim Array As String = "['"
For Each str As String In files
Array += str
count += 1

Array += If(countfiles <> count, "','", "']")
Next

and i found the error on the second last line that is bold
"Expected Expression" is any one help me.
 
Old July 2nd, 2010, 02:25 PM
Authorized User
 
Join Date: Aug 2009
Posts: 17
Thanks: 0
Thanked 1 Time in 1 Post
Default

Dim Array As String = "['"
For Each str As String In files
Array += str
count += 1

Array += If(countfiles <> count, "','", "']")
Next


=====
I think what you want is

Array += IIF(countfiles <> count, "','", "']")





Similar Threads
Thread Thread Starter Forum Replies Last Post
Expected Expression before')' token page 212 line martyds BOOK Beginning Linux Programming, 3rd Edition 0 November 9th, 2008 04:44 PM
XPath Error : Expression Expected deean XML 1 June 14th, 2008 05:57 PM
Message> in query expression <expression>. (Error ybg1 Access 5 July 15th, 2007 05:42 AM
Expected 'Then' Adam H-W Classic ASP Basics 5 July 26th, 2004 02:36 PM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.