Contact US

Log In

Come Join Us!

Are you a
Computer / IT professional?
Join Tek-Tips Forums!
  • Talk With Other Members
  • Be Notified Of Responses
    To Your Posts
  • Keyword Search
  • One-Click Access To Your
    Favorite Forums
  • Automated Signatures
    On Your Posts
  • Best Of All, It's Free!

*Tek-Tips's functionality depends on members receiving e-mail. By joining you are opting in to receive e-mail.

Posting Guidelines

Promoting, selling, recruiting, coursework and thesis posting is forbidden.

Students Click Here

Impromptu CreateFilterFor OLE Automation

Impromptu CreateFilterFor OLE Automation

Impromptu CreateFilterFor OLE Automation


I'm developping an VB application who add users and restrictions on some Impromptu's catalog.

Adding users and some basic restrictions work well. But when I tri to add a filter (.CreateFilterFor), I get the message "Run-time error '13' : type mismatch". I don't understant, cause I make exactly what is in Cognos documentation.

As everyone an idea ?

I use VB6 and Impromptu 6.


Here is my code:

Set ImpNewUser = ImpUser.Add(sClassName)

With ImpNewUser
    .databaseconnections(1).UserName = CStr(txtUser.Text)
    .databaseconnections(1).PlainTextPassword = CStr(txtPassword.Text)
    If Len(txtTextBlob.Text) <> 0 Then
    .HasTextBlobLimit = True
    .MaxTextBlobCharacters = CInt(txtTextBlob.Text)
    End If
    If Len(txtMaxRows.Text) <> 0 Then
    .MaxRowsRetrieved = CInt(txtMaxRows.Text)
    End If
    If Len(txtMaxQuery.Text) <> 0 Then
    .MaxQueryExecutionTime = CInt(txtMaxQuery.Text)
    End If
    .CrossProductPermission = cboCrossProduct.ListIndex

    ' Ajout d'un filtre
    ' here is the probleme :(
    Set ImpFilter = .Createfilterfor(ImpDb.Tables("M05_V_ORGSHC_ANNEE").Columns("orgshc_ug"))
End With

RE: Impromptu CreateFilterFor OLE Automation


Here is the answer:

The exemple in help add filter for a catalog who have no catalog level nor schema level.

For working with the Oracle database, you have to use the schemalevel

set ObjLevel = objcatImp.Database(1).SchemaLevels(1)

Now the .CreateFilterFor will work :


Red Flag This Post

Please let us know here why this post is inappropriate. Reasons such as off-topic, duplicates, flames, illegal, vulgar, or students posting their homework.

Red Flag Submitted

Thank you for helping keep Tek-Tips Forums free from inappropriate posts.
The Tek-Tips staff will check this out and take appropriate action.

Reply To This Thread

Posting in the Tek-Tips forums is a member-only feature.

Click Here to join Tek-Tips and talk with other members! Already a Member? Login

Close Box

Join Tek-Tips® Today!

Join your peers on the Internet's largest technical computer professional community.
It's easy to join and it's free.

Here's Why Members Love Tek-Tips Forums:

Register now while it's still free!

Already a member? Close this window and log in.

Join Us             Close