I would like to create a query based on the 3rd & 4th characters in a field. The total field is 8 characters.
ex. find all records where those characters are "FR"
field name is trkNum.
Any ideas?
I tried making it global (access dropped the word global & just left it as Sub Open_...)
This created problems with just opening the form (suddenly fields weren't recognized)
even when I tabbed by the "parameter boxes" that were created by those errors, I still got the same error.
ld like to put some recordset handling in a common module. When I try to call it from a form I get an error:
"The expression On Click you entered as the event
property setting produced the following error:
Invalid Outside Procedure.
* The expression may not result in the name of...
Never mind. The problem has something to do with me using it as a function inside of a form, instead of a module. (don't know why, or if that's a part of the "immediate window"'s functioning.
Can someone explain to me how to use a "module" for something, instead of having the code stored within a form?
and/or where I can find information on it?
Thanks
I took the following function code from an articl "How to: Find the Number of Days in a month in Access 2000. Problem is, when I try to test it like they say:
"In the immediate window type ?DaysInMonth(Date())"
I get a visual basic "Run-time error '13': Type mismatch" error.
Function...
I want to use a msgbox to display a "Yes" & "No" button. If "Yes" is pressed I want to perform fnct1. If no is pressed I just want to cancel/clear the msg box.
Can I do this? & how would I indicate the function to perform on "Yes" selection?
I have a cboPOC on a main form. When I select that POC, I want to access the POC table and update the dtLastUsed field in the POC table. (intPOC is the key to POC table, and the bound field for the cbo) I am using ADO. How might I do that?
Thank you BarrySprout, ProgramError & AceMan1,
That makes it much clearer. I especially like your explanation AceMan1. That shows exactly what I was looking for.
A break in hours is any missing hour(s) in the same day. so if: user1 6-9, user1 11-12 that would be 2 records
user1, day1, 6, 9
user1, day1, 11,12
Since this is based on hours in the day, could be a max of 24 hours. No limit on how many hours can be "missing".
I'm not really...
I have a table it looks something like
recNum user Day Hour
1. I need to find out the Min Hour & Max hour on a given day for a given user.
2. If there is a break between hours, I need a new record that has the min hour & max hour for that period
i.e. if user1 has 8/22 hours 2 through...
I would like to use Msgbox to display some information. The catch is, I want it broken down by specific lines. How would I insert a carriage Return/Linefeed into the Msgbox.
What I currently have:
MsgBox "Request Added.", vbOKOnly + vbInformation, "Record Added
I have a form which uses a cbo to find a record. It has a reset button on it.
I would like to trap the event/error when the button is pressed. Now if a record is selected, but not changed, it gives an error "The command or action 'Undo' isn't available now." I would like it to re-set the cbobox...
I tried:
Expr1: IIf(IsNull([tblPendReq]![intRmID]),[tblRoomName]![txtRoomName],[tblRoomType]![txtRoomType])
I have 3 tables; PendReq (primary table for this form)
RoomName(key=intRmKey), & RoomType(key=intRmTypeID).
PendReq has a tracking Number, RoomType, and room Name fields. (RoomName can...
I have a mainform which will be used to select a record. It refreshes the data on the main form based on the cbo, as it should, however, I need it to also refresh the subform.
How might I do this?
Maybe I'm missing something.
I'm looking at the properties for the textbox, on the form.
These are the options I find:
Control Source, Format, Decimal Places, Input Mask (which is >000000LLLL00), default value, IME Hold, IME Mode, IME Sentence Mode, Validation Rule, Validation text, Enter Key...
Is there a way to set the cursor location to the first character position when the user clicks on a formatted field? Currently when I click on the field it usually puts me in the middle of the field (wherever the mouse clicked)
Maybe I'm making this too difficult. Here's the scenario. I have a submittal to use a resource. A person can select multiple start and end dates and multiple begin and end times. An example would be:
start start End End
date: hour Date: Hour:
Jan 1 10:00 Jan 5...
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.