Hi,

I'm fairly new to Access and VBA and I'm entirely self-taught (via google and extremely helpful sites like this one), so please forgive me if this is a stupid question.

I have an Access 2007 report that calls a query to display information about individual entries in an online database. Each cell in the report has individual bits of information that together make up the URL for the web page. I could end up with a report that looks like this:

__________COLOR___NUMBER___ANIMAL
row 1:____red_____five_____tiger
row 2:____blue____two______lion
row 3:____green___seven____penguin

And, for example, I'd need to open up this url:

http://www.davesdata.com/red/five/tiger
or
http://www.davesdata.com/green/seven/penguin

I currently have it set up so that I can click a button and a bit of VBA code is called that asks me for each piece of data, which I then have to type in manually:

------------------------------------
Public Function createLink()

Dim color As String
system = InputBox(Prompt:="Enter the Color:", _
Title:="Color", Default:="")

Dim number As String
number = InputBox(Prompt:="Enter the Number:", _
Title:="Number", Default:="")

Dim animal As String
animal = InputBox(Prompt:="Enter the Animal:", _
Title:="Animal", Default:="")

FollowHyperlink Address:="http://www.davesdata.com/" & color & "/" & number & "/" & animal & ""

End Function
------------------------------------

But what I want to do is add a button on each row of the report that, when clicked, will call a VBA script to populate the variables with the appropriate values from that row to plug them into the URL.

I haven't been able to find a way to refer to the individual cell values on a particular row of a report and store them as variables.

I am grateful for any information or assistance!

Thanks,
Dave