Skip to main content

IDEAScript Questions

using a Variable in the Task.Criteria

Hey,
 
I am currently working on a searching filter function so I can filter a database. For this function I have a String variable as input. Somehow Idea doesn't allow me to use the Variable in this function and I just cant Figure out why.
 
Function SearchFilter(KeyWord As String)
 
task.Criteria = "@Isini(KeyWord; Column1) .OR. @Isin(KeyWord; Column2) .OR. @Isini(KeyWord; Column3) .OR. @Isini(KeyWord; Column4)"
 

Create Mask for the function gap detection

I created a script for the gap detection and build some code so that would check if a letter from a string is numeric or not. I got it working but what i don't understand is that every space, dot en minus sign is recognized by the IsNumeric function als numeric. Why is that? I would expected that only number would be a valid numeric. 

Array data

I created some code to import a txt file and remove the " symbol from the array:
 
 Function ImportText1
Const fsoForReading = 1
Dim objFSO
Dim objTextStream
Dim FirstTime As Boolean
Dim FileName As String
Dim i As Integer
 
FileName = WorkingDirectory & "\Exports.ILB" & "\Temp1.DEL"
FirstTime = True
Set objFSO = CreateObject("Scripting.FileSystemObject")
Set objTextStream = objFSO.OpenTextFile(FileName, fsoForReading)
Do Until objTextStream.AtEndOfStream 

Listbox

I know how to get fieldnames in a list, but is there a way to get the content of a field in a listbox? (Such as debtor names or general ledger ID's)
 
Update:
I got to the point to summarize the selected field (general ledger ID) and export only the content of that field to a txt file and then import it.
 
Open WorkingDirectory & "\Temp.DEL" For Input As File1
Line Input #File1, Contents
MsgBox "The file contains: " & Contents
 

Summarization function

In the summarization function IDEA wants to know what statistics functions to use. When all are selected the code is as follows: task.StatisticsToInclude = SM_SUM + SM_MAX + SM_MIN + SM_AVERAGE + SM_VARIANCE + SM_STD_DEV
 
I created check boxes in a dialog menu so the user can select the statistics function they want to use. The check boxes are set as boolean, but i added a If function that when a statistic function is selected (example sum) a variable (sting) is set with SM_Sum and if not it is set to "".