User Profile
Collapse
-
Works absolutely fine... leaned up lots of code too.. Thanks a lot Hennepin. -
Hennepin: This seems much tidier and simpler for the clear filter buttons. I'll give it a try.
For the combos, I suppose you mean change the "Private Sub filterList()" to "Private Function filterList()" and change the "[Event Procedure]" to "=FilterLis t()" on the property window.
Sounds logical, will try when I get to my computerLeave a comment:
-
I'd think the select case and loop would not shorten the code either..
Nico's solution does not seem to simplify the code either. I was just curious if I was taking the long and wrong way doing the same thing for the same event for many controls but seems it's the only way.
Thanks a lot for your interest and assistanceLeave a comment:
-
The FilterList sub just changes the record source of the form:
The declarations:
The FilterList sub:Code:Option Compare Database Private Const strRowSrc As String = "SELECT * FROM qry_purchases WHERE qry_purchases.TtlQty > 0" Private Const strOrderBy As String = " ORDER BY qry_purchases.purchaseDate, qry_purchases.purchGroup, qry_purchases.purchaseSubID;"
...Code:Private Sub filterList()
Leave a comment:
-
Multiple combos event doing same action - Any practical way?
Hi, I have several combos in a form which individually filter the records in that form (continuous). The filtering process is done in a private sub filterList() and all the combos AfterUpdate event calls that procedure. Example:
...Code:Private Sub cbo_filterDate_AfterUpdate() filterList End Sub Private Sub cbo_filterSupp_AfterUpdate() filterList End Sub Private Sub cbo_filterGroup_AfterUpdate()
-
I used me.refresh instead of recalc and it worked though I still have not figured out the differenceLast edited by Niheel; Mar 17 '13, 05:16 PM. Reason: No need to disregard, you provided a solution to problem yourself. Thanks for posting it :)Leave a comment:
-
Me.Recalc in After Update event forces tab key to be pressed twice. Why?
Hello, this may seem a simple question but it does get annoying after some time.
I have a continuous subform with a hidden calculated control named 'txt_purchSubSu m' in the footer with control source as =Sum([purchUnitQty]*[purchUnitPrice]). Both purchUnitQty and purchUnitPrice are on the same subform.
On the main form, I have a textbox named 'txt_purchMainS um' with control source =[Purchase Details].Form!txt_purch S... -
Many thanks for your reply SmileyCoder.
Your code didn't work at first so I tried to debug just to know what OpenArgs is by "MsgBox Me.OpenArgs". I got an error 94 invalid use of null which is not a surprise because if you try to open the form directly, there is no OpenArgs. When I opened it clicking the button on the calling form though, it did give me the correct form name. But strangely, it still does not cancel and opens...Leave a comment:
-
Opening a form only from a button click - openargs??
Hello, I'm still using Access 2003 as I find it more "developer friendly" than "user friendly".
I really didn't use openargs much, only to pass variables but not to do an action. Now I have a question:
I have a listbox on a form which passes the value to the subform (dont ask me why I use listbox instead of comdo). I have a command button to add a list box item if it is not in the list. The list... -
Fish,
Thanks a lot for your warning.. I realized the field was long integer in stead of single. I have overlooked and took your time (also spent my time) for such a simple mistake. Sorry about that.
CelalLeave a comment:
-
Decimal problem when adding data by vba
Hi, I couldn't get around a problem about decimal rounding up when adding a record to a table from a form by programming a button.
I have an invoice form where the grand total is a calculated text field. The command button "cmdProcess " is supposed to add some fields (customer no, invoice date, grand total (as receivable), currency etc) to a table which keeps track of customer transactions. However, the decimals of grand total... -
sorry, please disregard this thread.
found my mistake in:
stAppName = "C:\Program Files\Internet Explorer\iexplo re.exe http:/www.thescripts. com/forum/" & Me.short_url & "/"
Call Shell(stAppName , 1)
only 1 backslash after http
sorry to botherLeave a comment:
-
sorry forgot to put the code of on click event for the button:
Private Sub Command14_Click ()
On Error GoTo Err_Command14_C lick
Dim stAppName As String
stAppName = "C:\Program Files\Internet Explorer\iexplo re.exe http:/www.thescripts. com/forum/" & Me.short_url & "/"
Call Shell(stAppName , 1)
Exit_Command14_ Click:
Exit Sub...Leave a comment:
-
Accessing web page through command button
I have a wierd problem here:
Suppose I have a list of tutorials on thescripts.com. I have a form that lists each one and a command button which links to the site.
All the url's of the site starts with "http://www.thescripts. com/forum" and since so, I only put the preceeding url part in the db
The problem is, the command button's onClick event fires IE, finds the url, but gives that usual "Internet... -
Not sure if I can do it but for the sake of disk space, sounds it would be better to have one subform based on different record source queries envoked when clicking on the tabs.. Will try.
Many thanks againLeave a comment:
-
Thanks so much.. So I understand I need to have subforms for each letter group??Leave a comment:
-
Filtering records over tabs
Hi,
I have a continuos form sorted alphabetically with names etc of about 250 people. I want to make it easier to browse by making it like a phone book ie, with tabs of "ABC", "DEF", "GHI" and so on. How can this be done using tabbed forms??
Many thanks for any suggestions
No activity results to display
Show More
Leave a comment: