Compile Error Expected Then Or Goto
Contents |
Way | Trading Add-ins For Excel | Convert Excel Into Calculating Web Pages Excel Web Pages | Produce
Compile Error Expected Identifier
Clean Efficient VBA Code Every Time | Build Automated Trading Models compile error expected identifier or bracketed expression In Excel | Excel Web Pages | Excel Video Training Forum New Posts FAQ Calendar compile error expected case Forum Actions Mark Forums Read Quick Links Today's Posts What's New? Advanced Search Forum HELP FORUMS Excel General if then else statement in VBA Excel Training / Excel http://www.excelforum.com/showthread.php?t=1067650 Dashboards Reports If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below. If you don't http://www.ozgrid.com/forum/showthread.php?t=155966 like Google AdSense in the posts, register or log in above. Click here to view the relaunched Ozgrid newsletter. Results 1 to 5 of 5 Thread: if then else statement in VBA Thread Tools Show Printable Version Search Thread Advanced Search July 13th, 2011 #1 acfiltm View Profile View Forum Posts Member Join Date 10th June 2011 Posts 50 if then else statement in VBA I am having trouble setting up if then else statement. I have cell AF848 selected, and if AA848 is "yes" I want it to run one set of equation but if AA848 is no I want it to run different set of equation. here is my code VB: Range("AF848").Select If RC[-35]=""yes"" Then Range("AH848").FormulaR1C1 = _ "=IF(and('201106'!R[-455]C[-24]<>0,'PriceSheets-ItemList'!RC[-2]<>"""") Else Range("AH848").FormulaR1C1= _ "=If(and('201106'!R[-455]C[-24]<>0,'PriceSheets-ItemList'!RC[-2]<>""""'),201106'!R[-455]C[-24]*1.03,"""")" I keep getting an error for If RC[-35]="yes" then row. Excel Video Tutorials / Excel Dashboards Reports Reply With Quote July 13th, 2011 #2 cytop View Profile View Forum Posts . Join Date 1st September 2010
Unanswered Topics Wrox Programmer Forums > ASP.NET and ASP > ASP 3 Classic ASP Active Server Pages 3.0 > Classic ASP Basics http://p2p.wrox.com/classic-asp-basics/8740-expected-then-vbulletin-script-compilation-error.html 'expected then' VB script compilation error User Name Remember Me? Password Reminder https://social.msdn.microsoft.com/Forums/en-US/1988d360-7d77-43fc-851c-1dd3801301de/im-getting-a-compile-error-expected-?forum=isvvba Password Register Register | FAQ | Members List | Calendar | Today's Posts | Search Classic ASP Basics For beginner programmers starting with "classic" ASP 3, pre-".NET." NOT for ASP.NET 1.0, 1.1, or 2.0 Search Forums Show Threads Show Posts Advanced Search Find All compile error Thanked Posts Go to Page... Welcome to the p2p.wrox.com Forums. You are currently viewing the Classic ASP Basics section of the Wrox Programmer to Programmer discussions. This is a community of tens of thousands of software programmers and website developers including Wrox book authors and readers. As a guest, you can read any forum posting. By joining today compile error expected you can post your own programming questions, respond to other developers’ questions, and eliminate the ads that are displayed to guests. Registration is fast, simple and absolutely free . Thread Tools Display Modes #1 (permalink) January 29th, 2004, 11:37 AM Adam H-W Friend of Wrox Join Date: Jun 2003 Location: , , . Posts: 347 Thanks: 0 Thanked 0 Times in 0 Posts 'expected then' VB script compilation error Hi there I'm getting a compilation error and I'm not sure why. Here's the rogue code: intTotalPrice = intTotalPrice + (intQuantity * intPrice) Set rsPacking = server.CreateObject("ADODB.Recordset") strSQL = "SELECT * FROM PPack ORDER BY PPid DESC" set rsPacking = con.execute(strSQL) if rsPacking.EOF then else do while not rsPacking.EOF intPP = 0 If intTotalPrice > rsPacking("Limit") where rsPacking("PPid") = 1 then intPP = rsPacking("FixPrice") elseif intTotalPrice rsPacking("Limit") where rsPacking("PPid") = 2 then intPP = rsPacking("FixPrice") else intPP = rsPacking("FixPrice") where rsPacking("PPid") = 3 end if rsPacking.movenext() loop end if The error is on line: If intTotalP
SQL Server 2014 Express resources Windows Server 2012 resources Programs MSDN subscriptions Overview Benefits Administrators Students Microsoft Imagine Microsoft Student Partners ISV Startups TechRewards Events Community Magazine Forums Blogs Channel 9 Documentation APIs and reference Dev centers Retired content Samples We’re sorry. The content you requested has been removed. You’ll be auto redirected in 1 second. Ask a question Quick access Forums home Browse forums users FAQ Search related threads Remove From My Forums Answered by: I'm getting a compile error: Expected: ( Microsoft ISV Community Center > Visual Basic for Applications (VBA) Question 0 Sign in to vote I am getting acompile error: Expected: ( error. The code is below, the point upon where the error is coming from is below it. With wsJL strComp = Range("A1") ' assumes company name in A1 strPart = CleanName(Range("C1")) ' assumes part in C1 strPath = CleanName(Range("G2")) If Not FolderExists(strPath & strComp)Then 'company doesn't exist, so create full path FolderCreate strPath & strComp & Application.PathSeparator & strPart Else 'company does exist, but does part folder If Not FolderExists(strPath & strComp & Application.PathSeparator & strPart) Then FolderCreate strPath & strComp & Application.PathSeparator & strPart End If End If End Sub Function FolderCreate(ByVal path As String) As Boolean FolderCreate = True Dim fso As New FileSystemObject If Functions.FolderExists(path) Then Exit Function Else On Error GoTo DeadInTheWater fso.CreateFolder path ' could there be any error with this, like if the path is really screwed up? Exit Function End If DeadInTheWater: MsgBox "A folder could not be created for the following path: " & path & ". Check the path name and try again." FolderCreate = False Exit Function End Function Function FolderExists(ByVal path As String) As Boolean