Extract Subform Data to a Table ?

007

New member
Local time
Today, 02:53
Joined
Dec 4, 2006
Messages
4
i am sure there may be an easy way of achieving this but after 2 days trying...it's beyond me !

I have a mutli record continuous subform with some calcualtions behind some of the txt boxs, therefore they cannot be linked back to table fields. i want to extract the results of this subform into a table and create new records according to the number of lines in the subform.

Have tried via a query then a second copy subform on the same form linked to the table I wish to write to, can't get either to work and I feel like I am taking a long route to a simle task.
 
My feeble brain does not understand your explaination well enough to offer a suggestion. Any chance you could try wording it differently? Are you trying to store calculated information?
 
My feeble brain does not understand your explaination well enough to offer a suggestion. Any chance you could try wording it differently? Are you trying to store calculated information?

So Sorry

Will go the whole hog and tell you why i've done it via a form.

Bascially I need to rank players for their finishing places in a tournament (Golf), so for example one player wins (P1) then three placers come 2nd (P2) then next best score comes 5th (P5) as 4 players are before him and so on.

I have done this on a form as I can refer easily back to the prior record which I need to do for this to keep a running total of players. I have done this by calling a function (which I picked up on here) from the text box on the form which gives me a running total of the players so I can work out my finishing positions.

So I now have all the data I want on the form but need to get it back into a table so I can use it. I suppse the easy way is not to use a form and build this ranking system directly into the query but I have tried and failed at that as i can't get the query refer to it's prior record's value.

Code i call is..

Public TC As Integer
Public LC As Integer


Public Function ZeroCount()
TC = 0
End Function
'Jon Added

Public Function TruePos()
TruePos = LC + 1
End Function


Public Function PosTotal(frm As Form) As Variant

With frm.RecordsetClone
LC = TC
.Bookmark = frm.Bookmark
TC = TC + .players
PosTotal = TC

End With

End Function
 
Last edited:
I would do a search of this forum on "Ranking". I just tried it and there are lots of threads that address this issue.
 

Users who are viewing this thread

Back
Top Bottom