I need to base a variable array using a variable. For example,
ReDim pstrDepSSN(pint RecordCount) as string
The only way to do this is with the ReDim statement but it doesn't permit me to declare the variables as Static so that they hold their values. And if I declare the variables as Static like this
Static pstrDepSSN(pint RecordCount) as string
then I'm not using ReDim so it requires a constant...
User Profile
Collapse
-
Dynamic Variable Array Issue
-
Emailing Reports
I'm using the following code in an attempt to email reports from a database form in Access.
[Code=vb]
With EMsg
Set .Configuration = EConf
.To = Recip (variable)
.CC = "Susan.Miller@o cfl.net"
.From = "Susan.Miller@o cfl.net"
.Subject = "Please read: Test CDO message with Attached Reports"
.HTMLBody = strHTML
.addattachment (stDocName)
.send
End With... -
Solved my own problem. At least so far. The only way to allow a main save and cancel function with subforms that use different recordsources is to programatically define the recordset based on query. Circle thru the recordset when you press Edit and use ReDim to define dynamic variable array and store the "old values" in variables. Then if user presses cancel, you can circle thru the recordset and reassign those old values. Its alot of... -
-
Yeah. I would much rather be using something like VB unfortunately it is not an option at work. The idea was to make changes to any of their information and save one time but I cannot do from one recordsource because of the one to many relationships. There everything from Retirement info, to benefit info, dependants info carried on coverage, Disability, etc. No way to use 1 recordsource and requires me to make chgs in like 10 diff forms.
...Leave a comment:
-
How to stop subforms from autosaving upon losing focus?
I have a Main form with several tabs. Each tab contains subforms that hold various employee information regarding benefits, dependant coverage, retirement, etc. I have a Save and cancel function on the form. I wish to edit information on these tabs regarding employee information and wait until save is clicked to save all information. If the user selects cancel I'd like it to cancel all changes made to all subform and form fields. However the subforms... -
Unfortunately, I am having the same problem and when I set Cancel = True in the subforms before update event, it will not allow the subform to lose focus until that data is saved. I have a form with several tabs. Each tab contains different information regarding the employee. I need to be able to edit the information without it saving until a master save button on the main form is clicked. It is horribly redundant to perform edit and save functions...Leave a comment:
No activity results to display
Show More
Leave a comment: