Solved

Real time form.

Posted on 2011-03-24
2
308 Views
Last Modified: 2012-05-11
I have a form that looks something like this:
Start Time  Stop Time      Status Code      Incident      Incident Title
12:00           1:00                             E                         34          Standby

I need to have that form automatically go to the next line and start another line with the same format. I couldnt draw the lines,  but it should be a table format. So when they tab at the end it will start another row automatically with date/time format and all the other columns.
0
Comment
Question by:gigifarrow
2 Comments
 
LVL 84

Accepted Solution

by:
Scott McDaniel (Microsoft Access MVP - EE MVE ) earned 500 total points
ID: 35209053
Generally you do this by capturing the values in module-level variables. For example, in the General Declarations section of your FORM, add these variables:

Private mdStartTime As Date
Private mdStopTime As Date
Private msStatusCode As String
etc etc

Now capture the values in the Form's BeforeUpdate event:

Sub Form_BeforeUpdate(Cancel As Integer)
  mdStartTime = Me.[Start Time]
  msStatusCode = me.[Status Code]
End Sub

Now, in the Current event ofy our form, check for a NewRecord and if found, add those values;

Sub Form_Current()
  If Me.NewRecord Then
    Me.[Status Code]= msStatusCode
    Me.[Start Time] = mdStartTime
  End If
End Sub

Obviously you'd have to change the names of your controls and such based on your project, and you'd have to add the other variables to handle all the items you need.
0
 

Author Closing Comment

by:gigifarrow
ID: 35212354
the information wasnt that clear
0

Featured Post

Microsoft Certification Exam 74-409

Veeam® is happy to provide the Microsoft community with a study guide prepared by MVP and MCT, Orin Thomas. This guide will take you through each of the exam objectives, helping you to prepare for and pass the examination.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Shadow IT is coming out of the shadows as more businesses are choosing cloud-based applications. It is now a multi-cloud world for most organizations. Simultaneously, most businesses have yet to consolidate with one cloud provider or define an offic…
Never store passwords in plain text or just their hash: it seems a no-brainier, but there are still plenty of people doing that. I present the why and how on this subject, offering my own real life solution that you can implement right away, bringin…
Familiarize people with the process of utilizing SQL Server views from within Microsoft Access. Microsoft Access is a very powerful client/server development tool. One of the SQL Server objects that you can interact with from within Microsoft Access…
Familiarize people with the process of retrieving data from SQL Server using an Access pass-thru query. Microsoft Access is a very powerful client/server development tool. One of the ways that you can retrieve data from a SQL Server is by using a pa…

910 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

21 Experts available now in Live!

Get 1:1 Help Now