Search results

  1. A

    my computer cant compare dates

    thank you guys following did the job Dim dtDateNow, dtDatum As Date dtDateNow = Date Dim strWhereCondition As String dtDatum = DateAdd("d", dtDateNow, "-" & gbtBetaalTermijn) strWhereCondition = "[Betaald] = 0 AND [DatumBetAangemaakt] < #" & dtDatum & "#"...
  2. A

    my computer cant compare dates

    Hi, Im confused about the results a report is showing. I open the report with a filter; Dim strWhereCondition As String Dim dtDatum As Date dtDatum = Date - gbtBetaalTermijn strWhereCondition = "Betaald = 0 AND DatumBetAangemaakt < #" & dtDatum & "#" DoCmd.OpenReport...
  3. A

    whats wrong with my adding

    Hi I have a form where the user can Add new students; when finished the user clicks on SAVE, the programm asks the question "add a new student" From here 2 options; users clicks NO; the record got saved (this works fine) but when the user clicks YES; (the form textboxes clear) and you add a...
  4. A

    counting all textboxes

    thx, strInhoud = Nz(Me.Controls(strText), "") did the job! Al
  5. A

    counting all textboxes

    Hi im trying to figure out whats best to make my Cancel button aktive. CAncel can only be used if something is really changed (otherwise access gives me an error) So i thought of following: count all fields an if it the number changes... aktivate the cancel button so far I have Dim...
  6. A

    is it possible to 'see' which field has the focus?

    thx, for as far as my knowledge goes, you are right about the color changes , but what about the first postion? the form as an ADD student form and I would like the cursor(always) to start at the leftmost postion in the textbox. Now you click on any postion in a textbox and start typing. thx Al
  7. A

    is it possible to 'see' which field has the focus?

    Hi, I have a form with lots of textboxes. I dont want to write the same code for all of the textboxes, when the user enters the field. Me.txtboxABC.SelStart = 0 me.txtboxABC.backcolor=10092543 when the user leaves the field me.txtboxABC.backcolor=-2147483643 So, I think i just...
  8. A

    counting 1 - 2 - 4 - 8 - 16 - 32

    Thank you both! it works Al
  9. A

    counting 1 - 2 - 4 - 8 - 16 - 32

    Hi, I want to build my counter to count like above number sequence? doubling the previous value how to do this in vba? any hint or tips thx in advance Al
  10. A

    type mismatch passing values to function

    I found the solution: the right way was: .Fields("Uitstraling1") = Me.Controls("txtPunt" & X + 0).Value thanks for putting me in the right direction!! You really helped me. thx again still want to know what "CLng" does :o Al
  11. A

    type mismatch passing values to function

    oke I did change it and it goes 1 rule further; now it stops at; .Fields("Uitstraling1") = "Me.txtPunt" & X + 0 is my syntax wrong? when I try to write a field with the value on my form in txtpunt1 txtpunt2 etc. or is it wrong the way I try to add a value to my variable and attach it...
  12. A

    type mismatch passing values to function

    thx guys I chaged my code to: SaveIt InschrijfId, X as soon as i walk through the code (F8) I get (hoovering the mouse over the value) following values: inschrijfid = "774" X = 1 this looks strange to me. shouldnt the 774 also not between the ""? because Im going to write records The...
  13. A

    type mismatch passing values to function

    thx Ken I tried but with no luck: get the message: compile error: expected: = ideas Al
  14. A

    type mismatch passing values to function

    Hi, I have trouble passing my calculated values to my function. Every time I get the message Type Mismatch: this is the code I have: Dim X As Byte Dim InschrijfId As String Dim Cnt4 As Byte 'berekening van STARTnummer lezen van txtPunt velden (start: 1(1-8), 9(9-16), 17(17-24), 25(25-33) etc...
  15. A

    counter wont break if true

    thank you all for helping me out! Its working! I att a screeshot, wich (hopefully) gives more clarity. txtStudent = txtCursist (in Dutch) and are the yellow fields in the screen. when doubleclick on the listbox (downleft) or click cmdmove, the selected item has to move to the first empty...
  16. A

    counter wont break if true

    chris, And thats excactly what is should do, but it doesnt :( Meaning: the loop should lookup the first empty txtStudentX textbox. ie if txtStudent1 is occupied the loop should return txtStudent2 because thats the next empty one. but so far it only returns "" (the txtStudent1 etc are going to...
  17. A

    counter wont break if true

    Wayne, had a nice day at work? I changed your code a bit, because i need the return value to pass it in a function: For i = 1 to 6 If IsNull(Me.Controls("txtStudent" & CStr(i)) Then textboxX = Me.Controls("txtStudent" & CStr(i)) End If Next i MoveSingleItem "lstCursist", " texboxX" (or can...
  18. A

    counter wont break if true

    Wayne, thx for your quick response! It still does not work. For i = 1 to 6 If IsNull(Me.Controls("txtStudent" & CStr(i)) Then Me.Controls("txtStudent" & CStr(i)) = textboxX End If Next i when debugging it: I counts from 1 to 6 and stops (wow) but when counting the texboxX = ""...
  19. A

    counter wont break if true

    I think this is an easy one for almost everyone.. except me! I have a form wich contains 2 sets of textboxes: txtStuden1 - txtStudent12 txtPoint1 - txtPoint12 I fill the txtStudentX boxes from a listbox, No problem so far. now I try to cach the first empty txtStudent textbox with a counter...
  20. A

    Explanation of Code

    works but dunno how... can someone explain it to me I found following code on the forum It works great and I can change it for my needs BUT I cant figure out how and why its working Can someone lecture me? Dim Criteria As String Dim ctl As Control Dim Itm As Variant Dim stDocName As String '...
Back
Top Bottom