cancel
Showing results for 
Search instead for 
Did you mean: 

Queries refreshing at the same time

Former Member
0 Kudos

Hi eb!!

In my BEx, when click in the refresh query in a cell that isn't a query's cell, ask to me about to refresh every queries in the workbook, and i answer yes (of course, what was you thinking?). After that i select the values for the filters and go (exec. the query F8) and the problem is that the filters are just applied to the SAPBEXq0001 and the other one remains not filtered.

The two queries in the workbook are the same one (i know that it's illogical but .... it's not your business, told to me).

Any idea to make the filters acts for the two queries?

Excuse my poor english and thank you very much.

Accepted Solutions (0)

Answers (1)

Answers (1)

Former Member
0 Kudos

Hi,

In the properties you have the option of refreshing all the queries of the workbook when opened. just check it. All the queries will be refreshed.

check the below link.

Message was edited by: AVR - IGA

Former Member
0 Kudos

I have cheked this box but it doesn't works, that's the reason because i have posted a this question.

Now i`m using a trick: i have a botton, in the presantation sheet, thar launch the next code (in a module)

Set r = Range("SAPBEXqueries!SAPBEXq0001")

Run "sapbex.xla!SAPBEXrefresh", False, r

Set r = Range("SAPBEXqueries!SAPBEXq0002")

Run "sapbex.xla!SAPBEXrefresh", False, r

But they don't want to have this botton in the presentation sheet of the workbook

Former Member
0 Kudos

Hi,

I understood your problem. you need write VB code in macro to add a button in the workbook which when pressed will refresh the sheet. If my understanding is wrong please get back with details. If my understanding is right I can give you macro code.

Former Member
0 Kudos

Sorry, you are wrong, i have the VB code for this botton. Look that:

'module

Sub accion()

Set r = Range("SAPBEXqueries!SAPBEXq0001")

Run "sapbex.xla!SAPBEXrefresh", False, r

Set r = Range("SAPBEXqueries!SAPBEXq0002")

Run "sapbex.xla!SAPBEXrefresh", False, r

End Sub

'button

Private Sub CommandButton1_Click()

Call accion

End Sub

This is my VB code, and this works, but the problem is that "the client" don´t want to have an extra botton on the sheet and want to the BEx refresh query add oc botton works refreshing both queries.

It's seem that's something wrong whit the BEx, (not my code) but i don't know what can it be.

Thank you.