Option Compare Database
Sub soru4()
Dim db As Database
Dim rst As Recordset
Set db = CurrentDb
Set rst = db.OpenRecordset("Tablo1")
Do Until rst.EOF
rst.Edit
If rst.Fields("fiyat").Value > 100 Then
a = rst.Fields("fiyat").Value * 0.5
Top = a + rst.Fields("fiyat").Value
rst.Fields("fiyat").Value = Top
End If
If rst.Fields("fiyat").Value < 100 Then
a = rst.Fields("fiyat").Value * 1
Top = a + rst.Fields("fiyat").Value
rst.Fields("fiyat").Value = Top
End If
rst.Update
rst.MoveNext
Loop
End Sub
Yorumlar
Yorum Gönder