Qlik Community

QlikView Scripting

Discussion Board for collaboration on QlikView Scripting.

Announcements
QlikView Fans! We’d love to hear from you.
Share your QlikView feedback with the product team… Click here to participate in our 5-minute survey.
Rules, plus terms and conditions, can be found here.
Not applicable

ActiveDocument.DynamicUpdateCommand doesn't work

Hi all,

I use the following to load some data:

LOAD * INLINE [

    Alpha, Beta

    a, 0

    b, 0

    c, 0

    d, 0

    e, 0

    f, 0

    g, 0

];

I have the following macro's (taken from the QlikView Automation Reference and updated to match the fields):

sub Update

     SET Result = ActiveDocument.DynamicUpdateCommand("UPDATE * SET Beta = 1")

     if Result = false then

          MsgBox Result.ErrorMessage

     end if

end sub

sub Insert

     SET Result = ActiveDocument.DynamicUpdateCommand ("INSERT INTO * (Alpha, Beta) VALUES (x, 0), (y, 0), (z, 0)")

     if Result = false then

          MsgBox Result.ErrorMessage

     end if

end sub

I have a two buttons from which i trigger the Update and Insert macro.

For some reason the values doesn't get updated or inserted. When i trigger one of these macro's the Edit Module opens and the line starting with SET Result .... is highlighted.

Any sugestions on how to resolve this issue?

2 Replies
Not applicable

Re: ActiveDocument.DynamicUpdateCommand doesn't work

Hi Laming2911

Check your document properties. On the server-tab the option Enable Dynamic Data Update should be on.

Not applicable

Re: ActiveDocument.DynamicUpdateCommand doesn't work

After Checking the option Enable Dynamic Update it is working perfect.

Community Browser