Search results

  1. P

    Media Player ActiveX Control

    I have just tried this in Visual Basic 6.0, and it works. My conclusion is that it is something to do with the way the VBA Close command works, which is different to the VB Unload command. There doesn't seem to be any documentation available that describes what happens when you invoke these...
  2. P

    Media Player ActiveX Control

    Thanks for the reply lagbolt. I've already tried the full parameters for the command, made no difference, nor did setting the focus onto another form before closing. The timer thing seemed like a good idea, so I gave it a go. Got up to 5 seconds and still crashes out! I suppose what I need...
  3. P

    Media Player ActiveX Control

    Hi, I have a form with an ActiveX Control for Media Player 10. The player works ok, but if I try to close the form using the PlayStateChange Event, Access crashes out to the 'Send Report To Microsoft' window. This is the code:- Private Sub WindowsMediaPlayer0_PlayStateChange(ByVal Newstate As...
  4. P

    File Browsing Code Modification

    PS, forgot to mention this is for the BrowseDirectory form.
  5. P

    File Browsing Code Modification

    Hi, I have used ghudson's example for file browsing and it works great, thanks. However, the window always opens with My Computer as it's starting folder. Is there any way to make it start in another folder? I have searched on here and on the web, but all I can find is a very complicated C++...
  6. P

    Should Dcount return 0 for no records?

    Thanks DocMan, the quote around [ID] did it! That was a brilliant explanation, I finally understand how the syntax of the Dcount function works. Can I presume that the same theory applies to the othe domain functions?
  7. P

    Should Dcount return 0 for no records?

    I've tried the last suggestion, and I am still getting 'Invalid Use Of Null'. I have tried this line as the ControlSource property of a text box, as well as in the code of a command button, and still no joy. Could it be something to do with using SQL server as the back end?
  8. P

    Should Dcount return 0 for no records?

    I am at home now, so I will try this tomorrow. I don't know if it makes a difference, but the query is an SQL server 'view'. This is the only thing I can think of that might be affecting it.
  9. P

    Should Dcount return 0 for no records?

    Yep, I'd already tried it like that as well!
  10. P

    Should Dcount return 0 for no records?

    I tried that, and it still returns an error! Nz(DCount([ID], "qryReturnUsersRecords", "[LessonNo] = " & Forms!frmGetInputData!txtLessonNo), 0)
  11. P

    Should Dcount return 0 for no records?

    It seems strange to me, but I am finding that Dcount returns a 'Invalid use of null' error when there are zero records. Surely it should return 0. I can make this work by using an if and trapping the error, but it isn't very tidy.
  12. P

    Dcount, Grrrrrr......

    Thanks a lot for the prompt response guys, that did the trick (integer solution).
  13. P

    Dcount, Grrrrrr......

    Why is Dcount so damned fussy? I am trying to display a record count on a sub-form, using criteria from a text box on the parent form. This is what I have: counter = DCount([ID], "qryReturnUserRecords", "[LessonNo] = Forms!frmGetInputData!txtLesson") When I run it, I get the following error...
  14. P

    Help with record saving

    I think I am at the stage now where I can't see the wood for the trees! I have a one table db with the following fields ID(Autonumber)(PK), RollNumber,LessonNo,DataField1,DataField2,DataField3.....etc. I have a unique index on RollNumber and LessonNo, the idea being that each RollNumber can...
  15. P

    Change colour of the empty area of subform

    Is it possible to change the colour of the dark grey area that shows when a subform doesn't fill the box that has been set up for it?
  16. P

    Averages problem

    Solved this one myself, almost by accident. The calculated field in the first query was producing 1 result out of 1600 that was #error due to bad data. I was just scrolling through the results looking for inspiration and happend to spot it.
  17. P

    Averages problem

    I have a query that calculates percentages as follows SELECT dbo_tblStudents.RollNumber, dbo_tblStudents.YearGroup, dbo_tblStudents.Absence1, dbo_tblStudents.NoPoss1, ([NoPoss1]-[Absence1])/[NoPoss1]*100 AS [Absence1%] FROM dbo_tblStudents; I have called this query PercentAttend This works...
  18. P

    Passwords

    Thanks Colin, but all of the code posted, as well as the utils available on the web, are for a password on an .mdb file, not the .mdw
  19. P

    Passwords

    Hi, I need to get into an old database that was written by a previous employee and locked up tight, and no-one can remember the password. I know the password for a very restricted user, but there are not enough rights on this user to do anything useful. I can get into the back-end, but the info...
  20. P

    Like and Not Like in same criteria

    Hello Mile, I have attached a db with the form in it. I would be extremely grateful if you could come up with something simpler. I think I am at the stage now where I "can't see the wood for the trees"!
Back
Top Bottom