question

Upvotes
1 0 0 0

Running RDP.Price in VBA

Hi, we have recently migrated the user to Workspace, and later he found some VBA issues. He wanted to find out if there’s any way to run RDP.Price via VBA and assign the result to a variable?

Previously he could write a function that waited until the output of the function was no longer “Retrieving” i.e. like so:

Function getField(feed As String, ric As String, field As String) As String

Dim data

data = Application.Run("RtGet", feed, ric, field)

Do While VBA.Left(CStr(data), 3) = "Ret" 'ie loop while it is retrieving data

Application.RTD.RefreshData

DoEvents

data = Application.Run("RtGet", feed, ric, field)

Loop

getField = CDbl(data)

End Function

This doesn’t work with just switching to RDP.Price.

To clarify it does work as a cell function, but when calling via VBA it returns Empty. It doesn’t even get to the stage where it returns “Retrieving…” in his loop.

Can you help please? Thank you!

workspace#productvba
icon clock
10 |1500

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

1 Answer

· Write an Answer
Upvotes
87.1k 294 53 79

@dianne.ocumen

Thank you for reaching out to us.

I tested it and it doesn't work.

Please contact the Workspace Excel support team directly via MyAccount regarding how to use the RDP.Price function in VBA.

icon clock
10 |1500

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Hi @Jirapongse

Appreciate you looking into this. I will reach out to the WS Excel support team, per your advice.

Thanks!
Dianne

Write an Answer

Hint: Notify or tag a user in this post by typing @username.

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.