Submitted by reesd on 2011/04/19 20:29
IQ (0.9.25Q1) doesn't seem to be validating VB code for some reason. Even the system code. If you go to the system code and click validate you get the following error:
 
 
d

Comments

hmmm... I don't have that problem. Will see if I can find the time to do more testing tomorrow.
 
 [Edit : That said... are you sure you're not missing an extra ")" somewhere ?]
 
--------------------------------------------------------------------------------
Windows XP Home Edition, Service pack 2
Dell Vostro 1500, Ram:3gb, CPU:Core2Duo T7500 2.2ghz

reesd

2011/04/19 22:09

In reply to by Armando

[quote=Armando]
hmmm... I don't have that problem. Will see if I can find the time to do more testing tomorrow.
 
 [Edit : That said... are you sure you're not missing an extra ")" somewhere ?]
 [/quote]
 
Ok, I was wrong about the System Code part. I misunderstood what close did. It closes everything so it was scanning all three code bases including User Code.
 
And knowing that let me track down my issue. I had the following code that worked find in Excel, but I got that error in IQ. The problem turns out to be typing, the areas in yellow are not valid in VB Script but are valid in VBA. I've updated Field Management Dialog - Equations (again) to point that out.
 
Function SplitOrNone(inputStr As String, index As Integer)
    Dim inputSplit
    inputSplit = Split(inputStr, "-")
   
    If index > UBound(inputSplit) Then
       SplitOrNone = ""
    Else
        SplitOrNone = inputSplit(index)
    End If
End Function

Armando

2011/04/19 23:02

In reply to by reesd

Yes, that's because there are no types in Vbscript.
 
Unlike Visual Basic and/or Visual Basic for Applications, VBScript has only a single data type : the variant.  Variants can contain "any" type of data. vbScript will select the most appropriate data type in relation to the context.
 
[BTW : thanks for taking the time to insert all these changes and put all these links in the manual! Highly appreciated.]
 
--------------------------------------------------------------------------------
Windows XP Home Edition, Service pack 2
Dell Vostro 1500, Ram:3gb, CPU:Core2Duo T7500 2.2ghz

reesd

2011/04/20 20:59

In reply to by Armando

[quote=Armando]
Yes, that's because there are no types in Vbscript.
 
Unlike Visual Basic and/or Visual Basic for Applications, VBScript has only a single data type : the variant.  Variants can contain "any" type of data. vbScript will select the most appropriate data type in relation to the context.
 
[BTW : thanks for taking the time to insert all these changes and put all these links in the manual! Highly appreciated.]
[/quote]
 
I used to know that way back when, but had forgotten.
 
Happily I just dug through a pile of MSDN disks and found VS 2005, so I'm looking forward to trying that. Would be awesome if I could actually debug.
 
d

Armando

2011/04/21 00:31

In reply to by reesd

[quote=reesd]
I used to know that way back when, but had forgotten.
 
Happily I just dug through a pile of MSDN disks and found VS 2005, so I'm looking forward to trying that. Would be awesome if I could actually debug.
 
d
[/quote]
 
These things are easily forgotten... :(
 
And, yes, having a debugger  handy is... pretty handy.
 
--------------------------------------------------------------------------------
Windows XP Home Edition, Service pack 2
Dell Vostro 1500, Ram:3gb, CPU:Core2Duo T7500 2.2ghz

reesd

2011/05/03 10:23

In reply to by Armando

[quote=Armando]
[quote=reesd]
Happily I just dug through a pile of MSDN disks and found VS 2005, so I'm looking forward to trying that. Would be awesome if I could actually debug.
[/quote]
And, yes, having a debugger  handy is... pretty handy.
[/quote]
 
What debugger tool do you use?

Armando

2011/05/03 10:47

In reply to by reesd

The debugger from the old Visual InterDev in Visual Studio 6.
 
--------------------------------------------------------------------------------
Windows XP Home Edition, Service pack 2
Dell Vostro 1500, Ram:3gb, CPU:Core2Duo T7500 2.2ghz