[Show all top banners]

Ashutosh Shrivastav

More by Ashutosh Shrivastav
What people are reading
Subscribers
:: Subscribe
Back to: Kurakani General Refresh page to view new replies
 IT Help -- Urgent
[VIEWED 2970 TIMES]
SAVE! for ease of future access.
Posted on 03-29-07 12:06 AM     Reply [Subscribe]
Login in to Rate this Post:     0       ?    
 

Hey Guys:

One of my friends needs some help in solving some IT problems listed below. Your response will greatly be appreciated.

_____________________________________________________________________
Directions: Type answers to test – all typing should come up in red font. If it does not, change any new text that you enter to red font. Save the file with your name in place of the word “Template” in the file name.


QUESTION #1:
You have a form open in the Design View and the form contains a Combo Box named APET. How would you create a Sub – Routine that would execute miscellaneous code after a user has selected one of the options in the Combo Box?











QUESTION #2:
Below is a section of code that updates one of the tables in our database after a user has made some changes to the information displayed on the form. A problem occurs since there is not always an existing record in the “T ANTS – Revision Dates” table and an error will occur when this code executes. Project number is the Primary Key for the table and CurrentUser.Filter returns a string that stores the Project Number that the user was currently viewing in the form. Insert code that will handle the situation where a record does not exist in the table.

If (ReadOnly) Then
DoCmd.Close
Else
[Project Number].Value = CurrentUser.Filter

Dim dbs As Database
Dim rst As Recordset

Set dbs = CurrentDb()

' #12242001MV
' The user has made an update so update the Revision Dates table.
Set rst = dbs.OpenRecordset("SELECT * FROM [T ANTS - Revision Dates] WHERE
[Project Number] = '" & CurrentUser.Filter & "';")

rst.Edit
rst![Revision Date] = Now()
rst![Logon ID] = CurrentUser.ID
rst.Update
rst.Close
dbs.Close

' #12232001MV
' Handle click to return to Main Menu.
DoCmd.Close
End If





QUESTION #3:
Below is a section of code that executes once the user has clicked on a Check Box in the form named “Identify Complete”. Once this check box has been clicked on the “Analyze” and “Analyze Complete” fields that were originally disabled need to be enabled and the “Identify Complete” check box needs to be disabled so the user may not click on it again. Insert code that will disable and enable the appropriate fields.


Private Sub Identify_Complete_Click()
On Error GoTo ErrCatch

'10182002 BW
'Once the Identify step of the Corrective Action has been marked complete
'make the next field and check box in the Corrective Action process available

'04102003 BW
'Disable the Identify fields once the step has been marked as complete

Exit_Routine:
Exit Sub

ErrCatch:
Call Error_Catch(Err.Number, Err.Description)
Resume Exit_Routine

End Sub







QUESTION #4:
Below is code that executes when a user clicks the next button on one of the forms. The intention is for the current form to close and for the “ANTS – Contact Information” form to open when the user clicks on this button. Insert code that will handle this process.


Private Sub Next_Click()
On Error GoTo Err_Next_Click
' #04232002MV
' Added functionality for users to click the Next button to progress through the various
'SORM data input forms in a linear way.

If (Not ReadOnly) Then
[Project Number].Value = CurrentUser.Filter
End If

Exit_Next_Click:
Exit Sub

Err_Next_Click:
Call Error_Catch(Err.Number, Err.Description)
Resume Exit_Next_Click

End Sub
 


Please Log in! to be able to reply! If you don't have a login, please register here.

YOU CAN ALSO



IN ORDER TO POST!




Within last 365 days
Recommended Popular Threads Controvertial Threads
Lets play Antakshari...........
शीर्षक जे पनि हुन सक्छ।
NRN card pros and cons?
What are your first memories of when Nepal Television Began?
TPS Re-registration
TPS Re-registration case still pending ..
Democrats are so sure Trump will win
is Rato Bangala school cheating?
What Happened to Dual Citizenship Bill
Basnet or Basnyat ??
nrn citizenship
H1B fraud
इन्दिरा जोशीको चिन्ता लौच
Sajha has turned into MAGATs nest
Nas and The Bokas: Coming to a Night Club near you
श्राद्द
सेक्सी कविता - पार्ट २
डलराँ कमाएर ने .रु मा उडांउदा !@#
ChatSansar.com Naya Nepal Chat
Why always Miss Nepal winner is Newari??
Nas and The Bokas: Coming to a Night Club near you
राजदरबार हत्या काण्ड बारे....
Mr. Dipak Gyawali-ji Talk is Cheap. US sends $ 200 million to Nepal every year.
Harvard Nepali Students Association Blame Israel for hamas terrorist attacks
TPS Update : Jajarkot earthquake
is Rato Bangala school cheating?
NOTE: The opinions here represent the opinions of the individual posters, and not of Sajha.com. It is not possible for sajha.com to monitor all the postings, since sajha.com merely seeks to provide a cyber location for discussing ideas and concerns related to Nepal and the Nepalis. Please send an email to admin@sajha.com using a valid email address if you want any posting to be considered for deletion. Your request will be handled on a one to one basis. Sajha.com is a service please don't abuse it. - Thanks.

Sajha.com Privacy Policy

Like us in Facebook!

↑ Back to Top
free counters