Go Back   Access World Forums > Search Forums

 
Showing results 1 to 25 of 500
Search took 1.17 seconds.
Search: Posts Made By: Pat Hartman
Forum: Modules & VBA Yesterday, 02:39 PM
Replies: 10
Views: 91
Posted By Pat Hartman
Re: Access VBA DAO records need to know ID field

Here's the correct way to find the ID of the inserted row. This app started out as Jet/ACE and was converted to SQL Server and this was one of the necessary changes.

The original code picked up...
Forum: Forms Yesterday, 02:27 PM
Replies: 7
Views: 77
Posted By Pat Hartman
Re: copy value from form to subform

Glad you are happy but just because it seems to work, doesn't mean that the solution is sound. YOU are dirtying a record rather than the user This code will end up creating "empty" records if the...
Forum: Forms Yesterday, 01:57 PM
Replies: 19
Views: 210
Posted By Pat Hartman
Re: Time Stamp after clicking a Command Button

Bound forms are soooooo much easier to use :)
Forum: Forms Yesterday, 01:55 PM
Replies: 7
Views: 77
Posted By Pat Hartman
Re: copy value from form to subform

Do NOT dirty records before the user does. If you want to copy a field from the main form to the subform, do it in the subform's BeforeInsert event. This event runs immediately when the user types...
Forum: Queries Yesterday, 01:47 PM
Replies: 12
Views: 105
Posted By Pat Hartman
Re: Exact age

Here's a sample database that I've posted multiple times.
Forum: Queries Yesterday, 11:09 AM
Replies: 9
Views: 93
Posted By Pat Hartman
Re: uncombine string

You could end up spending more time looking for and testing a band aid than it would take to actually fix the problem.

Fixing it might be as easy as identifying all the queries that select the...
Forum: Forms Yesterday, 10:58 AM
Replies: 5
Views: 74
Posted By Pat Hartman
Re: When checkbox checked it shows textbox

The line of code in the current event does what the multiple lines of code in the other the other procedures does. Although you would need to make it a goggle. You could do that by first setting...
Forum: Forms Yesterday, 10:50 AM
Replies: 14
Views: 110
Posted By Pat Hartman
Re: Conditional visibility based on input

Normalizing the schema would make this oh so much simpler. Then you could give the students access to a subform in Data Entry view. This brings up an empty form and allows them to add a new record....
Forum: Forms Yesterday, 10:41 AM
Replies: 8
Views: 1,449
Posted By Pat Hartman
Re: Sending SMS to phones.

We've had a lot of this lately. Something is popping old threads to the top of the list. I recently responded to one as the first response in several years. I wasn't doing a search so I didn't...
Forum: Queries Yesterday, 10:17 AM
Replies: 9
Views: 93
Posted By Pat Hartman
Re: uncombine string

It would be a far better solution to actually fix the underlying design problem. You shouldn't be storing the concatenated value to begin with. If you don't store it, you don't have to break it...
Forum: Queries Yesterday, 10:05 AM
Replies: 4
Views: 52
Posted By Pat Hartman
Re: Query with Date Range and Duplicates

Plog beat me. I was going to suggest a non-equi join but went with the WHERE clause instead. Try both to see if one is faster than the other.
Forum: Queries Yesterday, 10:03 AM
Replies: 4
Views: 52
Posted By Pat Hartman
Re: Query with Date Range and Duplicates

Using the QBE, create a query that joins the two tables on PatientID. Select the columns you want from each table. Then switch to SQL view to add the WHERE clause.

Where tblPatient.DiagDT...
Forum: Queries Yesterday, 09:56 AM
Replies: 12
Views: 127
Posted By Pat Hartman
Re: Update Query with percentage value

What was wrong with the solution proposed by Guus2005? I think the update query needs criteria because you should not be updating historical records but aside from the Guus2005's solution is correct.
Forum: Modules & VBA Yesterday, 09:42 AM
Replies: 9
Views: 15,591
Posted By Pat Hartman
Re: SetFocus Tab Control Page

The tab control is not in the reference hierarchy of a form's objects. So, to reference a field on a form:

Forms!someform!somefield

To reference a field on a subform
...
Forum: Reports Yesterday, 09:26 AM
Replies: 4
Views: 76
Posted By Pat Hartman
Re: Reports displays more than selected records

If your field is actually stored as "1.01", that will make it more difficult to work with. NEVER mush two values into a single field. You should have two numeric fields rather than a single text...
Forum: Reports Yesterday, 09:20 AM
Replies: 6
Views: 96
Posted By Pat Hartman
Re: Davg in report group footer

When calculating overdue, return null rather than 0 when the item is not overdue. The domain functions will ignore nulls but will include zero so:

Avg(3,0,3) = 2
BUT
Avg(3, null, 3) = 3

Then...
Forum: Forms 10-15-2019, 05:04 PM
Replies: 14
Views: 15,811
Posted By Pat Hartman
Re: Highlighting the contents of a textbox on entry.

I'm working on getting that changed. Every year when I send my Christmas wish list to the MS Access team, a way to control properties for THIS database specifically and for new databases created by...
Forum: Forms 10-15-2019, 04:58 PM
Replies: 19
Views: 210
Posted By Pat Hartman
Re: Time Stamp after clicking a Command Button

You can never get back data that you don't explicitly save. So, theDBGuy gave one solution that will work. If you don't like that one, we can provide others but they will be more complex since I'm...
Forum: Forms 10-15-2019, 04:55 PM
Replies: 9
Views: 139
Posted By Pat Hartman
Re: Form Code

If you want us to debug code, you need to post it. Even better, post the database with instructions on how to get the error.
Forum: General 10-15-2019, 04:52 PM
Replies: 7
Views: 1,272
Posted By Pat Hartman
Re: Application slow over VPN

Something made it pop to the top of the list. I have no idea what caused that. Maybe someone made a post but then deleted it. I certainly didn't go looking for it.
Forum: Queries 10-15-2019, 04:44 PM
Replies: 18
Views: 271
Posted By Pat Hartman
Re: Appending an auto-increment date to a Query

Problem statement is always the hardest part of the development job. By the time you really understand what needs to be done, implementation becomes almost trivial once you have a little experience.
Forum: Queries 10-15-2019, 02:57 PM
Replies: 8
Views: 94
Posted By Pat Hartman
Re: Using IIF in queries

It would be better to build the SQL on the fly in your form when the user chooses his option. Then use the SQL String as the result form's RecordSource.

I'm surprised that what you came up with...
Forum: Queries 10-15-2019, 02:53 PM
Replies: 12
Views: 127
Posted By Pat Hartman
Re: Update Query with percentage value

It's not clear what your schema is. Typically rates are kept by date. They have an effective date and an expiration date. The active date would have null as the expiration date. When a new date...
Forum: Queries 10-15-2019, 02:49 PM
Replies: 6
Views: 86
Posted By Pat Hartman
Re: Yearly odometer reading- subtract from last years

Why is the driver involved in this lookup? If you are trying to track the miles on the vehicle, the driver shouldn't be relevant. Also, the vehicle might not have been in service last year so...
Forum: Queries 10-15-2019, 02:38 PM
Replies: 18
Views: 271
Posted By Pat Hartman
Re: Appending an auto-increment date to a Query

OK, you want to create x days worth of records and you want to use each of the 11 teachers once? So if x is 2, then 22 records will be created. Should weekends and holidays be excluded? How do...
Showing results 1 to 25 of 500

 
Forum Jump



All times are GMT -8. The time now is 05:25 AM.


Microsoft Access Help
General
Tables
Queries
Forms
Reports
Macros
Modules & VBA
Theory & Practice
Access FAQs
Code Repository
Sample Databases
Video Tutorials

Featured Forum post


Sponsored Links


Powered by vBulletin®
Copyright ©2000 - 2019, Jelsoft Enterprises Ltd.
(c) copyright 2017 Access World