Need help for "For next"

alpertunga65

Registered User.
Local time
Today, 08:03
Joined
Mar 15, 2013
Messages
21
:confused:hello,

I need help to run "For..next loop"

I have a table named as FrequencyList (fields are; FreID, Frequency)

I want to create a frequency list between "firstfrequency" and "lastfrequency" by a form

I made a For..Next loop and put a msgbox at the end of the loop.

When I push the button I get the message, but the loop is not working and not recording in the table.

I cannot create the list.
Could you please help...

here is for..next loop

Private Sub Komut20_Click()
a = firstfrequency.Value
b = lastfrequency.Value
c = FreInt.Value

For i = a To b Step c
Next i
i = b
If i = b Then
MsgBox "Frequency Table has been completed."
End If
DoCmd.DoMenuItem acFormBar, acRecordsMenu, acSaveRecord, , acMenuVer70
End Sub
 
DoCmd.DoMenuItem acFormBar, acRecordsMenu, acSaveRecord, , acMenuVer70

DoMenuItem has been deprecated since 2000. It is retained for backwards compatibility but should not be used in new designs.
 

Users who are viewing this thread

Back
Top Bottom