Search results

  1. J

    Help with ApplyFilter on a Subform

    Its bad practice to have spaces in your form names, will be alot easier if you rename then without the spaces. After removing spaces you could use different code to ahieve your desired results. Private Sub CboFilterDate_AfterUpdate() If form_IssuesSelectionandReporting.CboFilterDate = "Today"...
  2. J

    deleting all entries in MS access

    Just compact the database, make sure 'Compact on Close' is checked on the "Tools > Options... > General" tab. It will then reset all autonumbers on exit, aswell as clearing up the other mess.
  3. J

    open folder from hyperlink

    Beings you're being a messy coder I'll clean it up a little because i'm bored :P Public Function DisplayImage(ctlImageControl As Control) As String Dim strImagepath As Variant On Error GoTo Err_DisplayImage ' 'PATH to DEFAULT FOLDER '====================== strImagePath = "c:\temp\" & intPath &...
  4. J

    If Isnull() function

    Also it may be better to place the code inside the OnCurrent event or the OnDirty event depending on how you're going to use it. (OnLoad will only affect the first record in your recordset)
  5. J

    If Isnull() function

    I think this will work, If isnull(me.dlookup1.value) then me.dlookup.value = "0"
  6. J

    Button to open subform within current form?

    Private Sub Open_subform_attendance_Click() On Error GoTo Err_Open_subform_attendance_Click Dim stDocName As String Dim stLinkCriteria As String Child31.SourceObject = "SUBFORM: ATTENDANCE DETAILS" if both.value = yes then stLinkCriteria = "[SHIFTNAME]=" & "'" & Me![SHIFTNAME] & "'...
  7. J

    Button to open subform within current form?

    Just open your form, add a subform/subreport control, this will probably be called child0 depending on what version of access you're using, then just place this code in your command button substituting FormName for whatever your form is called. Child0.sourceobject = "FormName"
  8. J

    Reset Public Variable Value to Zero

    Ok this should work, resets the variables every second. Public BgnAmount As Currency Public CurrencyCode As String Public Function RunSum(crd As Currency, dbt As Currency, CurrencyID As String) As Currency Me.TimerInterval = 1000 BgnAmount = 0 ' Resets the Variable CurrencyCode = "" If...
  9. J

    temporary table for VBA Access

    Quick translation for those who may be able to help him but may not undertsand what he's saying: Hi all, My project uses Access forms for the front end, It also uses SQL Server as the back end, my question is, is it possible to use temporary tables in SQL Server with VBA in access, if so, how?
  10. J

    Need help to detect event

    Just replace dofunction with your function or sub or whatever, Replace TXTBOX with the name of the text box. Private Sub TXTBOX_KeyDown(KeyCode As Integer, Shift As Integer) If KeyCode = 13 Then DoFunction End Sub
  11. J

    DSum not working :S

    Ah I'll read into them now(Would've read sooner but I assumed you meant they would help with my last problem only :P) Thanks :D Nothing seems to help :(, is there a DAO alternative to DLookup that you guys know of?
  12. J

    DSum not working :S

    Ruralguy, can't believe I forgot Option Explicit :$, cur is a public variable, anyway, got it working now, one more question though while we're here Dim res1 As String Dim res2 As String Dim pno As String pno = Part_No.Value res1 = DLookup("[Size]", "[Products List]", "[Part No] = '" & pno &...
  13. J

    DSum not working :S

    [Products] is a table, I'll try adding set rs = nothing, should I place that at the end? Private Sub Form_Dirty(Cancel As Integer) If Filtered1 = True Then Me.CompanyID = Cur Dim RS As DAO.Recordset Set RS = CurrentDb.Openrecordset("SELECT SUM([Price Each] * [Quantity]) As Result FROM...
  14. J

    Difference performance levels for diff users with seemingly the same set-up?!

    Damn, sounds very odd what with you having identical setups.
  15. J

    DSum not working :S

    Mmmm, I have the latest Jet Service Pack, I'm not using linked tables, and I've only got like 6 tables and 6 queries, I'm using a subform but that means I only have 2 forms open at a time with around 7 bound controls at a time :S.
  16. J

    Difference performance levels for diff users with seemingly the same set-up?!

    Just as a test, try running it locally.
  17. J

    Difference performance levels for diff users with seemingly the same set-up?!

    Have you tried compacting the database(Tools>Options>General>Compact on Close)? I'm afraid I can't answer if the code's locked into your profile or not, I've never heard of this happening.
  18. J

    Difference performance levels for diff users with seemingly the same set-up?!

    I suppose you could make sure you have the latest Oracle software on each machine, although by the sounds of things you already have.
  19. J

    DSum not working :S

    Set RS = CurrentDb.Openrecordset("SELECT SUM([Price Each] * [Quantity]) As Result FROM [Products] WHERE [Order ID] = " & Form_Orders.OrderID.Value) Too few parameters. Expected 1. pops up with that error now, I should probably familiarise myself with DAO some time :$. Edit: I needed the [Order...
Back
Top Bottom