2010-05-19, 16:08
#1
vi har fått en uppgift som ser ut så här:



Vi har funderat på att lösa bokningssystemet som på SF, hade vart lite coolt
dock lite segt att lägga in 1000 knappar kopplade till varje plats haha
Vi har funderat på att lösa bokningssystemet som på SF, hade vart lite coolt
dock lite segt att lägga in 1000 knappar kopplade till varje plats haha 
If (DLookup("Bokad", "Platser", "PlatsID = 1")) = True Then
Box0.Visible = False
Else
Box0.Visible = True
End If
If (DLookup("Bokad", "Platser", "PlatsID = 26")) = True Then
Box2.Visible = False
Else
Box2.Visible = True
End If
If (DLookup("Bokad", "Platser", "PlatsID = 51")) = True Then
Box3.Visible = False
Else
Box3.Visible = True
End If
If (DLookup("Bokad", "Platser", "PlatsID = 76")) = True Then
Box4.Visible = False
Else
Box4.Visible = True
End If
If (DLookup("Bokad", "Platser", "PlatsID = 101")) = True Then
Box5.Visible = False
Else
Box5.Visible = True
End If
If (DLookup("Bokad", "Platser", "PlatsID = 126")) = True Then
Box6.Visible = False
Else
Box6.Visible = True
End If
If (DLookup("Bokad", "Platser", "PlatsID = 151")) = True Then
Box7.Visible = False
Else
Box7.Visible = True
End If
If (DLookup("Bokad", "Platser", "PlatsID = 176")) = True Then
Box8.Visible = False
Else
Box8.Visible = True
End If
If (DLookup("Bokad", "Platser", "PlatsID = 201")) = True Then
Box9.Visible = False
Else
Box9.Visible = True
End If
If (DLookup("Bokad", "Platser", "PlatsID = 226")) = True Then
Box10.Visible = False
Else
Box10.Visible = True
End If
If (DLookup("Bokad", "Platser", "PlatsID = 251")) = True Then
Box11.Visible = False
Else
Box11.Visible = True
End If
If (DLookup("Bokad", "Platser", "PlatsID = 276")) = True Then
Box12.Visible = False
Else
Box12.Visible = True
End If
If (DLookup("Bokad", "Platser", "PlatsID = 301")) = True Then
Box13.Visible = False
Else
Box13.Visible = True
End If
If (DLookup("Bokad", "Platser", "PlatsID = 326")) = True Then
Box14.Visible = False
Else
Box14.Visible = True
End If
If (DLookup("Bokad", "Platser", "PlatsID = 351")) = True Then
Box15.Visible = False
Else
Box15.Visible = True
End If
If (DLookup("Bokad", "Platser", "PlatsID = 376")) = True Then
Box16.Visible = False
Else
Box16.Visible = True
End If
If (DLookup("Bokad", "Platser", "PlatsID = 401")) = True Then
Box17.Visible = False
Else
Box17.Visible = True
End If
If (DLookup("Bokad", "Platser", "PlatsID = 426")) = True Then
Box18.Visible = False
Else
Box18.Visible = True
End If
If (DLookup("Bokad", "Platser", "PlatsID = 451")) = True Then
Box19.Visible = False
Else
Box19.Visible = True
End If
If (DLookup("Bokad", "Platser", "PlatsID = 476")) = True Then
Box20.Visible = False
Else
Box20.Visible = True
End If
If (DLookup("Bokad", "Platser", "PlatsID = 501")) = True Then
Box21.Visible = False
Else
Box21.Visible = True
End If
If (DLookup("Bokad", "Platser", "PlatsID = 526")) = True Then
Box22.Visible = False
Else
Box22.Visible = True
End If
If (DLookup("Bokad", "Platser", "PlatsID = 551")) = True Then
Box23.Visible = False
Else
Box23.Visible = True
End If
If (DLookup("Bokad", "Platser", "PlatsID = 576")) = True Then
Box24.Visible = False
Else
Box24.Visible = True
End If
If (DLookup("Bokad", "Platser", "PlatsID = 601")) = True Then
Box25.Visible = False
Else
Box25.Visible = True
End If
If (DLookup("Bokad", "Platser", "PlatsID = 626")) = True Then
Box26.Visible = False
Else
Box26.Visible = True
End If
If (DLookup("Bokad", "Platser", "PlatsID = 651")) = True Then
Box27.Visible = False
Else
Box27.Visible = True
End If
If (DLookup("Bokad", "Platser", "PlatsID = 676")) = True Then
Box28.Visible = False
Else
Box28.Visible = True
End If
If (DLookup("Bokad", "Platser", "PlatsID = 701")) = True Then
Box29.Visible = False
Else
Box29.Visible = True
End If
If (DLookup("Bokad", "Platser", "PlatsID = 726")) = True Then
Box30.Visible = False
Else
Box30.Visible = True
End If
If (DLookup("Bokad", "Platser", "PlatsID = 751")) = True Then
Box31.Visible = False
Else
Box31.Visible = True
End If
If (DLookup("Bokad", "Platser", "PlatsID = 776")) = True Then
Box32.Visible = False
Else
Box32.Visible = True
End If
If (DLookup("Bokad", "Platser", "PlatsID = 801")) = True Then
Box33.Visible = False
Else
Box33.Visible = True
End If
If (DLookup("Bokad", "Platser", "PlatsID = 826")) = True Then
Box34.Visible = False
Else
Box34.Visible = True
End If
If (DLookup("Bokad", "Platser", "PlatsID = 851")) = True Then
Box35.Visible = False
Else
Box35.Visible = True
End If
If (DLookup("Bokad", "Platser", "PlatsID = 876")) = True Then
Box36.Visible = False
Else
Box36.Visible = True
End If
If (DLookup("Bokad", "Platser", "PlatsID = 901")) = True Then
Box37.Visible = False
Else
Box37.Visible = True
End If
If (DLookup("Bokad", "Platser", "PlatsID = 926")) = True Then
Box38.Visible = False
Else
Box38.Visible = True
End If
If (DLookup("Bokad", "Platser", "PlatsID = 951")) = True Then
Box39.Visible = False
Else
Box39.Visible = True
End If
If (DLookup("Bokad", "Platser", "PlatsID = 976")) = True Then
Box42.Visible = False
Else
Box42.Visible = True
End If
OSV....
End If
If (DLookup("Bokad", "Platser", "PlatsID = 1")) = True Then
Box0.Visible = False
Else
Box0.Visible = True
End If
If (DLookup("Bokad", "Platser", "PlatsID = 26")) = True Then
Box2.Visible = False
Else
Box2.Visible = True
End If
If (DLookup("Bokad", "Platser", "PlatsID = 51")) = True Then
Box3.Visible = False
Else
Box3.Visible = True
End If
If (DLookup("Bokad", "Platser", "PlatsID = 76")) = True Then
Box4.Visible = False
Else
Box4.Visible = True
End If
If (DLookup("Bokad", "Platser", "PlatsID = 101")) = True Then
Box5.Visible = False
Else
Box5.Visible = True
End If
If (DLookup("Bokad", "Platser", "PlatsID = 126")) = True Then
Box6.Visible = False
Else
Box6.Visible = True
End If
If (DLookup("Bokad", "Platser", "PlatsID = 151")) = True Then
Box7.Visible = False
Else
Box7.Visible = True
End If
If (DLookup("Bokad", "Platser", "PlatsID = 176")) = True Then
Box8.Visible = False
Else
Box8.Visible = True
End If
If (DLookup("Bokad", "Platser", "PlatsID = 201")) = True Then
Box9.Visible = False
Else
Box9.Visible = True
End If
If (DLookup("Bokad", "Platser", "PlatsID = 226")) = True Then
Box10.Visible = False
Else
Box10.Visible = True
End If
If (DLookup("Bokad", "Platser", "PlatsID = 251")) = True Then
Box11.Visible = False
Else
Box11.Visible = True
End If
If (DLookup("Bokad", "Platser", "PlatsID = 276")) = True Then
Box12.Visible = False
Else
Box12.Visible = True
End If
If (DLookup("Bokad", "Platser", "PlatsID = 301")) = True Then
Box13.Visible = False
Else
Box13.Visible = True
End If
If (DLookup("Bokad", "Platser", "PlatsID = 326")) = True Then
Box14.Visible = False
Else
Box14.Visible = True
End If
If (DLookup("Bokad", "Platser", "PlatsID = 351")) = True Then
Box15.Visible = False
Else
Box15.Visible = True
End If
If (DLookup("Bokad", "Platser", "PlatsID = 376")) = True Then
Box16.Visible = False
Else
Box16.Visible = True
End If
If (DLookup("Bokad", "Platser", "PlatsID = 401")) = True Then
Box17.Visible = False
Else
Box17.Visible = True
End If
If (DLookup("Bokad", "Platser", "PlatsID = 426")) = True Then
Box18.Visible = False
Else
Box18.Visible = True
End If
If (DLookup("Bokad", "Platser", "PlatsID = 451")) = True Then
Box19.Visible = False
Else
Box19.Visible = True
End If
If (DLookup("Bokad", "Platser", "PlatsID = 476")) = True Then
Box20.Visible = False
Else
Box20.Visible = True
End If
If (DLookup("Bokad", "Platser", "PlatsID = 501")) = True Then
Box21.Visible = False
Else
Box21.Visible = True
End If
If (DLookup("Bokad", "Platser", "PlatsID = 526")) = True Then
Box22.Visible = False
Else
Box22.Visible = True
End If
If (DLookup("Bokad", "Platser", "PlatsID = 551")) = True Then
Box23.Visible = False
Else
Box23.Visible = True
End If
If (DLookup("Bokad", "Platser", "PlatsID = 576")) = True Then
Box24.Visible = False
Else
Box24.Visible = True
End If
If (DLookup("Bokad", "Platser", "PlatsID = 601")) = True Then
Box25.Visible = False
Else
Box25.Visible = True
End If
If (DLookup("Bokad", "Platser", "PlatsID = 626")) = True Then
Box26.Visible = False
Else
Box26.Visible = True
End If
If (DLookup("Bokad", "Platser", "PlatsID = 651")) = True Then
Box27.Visible = False
Else
Box27.Visible = True
End If
If (DLookup("Bokad", "Platser", "PlatsID = 676")) = True Then
Box28.Visible = False
Else
Box28.Visible = True
End If
If (DLookup("Bokad", "Platser", "PlatsID = 701")) = True Then
Box29.Visible = False
Else
Box29.Visible = True
End If
If (DLookup("Bokad", "Platser", "PlatsID = 726")) = True Then
Box30.Visible = False
Else
Box30.Visible = True
End If
If (DLookup("Bokad", "Platser", "PlatsID = 751")) = True Then
Box31.Visible = False
Else
Box31.Visible = True
End If
If (DLookup("Bokad", "Platser", "PlatsID = 776")) = True Then
Box32.Visible = False
Else
Box32.Visible = True
End If
If (DLookup("Bokad", "Platser", "PlatsID = 801")) = True Then
Box33.Visible = False
Else
Box33.Visible = True
End If
If (DLookup("Bokad", "Platser", "PlatsID = 826")) = True Then
Box34.Visible = False
Else
Box34.Visible = True
End If
If (DLookup("Bokad", "Platser", "PlatsID = 851")) = True Then
Box35.Visible = False
Else
Box35.Visible = True
End If
If (DLookup("Bokad", "Platser", "PlatsID = 876")) = True Then
Box36.Visible = False
Else
Box36.Visible = True
End If
If (DLookup("Bokad", "Platser", "PlatsID = 901")) = True Then
Box37.Visible = False
Else
Box37.Visible = True
End If
If (DLookup("Bokad", "Platser", "PlatsID = 926")) = True Then
Box38.Visible = False
Else
Box38.Visible = True
End If
If (DLookup("Bokad", "Platser", "PlatsID = 951")) = True Then
Box39.Visible = False
Else
Box39.Visible = True
End If
If (DLookup("Bokad", "Platser", "PlatsID = 976")) = True Then
Box42.Visible = False
Else
Box42.Visible = True
End If
OSV....
End If
SUB Knappar()
For RAD = 1 TO 25
For STOL=1 TO 40
If (DLookup("Bokad", "Platser", "PlatsID = (rad-1)*40+STOL)) = True Then
[dölj knapp eller ersätt med dummybild]
Else
[visa knapp, räkna ut koordinater med hjälp av rad & stol]
End If
Next
Next
Flashback finansieras genom donationer från våra medlemmar och besökare. Det är med hjälp av dig vi kan fortsätta erbjuda en fri samhällsdebatt. Tack för ditt stöd!
Swish: 123 536 99 96 Bankgiro: 211-4106
Flashback finansieras genom donationer från våra medlemmar och besökare. Det är med hjälp av dig vi kan fortsätta erbjuda en fri samhällsdebatt. Tack för ditt stöd!
Swish: 123 536 99 96 Bankgiro: 211-4106