Search results

  1. S

    Exporting tables to SQL server using VBA

    Very useful. You wouldn't happen to have a 64-bit version that works with "accdb" files?
  2. S

    FSO Files Collection Size Limitation?!?

    Thanks for the suggestion. It looks like it is merely a display issue in the watch window that it only shows 256 items.
  3. S

    FSO Files Collection Size Limitation?!?

    I seemed to have run up against a 256 file limitation in the FileSystemObject Files collection?!? Can anyone confirm this or point to a workaround that does not entail piping the output to a file and iterating through that? Dim objFSO As New FileSystemObject Dim objFolder As Folder...
  4. S

    How to tell RDBMS opened by ODBC connection?

    Haven't done it using Excel but looking at the MSDN web site it looks like you can pass in a null pointer if either the window handle is not applicable or SQLDriverConnect will not present any dialog boxes.
  5. S

    How to tell RDBMS opened by ODBC connection?

    Put the code below in a procedure or function. Dim strSQLInfo as String Dim strConnStrIn as String Dim strConnStrOut as String strSQLInfo = GetSQLInfo(SQL_DBMS_NAME, strConnStrIn, strConnStrOut) Either strSQLInfo will be Empty (if the referenced function was unable to get the information) or...
  6. S

    How to tell RDBMS opened by ODBC connection?

    I have a form defined in which I prompt the user to select an ODBC data source using code similar to the following: Dim wrkODBC As Workspace Dim conPubs As Connection ' Create ODBCDirect Workspace object. Set wrkODBC = CreateWorkspace("NewODBCWorkspace", "admin", "", dbUseODBC) Set conPubs =...
  7. S

    Duplicate / Copy / Clone Recordset (A2K)

    Finally found it... :D Me.Recordset.OpenRecordset
  8. S

    Duplicate / Copy / Clone Recordset (A2K)

    If your application's data model is truly normalized I would agree with you. However, for many reasons (which I don't think we want to debate here) other than the fact that MS-Access has problems supporting resursive relationships, that will not always the case. The function I created in the...
  9. S

    Duplicate / Copy / Clone Recordset (A2K)

    The sequence is as follows: 1) prompt user to delete record 2) on confirm, delete record and related records 3) depending on form where deletion is occuring, prompt user to delete other records 4) on confirm, delete other records What I am trying to do is keep the recordset field values for...
  10. S

    Duplicate / Copy / Clone Recordset (A2K)

    Tim, that is the same environment as I am running. Could you put your code in a small DB and upload it so I could see what differs between the two approaches? Pat, I have greatly oversimplified my problem in order to try and figure out a solution. Essentially when the user wants to delete a...
  11. S

    Duplicate / Copy / Clone Recordset (A2K)

    Tim, I tried your code but it still did not work. dcx693, I created a function that I put in a module (so I could call it from any form) based on what you described but I still get the same results (see below). Public Function copyRecordset(ByVal frm As Form) As dao.Recordset On Error GoTo...
  12. S

    Duplicate / Copy / Clone Recordset (A2K)

    That is the behaviour that is being exhibited. I am looking for a way to copy a recordset such that the cloned recordset and the original one are disjointed (I.e. changes made to either one are not reflected in the other)?
  13. S

    Duplicate / Copy / Clone Recordset (A2K)

    I still get an error when I reference the recordset once the underlying record is deleted from the table. What I am looking for is for the recordset to maintain no reference to the recordsource so I can use it's field values after the original record is deleted. I have attached a tiny example...
  14. S

    Duplicate / Copy / Clone Recordset (A2K)

    Can someone remind me how to create a copy of a form's current record (or recordset) without maintaining the reference to the underlying table? Basically I want to copy the current record before deleting it so I can reference some of the field values afterwards in order to perform other...
  15. S

    hide columns BUT not in a combo box

    The database was created using MS-Access 2000. What version are you running? So if the only link between the main and subform is TabOn, how do you when to hide columns in the subform? Are you going to have something like: select case TabOn Case "a" ' Hide column 1 Case "b" ' Hide...
  16. S

    hide columns BUT not in a combo box

    You are. As I said, Do you not have such a control in the main form? If you do then replace COMBO in the procedure name with the name of that control. If not, what changes in the main form that requires the hiding of a column in the subform? I am attaching a small sample DB to give you an...
  17. S

    hide columns BUT not in a combo box

    COMBO was the name of the control in the example I gave you. Did you replace it with the name of your control? If so, look at the control's properties and make sure that [Event Procedure] is listed beside the On Change property. If all of that seems OK then step through the code and try to see...
  18. S

    hide columns BUT not in a combo box

    Let's say you have a combobox called COMBO that when the user selects a different value it affects which records (and controls) are displayed in the subform. From what you said I don't know how you are doing it but the approach should be the same. So in the controls's Change event you hide the...
  19. S

    Cascading Combo problem

    I have run into similar problems in the past. The only way I know of getting around it is to manually (ie through VBA code) set each control's recordsource as it's related parent is changed. For Example: Private Sub CONTROL1_AfterUpdate() CONTROL2.RecordSource = "..." & _...
  20. S

    hide columns BUT not in a combo box

    Use the ColumnHidden form property. For example: Me.MySubform.Form.ColumnName.ColumnHidden = True Obviously this requires you to know which columns need to be hidden based on what is selected in the main form. Once you know that though you can control your subforms as needed.
Back
Top Bottom