Skip to main content
Announcements
Qlik Connect 2024! Seize endless possibilities! LEARN MORE
cancel
Showing results for 
Search instead for 
Did you mean: 
Anonymous
Not applicable

settings on this computer prohibit accessing a data source on another domain

Hi,

I've wrote a simple macro: here the code:

function salva_dati_posizioni

       

        'Connect to database

        Set cn = CreateObject("ADODB.Connection")

        With cn

          .Provider = provider

          .ConnectionString = "Server="   & Server & _

                             ";Database=" & DB     & _

                             ";Uid="      & Uid    & _

                             ";Pwd="      & Pwd    & ";"

          .CursorLocation = 3

          .Open

        End With

       

       

'       

'        'Run procedure

        Set rs = CreateObject("ADODB.Recordset")

       

        set TableBox = ActiveDocument.GetSheetObject( "TB01" )

       

        for RowIter = 1 to TableBox.GetRowCount-1

                ndg_vis = TableBox.GetCell(RowIter,0).Text

                intestazione = TableBox.GetCell(RowIter,1).Text

                eta = TableBox.GetCell(RowIter,2).Text

                professione = TableBox.GetCell(RowIter,3).Text

                figli = TableBox.GetCell(RowIter,4).Text

                referenze = TableBox.GetCell(RowIter,5).Text

                note = TableBox.GetCell(RowIter,6).Text

               

                ndg = String(14-len(left(ndg_vis,len(ndg_vis)-3)),"0") & left(ndg_vis,len(ndg_vis)-3) & right(ndg_vis,2)

               

                qry = "UPDATE TABLE " & _

                          "SET ETA = '"&eta&"', " & _

                             "PROFESSIONE = '"&professione&"', " & _

                              "FIGLI = '"&figli&"', " & _

                              "REFERENZE = '"&referenze&"', " & _

                              "NOTE = '"&note&"' " & _

                         "WHERE NDG = '"&ndg&"'"

               

                rs.Open qry, cn, 0, 1

           

                'rs.Close

        next

        cn.Close

       

end function

I've developed the application on QV Server 10. When I access the application throght my pc all is ok and work fine.

When other users try to access them the qvw document is shown, but the macro fails with error:

settings on this computer prohibit accessing a data source on another domain

May be some activeX issue? How can I fix the problem?

I just create an ADODB connection directly to the server and execute the update. The qvw document is browsed with IE plugin.

Let me know if anyone encountered this problem and how can I solve that.

Thank you!

Matteo

0 Replies