User Profile

Collapse

Profile Sidebar

Collapse
dana1
dana1
Last Activity: Feb 28 '08, 09:19 PM
Joined: Mar 14 '07
Location:
  •  
  • Time
  • Show
  • Source
Clear All
new posts

  • Your suggestion worked quite well. I wrote a little "find and replace" type of function, and just before I open the report I use it on the string in the .sql property of the saved query to replace any instances of my parameter ("[pSite_ID]") with a reference to the control on the form ("[Forms]![frmReportBuilde r].[obsoleteSiteMed iaComboBox]"). Then after I run the open report command, I use the "find and replace"...
    See more | Go to post

    Leave a comment:


  • That makes sense.. So instead of trying to set the parameter value, I can just access the .sql property of the query def and replace the "parameter" part of the string with a reference to the appropriate control on form. That might actually work.

    I'll play around with it this afternoon and let you know. Thanks!
    See more | Go to post

    Leave a comment:


  • dana1
    started a topic Setting query parameters from VBA for a Report

    Setting query parameters from VBA for a Report

    Hello Experts!

    Does anyone know if there is a way to set the values of query parameters from VBA for a report's recordsource? (i.e., I want to set the values of the parameters and NOT have the user prompted for them).

    Based on a Microsoft page (http://support.microso ft.com/kb/287437), I tried the following approach:

    Code:
    Private Sub Report_Open(Cancel As Integer)
        
        Dim sql
    ...
    See more | Go to post

  • Here's the verdict:

    Creating brand new buttons from the wizard and making no modifications to them do the same thing, so maybe what I'm seeing is some undocumented "feature" of Access. (Maybe because the buttons are in the Header of the form the focus on them is different? I've done similar things with buttons in the footer and had no problems)

    The best solution for the navigation buttons seems to be to...
    See more | Go to post

    Leave a comment:


  • Thanks Denburt. I'll try creating new buttons next week and let you know how that works out.

    Dana
    See more | Go to post

    Leave a comment:


  • Denburt,

    Good thought-- I hadn't thought to check that. Unfortunately, it does not appear that they are toggle buttons. I don't see how to tell the type of the control from the GUI, but the ControlType property returns 104, which is a command button. Also, the Value property isn't available from VB, so it appears that is not what is going on.

    It's not really the "snapping back" part that is the problem....
    See more | Go to post

    Leave a comment:


  • ....Actually... like the overlapping thing, this only works for some buttons. And, it ends up leaving a green "highlight" instead of an orange "highlight" (probably XP theme colors for something) on the buttons I use it on. The green highlight isn't permanent, but it displays or doesn't display depending on whether the button next to it is enabled/disabled (or so it appears).


    [QUOTE=dana1]One thing that...
    See more | Go to post

    Leave a comment:


  • One thing that does appear to work is to disable/enable the button. Again, this isn't really a good solution...

    But I guess it will work if we can't figure out why the behaviour is happening in the first place.

    Code:
    Private Sub lastComputer_Click()
    On Error GoTo Err_lastComputer_Click
    
        searchComputerIDArrayCurrent = UBound(searchComputerIDArray)
        displayCurrentSearchResults
    ...
    See more | Go to post

    Leave a comment:


  • Mary,

    Thanks for responding. No luck with the Me.Refresh, unfortunately. Any other ideas?

    Even setting the Visible property to False and then back to True doesn't reset the way they're displayed, they still show that "highlight" permanently after they've been clicked. I also tried Me.Repaint, and that did not work either.

    Thanks,
    Dana
    See more | Go to post
    Last edited by dana1; Mar 21 '07, 06:47 PM. Reason: adding another thing I tried that didn't work

    Leave a comment:


  • Buttons still appear "highlighted" after being clicked

    I have a form which contains some buttons. The buttons use some of the standard images that come with access 2003 (e.g., the move next record image, or the sort ascending/descending images). The default behavior for access is to give the button a "highlighte d" appearance when the button is hovered with the mouse.

    My problem is that these buttons permanently have that "highlighte d" appearance after they have been...
    See more | Go to post

  • dana1
    replied to KeyDown event doesn't occur for Text Box
    Sheepishly... I must admit that only moments after posting, I thought of one more thing to try. The event procedure, for whatever reason, didn't get hooked up properly to the text box. So, I went into my text box properties and set the onKeyDown property to [Event Procedure] and everything is great.

    Sorry!

    Although if anyone has any ideas about that 2110 error.. feel free to respond :-)

    Dana
    See more | Go to post

    Leave a comment:


  • dana1
    started a topic KeyDown event doesn't occur for Text Box

    KeyDown event doesn't occur for Text Box

    I have a form with several combo boxes in the header used to determine the records that will be displayed on the form. When I tab or enter from the last combo box in the header, I want the focus to move to the first control on the form. When I Shift+tab from the first control on the form, I want the focus to move to the last control in the header. The form is a continuous form.

    The first control on the form is either a text box...
    See more | Go to post
No activity results to display
Show More
Working...