Skip to main content

IDEAScript Questions

Reading configuration file

Hi there.
I have to export many information to excel for some users but i have to wait for them to confirm whent to do it. They don't have database users so I was thinking to create some sort of configuration file where I do write my credentials and let them execute my script to import data...I know it's to much to ask encrypting-decrypting function to retrieve authetication info, but I'm expecting to be able of retrieving user and password.
Any advice?

Internal Error while running Dialog box with list box

Hi Brian,
I'm sure somebody might have asked you the question.
I'm coming back to idea scripting after three years and almost forgot all the tips and tricks.
Previously i have created many macros with list box but not rememebr facing this issue.
I'm getting internal error for the below example. I have defined the array for list box seperately but still facing issue. I'm using idea 10 version. Do you see something that i'm missing? I have a 3000 line code having this problem. so, just created an example with simple list box.
code:

Cannot delete folder within script

Hi Brian,
I'm writing a script that creates a working folder, does a lot of file compilation within that folder, and then moves the resulting two files to a new folder.
Once the results are moved to the new folder I then want to delete the working folder.
 
As part of the main subroutine I have the folder name defined much earlier in the script as shown below
 
Set fldrName as String
Set wD as String
 
wD= CurDir()

Field type

Is there a way to check if a field type is numeric or a string? I found the code to check is a field exists but now i need some code to check is the field type is numeric or not.
 
 
Function checkIfFieldNameExists(fieldname As String, filename As String) As String
 
fieldname = UCase(fieldname)
origFieldName = fieldname
 
Set db = Client.OpenDatabase(Databasename)
Set table = db.TableDef
field_count = table.count
 
ReDim fieldNames(field_count)
 
For i = 1 To field_count

Populating TextBoxes with values from an imported database

I have a macro now that performs extractions and random samples based on a number of user-entered edit boxes on the dialog screen. The user entered data comes from a standardized Excel workbook that contains the proper data in a structured manner. What am I wondering is if there is a way to "import" those values such that the text boxes are essentially filled in with the data contained in the Excel workbook?
Thanks for any information!

Function age

Hello,
 
I have a problem with the function @age in Ideascript. When I execute the following code, IDEA crash.
Function DatePiece
    Set db = Client.OpenDatabase(dbname)
    Set task = db.TableManagement
    Set field = db.TableDef.NewField
    field.Name = "ECARTDATE"
    field.Description = ""
    field.Type = WI_VIRT_NUM
    Dim a As String

Running a script on multiple databases before appending

Hi Brian,
I've got two scripts that I'd like to combine to create one process. My goal is be able to categorize each database in a .IDM file (unicode) by appending a field with the first number in each database name before appending all the databases together. Using some other scripts I've found and tweaked, I have the two separate codes I need, but I'm not sure how to put them together.  Any help you could provide would be appreciated.