If I have a client server setup, and would like to know who is logged on to the client end machine, by using vba. I'm running in a purely Windows NT 4.0 environment. Any code examples would be brilliant.
I have incountered a similiar problem, where a dll I was referencing was working fine, and then suddenly stopped.
The solution I found was to create a brand new database and import all the tables, queries, forms... etc.
I hope this helps.
If I'm understanding the problem correctly - you need to write some code to requery each of the controls on the mian form, on the close event of the smaller form. Once the smaller form closes the record will have been saved and your problem should be resolved.
Not the nicest way to do it, yet why don't you use the Startup Options to open the form. And then write a little bit of code on the Open_Form event of that form, which closes the form if the record in the database exists.
I think that if you down load the active x demonstration, you'll be going in the right direction. http://support.microsoft.com/support/kb/articles/Q165/4/37.ASP
Hope this helps.
Cheers,
Former
[This message has been edited by Former (edited 11-03-2000).]
How about putting another If statement around the whole thing. The if asks to see whether there is anything in the COMMENTS Box.
Private Sub COMMENTS_GotFocus()
If IsNull(Me!COMMENTS) Then
If Me!Material = "other" Then
Me!COMMENTS = Me!WA_FINDTYPE
Else
.....
Endif
Else
EndIf
End Sub
I'm not quite sure exactly what you are try to do here, but if you have the filename held as a string, you could splice it up using the Right, Left and Mid commands and then put it back together again to get the desired result.
If you can give uys a bit move information I'm sure someone will be...
Hi,
On the Close event of your pop up, you need to requery the combo.
A bit of code like this should do the trick
Private Sub Form_Close()
Forms("Form_Name").[Combo_Name].Requery
End Sub
I hope this helps
You shouldn't have any problem with your formula, if it's place in the right place on the report.
In which footer do you currently have the formula? Is the field that you are trying to average stored as numeric value ?
You may need to create a grouping on the report, and place the formula in...
You will need to write some code... The code below sets all the text boxes to display the key value of the combo box.
It's very basic....
Private Sub cboCombo_AfterUpdate()
On Error GoTo Err_cboCombo_AfterUpdate
Me.txtTextBox1.Value = Me.cboCombo.Value
Me.txtTextBox2.Value =...
Call this code, passing in the name of the form that you want to check ...
' Checks to see if a specific form is currently loaded or not
' and returns TRUE if so, FALSE if not.
Public Function IsLoaded(strFormName As String) As Boolean
Dim frmForm
Dim blnSuccess As Boolean ' this becomes...
I think that you are trying to calculate all the information on the report itself. Instead do the calculations in a query.
E.g. have a field like
Acc_Dep:IIF(([Depreciation/Month] * [# Months] >=
[Purchase Price],[Purchase Price],
([Depreciation/Month * # Months]))
Then base the report on...
Not the nicest way I'm sure, but it works...
________________________________________
Private Sub Form_Open(Cancel As Integer)
Me.textBoxName.SetFocus
SendKeys "{F2}"
SendKeys "{END}"
End Sub
________________________________________
Hope this helps
If you use the code....
DoCmd.OutputTo objecttype[, objectname][, outputformat][, outputfile][, autostart][, templatefile]
You can choose between a few different formats, which might be more suitable, however it doesn't support a word format.