Search results

  1. C

    code to create a list for combobox from filter

    I'm not sure what you are using to establish the User connected to the Database so I'll just wing it. It sounds like you have the First Combo down pat anyways...: Establish a Public String Variable name UserName to hold the User Name. Ensure that the the variable is filled when the user logs in...
  2. C

    Forcing a user to close database with command button

    In the Form which contains your Exit Database button, place the following code into the Forms' OnUnload event. It should look like: Private Sub Form_Unload(Cancel As Integer) MsgBox "Please Close This Database By Using The" & vbCr & _ "QUIT Button Located On Main Form."...
  3. C

    Control Scroll Bars in Access 2007?

    It's all a matter of sizing. Scroll bars in a Combo Box are automatic. The Vertical Scroll Bar is determined by the List Rows property. If there are more items within the list than what is indicated within the List Rows property then you will get the Vertical Scroll Bar. This of coarse makes...
  4. C

    Apply Check on Duplicate Entry

    The method MStef has provided is the better way to go and should be done. The method I provided allows you to trap the situation before it reaches the table and therefore provide your own message rather than the default MS-Access message and to perhaps handle other things such as provide...
  5. C

    Apply Check on Duplicate Entry

    Place this into the BeforeUpdate Event for the InvoiceNo TextBox on Form: If Nz(DLookup("[ID]", "[YourTableName]", "From='" & _ Me.FromFieldOnForm & "' AND InvoiceNo=" & _ Me.InvoiceNoFieldOnForm), 0) > 0 Then MsgBox "The Invoice Number you have supplied is...
  6. C

    TransferText- Importing a CSV file

    You need to supply a schema file. See TransferText in MS-Access Help. You can use the wizard to create the Schema file or create it yourself. .
  7. C

    DoCmd.OpenReport Code Error

    Is Gender in the Table the query is working from? Is Gender spelled the same as it is in Table? Do you have a Field in the Report (hidden or not) that holds the Gender? Is Gender in table actually holding a numerical value or is it holding string value such as "Male" or "Female"? If it is then...
  8. C

    subform and recordset

    You can save yourself the step of creating the recordset. Whatever query you used to create the Recordset, drop it directly into the Record Source of the SubForm: Me.MySubForm.Form RecordSource = "SELECT * FROM MyTable WHERE Whatever = Whatever;" .
  9. C

    Delete all items in a comboBox

    If your Combo Box Row Source Type is set to Value List then: Me.MyComboBox.RowSource = "" as missinglinq so kindly pointed out should clear the Combo List. This should also clear the Combo list even if the Row Source Type is set to Table/Query. It will not however clear the Text Box area of...
  10. C

    i have to press escape when i open a form

    It would be tough to say what could be causing something like this especially without looking at the Database. I personally have never encountered this. I find, most often when something goes stupidly wrong, the Form crashes and becomes corrupt and is usually non-recoverable and it's almost...
  11. C

    Creating a Folder in Medium date Format

    Whoops....LPurvis beat me to it...Sorry :o
  12. C

    Creating a Folder in Medium date Format

    Add this line of code to the Declarations section of a Database Code Module (not a Form code module): Public Declare Function MakeSureDirectoryPathExists Lib "imagehlp.dll" (ByVal lpPath As String) As LongAnother Path In the same Database Code Module, add this function, MakePath: Public...
  13. C

    Help with code very much needed. Please

    A thought for starters: Although Microsoft Windows operating systems today allow for long paths and file names with spaces in them, Microsoft Outlook does not within Hyperlinks. Long paths and file names are Okay but for some reason, Outlook doesn't care for spaces within a Hyperlink string and...
  14. C

    using this formula to autosave and update

    Well then you are looking at a Backend database (Back End of a Database split) or, there just hasn't been a Startup Form issued for the Database yet. This must be done from a Front-End Database. .
  15. C

    Help with code very much needed. Please

    Ok...this would have been a lot easier to see if you code was formated within a code window using the [ code ] and [ /code ] tags, but in any case.... The reason why you are always getting the message Outlook is not running, Launch Outlook and try again is because the code is always allowed to...
  16. C

    using this formula to autosave and update

    When you start you Access Database, what is the very first Form that is displayed on screen? Place that Form into Design View, open the Properties Window, select the Events tab on the top of the Properties Window the scroll down until you see On Open. Double-click in its' property window, Event...
  17. C

    DLOOKUP with multiple date criteria one of which is function

    Read the Access Help file with regards to the DMax function. .
  18. C

    Directory Creations

    By creating or rather nesting individual folders one by one on the fly, so to speak , requires you to set focus to each new folder using the ChDir function before the next sub-folder is created. By the time the nest is finished, disk focus will be in the last folder created. The better...
  19. C

    Help with code very much needed. Please

    What is the Error you are getting? This would be helpfull and it may be the root of your second problem :) .
  20. C

    Compile Error Expected: end of statement

    DOH! .... A double post :D .
Back
Top Bottom