Welcome to SPN

Register and Join the most happening forum of Sikh community & intellectuals from around the world.

Sign Up Now!

Invalid Data Format

Discussion in 'Information Technology' started by tb, Jul 28, 2006.

  1. tb

    tb
    Expand Collapse
    Guest

    I noticed a "Module 1" module which does not open. Receiving the error
    Invalid Data Format. If I delete, will I delete any valid information
    pertaining to my database?
     
  2. Loading...

    Similar Threads Forum Date
    Sikh News Sikh rendered invalid in ’84 riots seeks justice (Gulf Times) Breaking News Mar 14, 2008
    Sikh News 23 years later, invalid Sikh seeks justice (Calcutta News) Breaking News Mar 13, 2008
    Sikh News 23 years later, invalid Sikh seeks justice (New Kerala) Breaking News Mar 13, 2008
    Sikh News 23 years later, invalid Sikh seeks justice (Hindustan Times) Breaking News Mar 13, 2008
    Datawind's Sunseet Singh Introduces Ubislate: Aimed at the Cost-Conscious World Sikh Personalities Jan 12, 2014

  3. Ofer Cohen

    Ofer Cohen
    Expand Collapse
    Guest

    If you don't know what you have in this module, or if you need it, then
    create a back up to the MDB, try compact and repair to the MDB, if that
    doesn't work and you still can't open the module, delete it and run the
    debugger to see if you get any errors, then run the mdb and see if any error
    accur.
    If no errors you don't need the module
    If you have errors, bring back the module from the back up you created

    --
    Good Luck
    BS"D


    "tb" wrote:

    > I noticed a "Module 1" module which does not open. Receiving the error
    > Invalid Data Format. If I delete, will I delete any valid information
    > pertaining to my database?
     
  4. strive4peace

    strive4peace
    Expand Collapse
    Guest

    all DATA in the database is stored in tables, so no data
    will get deleted if you delete a module -- only program code

    have you compiled your code?

    from the menu in a module:
    Debug, Compile


    Warm Regards,
    Crystal
    Microsoft Access MVP 2006

    *
    Have an awesome day ;)

    remote programming and training
    strive4peace2006 at yahoo.com

    *

    tb wrote:
    > I noticed a "Module 1" module which does not open. Receiving the error
    > Invalid Data Format. If I delete, will I delete any valid information
    > pertaining to my database?
     
  5. tb

    tb
    Expand Collapse
    Guest

    I've tried debug/compile, but receive an invalid data format error.

    Could the MS system files for index and forms be corrupt? I found that
    failing on the "acform" variable. I am also unable to import specific forms
    in a new database; once imported they disappear; and invalid data format when
    importing these specific forms.

    tb

    "strive4peace" <"strive4peace2006 at yaho" wrote:

    > all DATA in the database is stored in tables, so no data
    > will get deleted if you delete a module -- only program code
    >
    > have you compiled your code?
    >
    > from the menu in a module:
    > Debug, Compile
    >
    >
    > Warm Regards,
    > Crystal
    > Microsoft Access MVP 2006
    >
    > *
    > Have an awesome day ;)
    >
    > remote programming and training
    > strive4peace2006 at yahoo.com
    >
    > *
    >
    > tb wrote:
    > > I noticed a "Module 1" module which does not open. Receiving the error
    > > Invalid Data Format. If I delete, will I delete any valid information
    > > pertaining to my database?

    >
     
  6. strive4peace

    strive4peace
    Expand Collapse
    Guest

    "failing on the "acform" variable"

    what is the full statement? perhaps you need a library
    reference -- or maybe you are missing a comma.

    *** Check Library References ***

    from the menu in a module, choose Tools, References...

    ---> does anything say MISSING?

    *** Decompile ***

    if you still haven't resolved the problem, try decompiling
    the database

    make an icon with this as its target:

    "C:\Program Files\Microsoft Office\Office\MSACCESS.EXE"
    "C:\path\filename.mdb" /decompile

    if your Access program is not located in the directory
    specified, make the appropriate substitution

    after you decompile, compile it if you have any code and
    then do compact/repair


    Warm Regards,
    Crystal
    Microsoft Access MVP 2006

    *
    Have an awesome day ;)

    remote programming and training
    strive4peace2006 at yahoo.com

    *

    tb wrote:
    > I've tried debug/compile, but receive an invalid data format error.
    >
    > Could the MS system files for index and forms be corrupt? I found that
    > failing on the "acform" variable. I am also unable to import specific forms
    > in a new database; once imported they disappear; and invalid data format when
    > importing these specific forms.
    >
    > tb
    >
    > "strive4peace" <"strive4peace2006 at yaho" wrote:
    >
    >
    >>all DATA in the database is stored in tables, so no data
    >>will get deleted if you delete a module -- only program code
    >>
    >>have you compiled your code?
    >>
    >>from the menu in a module:
    >>Debug, Compile
    >>
    >>
    >>Warm Regards,
    >>Crystal
    >>Microsoft Access MVP 2006
    >>
    >> *
    >> Have an awesome day ;)
    >>
    >> remote programming and training
    >> strive4peace2006 at yahoo.com
    >>
    >> *
    >>
    >>tb wrote:
    >>
    >>>I noticed a "Module 1" module which does not open. Receiving the error
    >>>Invalid Data Format. If I delete, will I delete any valid information
    >>>pertaining to my database?

    >>
     
  7. tb

    tb
    Expand Collapse
    Guest

    Nothing was MISSING in the library references. The following was checked:

    - Visual Basic for Applications
    - MS Access 11.0 Object Library
    - OLE Automation
    - MS VBA Extensibility 5.3

    The full statement is:

    Private Sub Command2_Click()
    On Error GoTo Err_Command2_Click

    basOpenWhatForm True, "frm_CO's_Amendments", Me![Combo0], False, False,
    "NotEditable"
    DoCmd.Close acForm, "fmnu_View_CO_By_Project"

    Exit_Command2_Click:
    Exit Sub

    Err_Command2_Click:
    MsgBox Err.Description
    Resume Exit_Command2_Click

    End Sub

    Regards, tb

    "strive4peace" <"strive4peace2006 at yaho" wrote:

    > "failing on the "acform" variable"
    >
    > what is the full statement? perhaps you need a library
    > reference -- or maybe you are missing a comma.
    >
    > *** Check Library References ***
    >
    > from the menu in a module, choose Tools, References...
    >
    > ---> does anything say MISSING?
    >
    > *** Decompile ***
    >
    > if you still haven't resolved the problem, try decompiling
    > the database
    >
    > make an icon with this as its target:
    >
    > "C:\Program Files\Microsoft Office\Office\MSACCESS.EXE"
    > "C:\path\filename.mdb" /decompile
    >
    > if your Access program is not located in the directory
    > specified, make the appropriate substitution
    >
    > after you decompile, compile it if you have any code and
    > then do compact/repair
    >
    >
    > Warm Regards,
    > Crystal
    > Microsoft Access MVP 2006
    >
    > *
    > Have an awesome day ;)
    >
    > remote programming and training
    > strive4peace2006 at yahoo.com
    >
    > *
    >
    > tb wrote:
    > > I've tried debug/compile, but receive an invalid data format error.
    > >
    > > Could the MS system files for index and forms be corrupt? I found that
    > > failing on the "acform" variable. I am also unable to import specific forms
    > > in a new database; once imported they disappear; and invalid data format when
    > > importing these specific forms.
    > >
    > > tb
    > >
    > > "strive4peace" <"strive4peace2006 at yaho" wrote:
    > >
    > >
    > >>all DATA in the database is stored in tables, so no data
    > >>will get deleted if you delete a module -- only program code
    > >>
    > >>have you compiled your code?
    > >>
    > >>from the menu in a module:
    > >>Debug, Compile
    > >>
    > >>
    > >>Warm Regards,
    > >>Crystal
    > >>Microsoft Access MVP 2006
    > >>
    > >> *
    > >> Have an awesome day ;)
    > >>
    > >> remote programming and training
    > >> strive4peace2006 at yahoo.com
    > >>
    > >> *
    > >>
    > >>tb wrote:
    > >>
    > >>>I noticed a "Module 1" module which does not open. Receiving the error
    > >>>Invalid Data Format. If I delete, will I delete any valid information
    > >>>pertaining to my database?
    > >>

    >
     
  8. strive4peace

    strive4peace
    Expand Collapse
    Guest

    what is the code for basOpenWhatForm ?

    Warm Regards,
    Crystal
    Microsoft Access MVP 2006

    *
    Have an awesome day ;)

    remote programming and training
    strive4peace2006 at yahoo.com

    *

    tb wrote:
    > Nothing was MISSING in the library references. The following was checked:
    >
    > - Visual Basic for Applications
    > - MS Access 11.0 Object Library
    > - OLE Automation
    > - MS VBA Extensibility 5.3
    >
    > The full statement is:
    >
    > Private Sub Command2_Click()
    > On Error GoTo Err_Command2_Click
    >
    > basOpenWhatForm True, "frm_CO's_Amendments", Me![Combo0], False, False,
    > "NotEditable"
    > DoCmd.Close acForm, "fmnu_View_CO_By_Project"
    >
    > Exit_Command2_Click:
    > Exit Sub
    >
    > Err_Command2_Click:
    > MsgBox Err.Description
    > Resume Exit_Command2_Click
    >
    > End Sub
    >
    > Regards, tb
    >
    > "strive4peace" <"strive4peace2006 at yaho" wrote:
    >
    >
    >>"failing on the "acform" variable"
    >>
    >>what is the full statement? perhaps you need a library
    >>reference -- or maybe you are missing a comma.
    >>
    >>*** Check Library References ***
    >>
    >>from the menu in a module, choose Tools, References...
    >>
    >>---> does anything say MISSING?
    >>
    >>*** Decompile ***
    >>
    >>if you still haven't resolved the problem, try decompiling
    >>the database
    >>
    >>make an icon with this as its target:
    >>
    >>"C:\Program Files\Microsoft Office\Office\MSACCESS.EXE"
    >>"C:\path\filename.mdb" /decompile
    >>
    >>if your Access program is not located in the directory
    >>specified, make the appropriate substitution
    >>
    >>after you decompile, compile it if you have any code and
    >>then do compact/repair
    >>
    >>
    >>Warm Regards,
    >>Crystal
    >>Microsoft Access MVP 2006
    >>
    >> *
    >> Have an awesome day ;)
    >>
    >> remote programming and training
    >> strive4peace2006 at yahoo.com
    >>
    >> *
    >>
    >>tb wrote:
    >>
    >>>I've tried debug/compile, but receive an invalid data format error.
    >>>
    >>>Could the MS system files for index and forms be corrupt? I found that
    >>>failing on the "acform" variable. I am also unable to import specific forms
    >>>in a new database; once imported they disappear; and invalid data format when
    >>>importing these specific forms.
    >>>
    >>>tb
    >>>
    >>>"strive4peace" <"strive4peace2006 at yaho" wrote:
    >>>
    >>>
    >>>
    >>>>all DATA in the database is stored in tables, so no data
    >>>>will get deleted if you delete a module -- only program code
    >>>>
    >>>>have you compiled your code?
    >>>>
    >>>
    >>>>from the menu in a module:
    >>>
    >>>>Debug, Compile
    >>>>
    >>>>
    >>>>Warm Regards,
    >>>>Crystal
    >>>>Microsoft Access MVP 2006
    >>>>
    >>>> *
    >>>> Have an awesome day ;)
    >>>>
    >>>> remote programming and training
    >>>> strive4peace2006 at yahoo.com
    >>>>
    >>>> *
    >>>>
    >>>>tb wrote:
    >>>>
    >>>>
    >>>>>I noticed a "Module 1" module which does not open. Receiving the error
    >>>>>Invalid Data Format. If I delete, will I delete any valid information
    >>>>>pertaining to my database?
    >>>>
     
  9. tb

    tb
    Expand Collapse
    Guest

    Sub basOpenWhatForm(Requery, stDocName, WhatProject, WhatAgt_Type,
    WhatStatus, Optional WhatOpenArgs = Null)
    On Error GoTo Err_basOpenWhatForm

    Dim stLinkCriteria As String
    Dim strOpenArgs As String 'used with change tracking

    If Not Requery Then
    Dim intProject As Integer

    'we're requerying before opening the detail form to prevent write
    conflict. A better method can be done in rev 2.

    With Screen.ActiveForm
    intProject = .CurrentRecord
    .Requery
    DoCmd.GoToRecord , , acGoTo, intProject
    End With
    End If

    stLinkCriteria = "[Project]=" & "'" & WhatProject & "'"

    DoCmd.OpenForm stDocName, acNormal, , stLinkCriteria, , , WhatOpenArgs

    'Can be deleted after testing
    'If WhatStatus Then
    ' 'concatenate multiple values for passing to change tracking
    ' strOpenArgs = WhatProject & ":1:" & WhatAgt_Type & ":2:" &
    stDocName & ":3:" & stLinkCriteria & ":4:" & WhatOpenArgs & ":5:"
    ' 'display change tracking comment form
    ' DoCmd.OpenForm "frm_Change_Tracking", acNormal, , , acFormAdd,
    acDialog, strOpenArgs
    'End If

    Exit_basOpenWhatForm:
    Exit Sub

    Err_basOpenWhatForm:
    MsgBox Err.Description
    Resume Exit_basOpenWhatForm

    End Sub

    "strive4peace" <"strive4peace2006 at yaho" wrote:

    > what is the code for basOpenWhatForm ?
    >
    > Warm Regards,
    > Crystal
    > Microsoft Access MVP 2006
    >
    > *
    > Have an awesome day ;)
    >
    > remote programming and training
    > strive4peace2006 at yahoo.com
    >
    > *
    >
    > tb wrote:
    > > Nothing was MISSING in the library references. The following was checked:
    > >
    > > - Visual Basic for Applications
    > > - MS Access 11.0 Object Library
    > > - OLE Automation
    > > - MS VBA Extensibility 5.3
    > >
    > > The full statement is:
    > >
    > > Private Sub Command2_Click()
    > > On Error GoTo Err_Command2_Click
    > >
    > > basOpenWhatForm True, "frm_CO's_Amendments", Me![Combo0], False, False,
    > > "NotEditable"
    > > DoCmd.Close acForm, "fmnu_View_CO_By_Project"
    > >
    > > Exit_Command2_Click:
    > > Exit Sub
    > >
    > > Err_Command2_Click:
    > > MsgBox Err.Description
    > > Resume Exit_Command2_Click
    > >
    > > End Sub
    > >
    > > Regards, tb
    > >
    > > "strive4peace" <"strive4peace2006 at yaho" wrote:
    > >
    > >
    > >>"failing on the "acform" variable"
    > >>
    > >>what is the full statement? perhaps you need a library
    > >>reference -- or maybe you are missing a comma.
    > >>
    > >>*** Check Library References ***
    > >>
    > >>from the menu in a module, choose Tools, References...
    > >>
    > >>---> does anything say MISSING?
    > >>
    > >>*** Decompile ***
    > >>
    > >>if you still haven't resolved the problem, try decompiling
    > >>the database
    > >>
    > >>make an icon with this as its target:
    > >>
    > >>"C:\Program Files\Microsoft Office\Office\MSACCESS.EXE"
    > >>"C:\path\filename.mdb" /decompile
    > >>
    > >>if your Access program is not located in the directory
    > >>specified, make the appropriate substitution
    > >>
    > >>after you decompile, compile it if you have any code and
    > >>then do compact/repair
    > >>
    > >>
    > >>Warm Regards,
    > >>Crystal
    > >>Microsoft Access MVP 2006
    > >>
    > >> *
    > >> Have an awesome day ;)
    > >>
    > >> remote programming and training
    > >> strive4peace2006 at yahoo.com
    > >>
    > >> *
    > >>
    > >>tb wrote:
    > >>
    > >>>I've tried debug/compile, but receive an invalid data format error.
    > >>>
    > >>>Could the MS system files for index and forms be corrupt? I found that
    > >>>failing on the "acform" variable. I am also unable to import specific forms
    > >>>in a new database; once imported they disappear; and invalid data format when
    > >>>importing these specific forms.
    > >>>
    > >>>tb
    > >>>
    > >>>"strive4peace" <"strive4peace2006 at yaho" wrote:
    > >>>
    > >>>
    > >>>
    > >>>>all DATA in the database is stored in tables, so no data
    > >>>>will get deleted if you delete a module -- only program code
    > >>>>
    > >>>>have you compiled your code?
    > >>>>
    > >>>
    > >>>>from the menu in a module:
    > >>>
    > >>>>Debug, Compile
    > >>>>
    > >>>>
    > >>>>Warm Regards,
    > >>>>Crystal
    > >>>>Microsoft Access MVP 2006
    > >>>>
    > >>>> *
    > >>>> Have an awesome day ;)
    > >>>>
    > >>>> remote programming and training
    > >>>> strive4peace2006 at yahoo.com
    > >>>>
    > >>>> *
    > >>>>
    > >>>>tb wrote:
    > >>>>
    > >>>>
    > >>>>>I noticed a "Module 1" module which does not open. Receiving the error
    > >>>>>Invalid Data Format. If I delete, will I delete any valid information
    > >>>>>pertaining to my database?
    > >>>>

    >
     
  10. strive4peace

    strive4peace
    Expand Collapse
    Guest

    change the name of your parameter called Requery to
    something else because Requery is a reserved word and using
    it as a variable name could be causing problems

    it is also a good ideat to specify type for each parameter
    just as you do when you dimension variables

    ie:
    booRequery as boolean, stDocName as string, etc

    instead of assigning WhatOpenArgs in the sub declaration,
    make it a string and pass an empty string or if you want to
    keep it optional and don't feel like testing it, use this in
    your code:

    nz(WhatOpenArgs,"")

    before your requery your activeform, you should save it if
    it is dirty

    if Screen.ActiveForm.dirty then
    Screen.ActiveForm.dirty = false
    end if

    this line may not act where you think it does

    DoCmd.GoToRecord , , acGoTo, intProject

    it would be better to use the Bookmark property to find the
    record again

    here is some code you can alter:

    '~~~~~~~~~~~~~
    Private Function FindRecord()

    If IsNull(Me.ActiveControl) Then Exit Function

    'save current record if changes were made
    If me.dirty then me.dirty = false

    Dim mRecordID As Long
    mRecordID = Me.ActiveControl
    Me.ActiveControl = Null
    Me.RecordsetClone.FindFirst "IDfield = " & mRecordID

    If Not Me.RecordsetClone.NoMatch Then
    Me.Bookmark = Me.RecordsetClone.Bookmark
    Exit Function
    End If

    End Function
    '~~~~~~~~~~~~~~~~~

    when you send Me![Combo0] for WhatProject, you really should
    check to 1. make sure it is filled out and 2. you are on a
    current record. Optionally, you could try sending
    nz(WhatProject,"")

    Warm Regards,
    Crystal
    Microsoft Access MVP 2006

    *
    Have an awesome day ;)

    remote programming and training
    strive4peace2006 at yahoo.com

    *

    tb wrote:
    > Sub basOpenWhatForm(Requery, stDocName, WhatProject, WhatAgt_Type,
    > WhatStatus, Optional WhatOpenArgs = Null)
    > On Error GoTo Err_basOpenWhatForm
    >
    > Dim stLinkCriteria As String
    > Dim strOpenArgs As String 'used with change tracking
    >
    > If Not Requery Then
    > Dim intProject As Integer
    >
    > 'we're requerying before opening the detail form to prevent write
    > conflict. A better method can be done in rev 2.
    >
    > With Screen.ActiveForm
    > intProject = .CurrentRecord
    > .Requery
    > DoCmd.GoToRecord , , acGoTo, intProject
    > End With
    > End If
    >
    > stLinkCriteria = "[Project]=" & "'" & WhatProject & "'"
    >
    > DoCmd.OpenForm stDocName, acNormal, , stLinkCriteria, , , WhatOpenArgs
    >
    > 'Can be deleted after testing
    > 'If WhatStatus Then
    > ' 'concatenate multiple values for passing to change tracking
    > ' strOpenArgs = WhatProject & ":1:" & WhatAgt_Type & ":2:" &
    > stDocName & ":3:" & stLinkCriteria & ":4:" & WhatOpenArgs & ":5:"
    > ' 'display change tracking comment form
    > ' DoCmd.OpenForm "frm_Change_Tracking", acNormal, , , acFormAdd,
    > acDialog, strOpenArgs
    > 'End If
    >
    > Exit_basOpenWhatForm:
    > Exit Sub
    >
    > Err_basOpenWhatForm:
    > MsgBox Err.Description
    > Resume Exit_basOpenWhatForm
    >
    > End Sub
    >
    > "strive4peace" <"strive4peace2006 at yaho" wrote:
    >
    >
    >>what is the code for basOpenWhatForm ?
    >>
    >>Warm Regards,
    >>Crystal
    >>Microsoft Access MVP 2006
    >>
    >> *
    >> Have an awesome day ;)
    >>
    >> remote programming and training
    >> strive4peace2006 at yahoo.com
    >>
    >> *
    >>
    >>tb wrote:
    >>
    >>>Nothing was MISSING in the library references. The following was checked:
    >>>
    >>>- Visual Basic for Applications
    >>>- MS Access 11.0 Object Library
    >>>- OLE Automation
    >>>- MS VBA Extensibility 5.3
    >>>
    >>>The full statement is:
    >>>
    >>>Private Sub Command2_Click()
    >>>On Error GoTo Err_Command2_Click
    >>>
    >>> basOpenWhatForm True, "frm_CO's_Amendments", Me![Combo0], False, False,
    >>>"NotEditable"
    >>> DoCmd.Close acForm, "fmnu_View_CO_By_Project"
    >>>
    >>>Exit_Command2_Click:
    >>> Exit Sub
    >>>
    >>>Err_Command2_Click:
    >>> MsgBox Err.Description
    >>> Resume Exit_Command2_Click
    >>>
    >>>End Sub
    >>>
    >>>Regards, tb
    >>>
    >>>"strive4peace" <"strive4peace2006 at yaho" wrote:
    >>>
    >>>
    >>>
    >>>>"failing on the "acform" variable"
    >>>>
    >>>>what is the full statement? perhaps you need a library
    >>>>reference -- or maybe you are missing a comma.
    >>>>
    >>>>*** Check Library References ***
    >>>>
    >>>
    >>>>from the menu in a module, choose Tools, References...
    >>>
    >>>>---> does anything say MISSING?
    >>>>
    >>>>*** Decompile ***
    >>>>
    >>>>if you still haven't resolved the problem, try decompiling
    >>>>the database
    >>>>
    >>>>make an icon with this as its target:
    >>>>
    >>>>"C:\Program Files\Microsoft Office\Office\MSACCESS.EXE"
    >>>>"C:\path\filename.mdb" /decompile
    >>>>
    >>>>if your Access program is not located in the directory
    >>>>specified, make the appropriate substitution
    >>>>
    >>>>after you decompile, compile it if you have any code and
    >>>>then do compact/repair
    >>>>
    >>>>
    >>>>Warm Regards,
    >>>>Crystal
    >>>>Microsoft Access MVP 2006
    >>>>
    >>>> *
    >>>> Have an awesome day ;)
    >>>>
    >>>> remote programming and training
    >>>> strive4peace2006 at yahoo.com
    >>>>
    >>>> *
    >>>>
    >>>>tb wrote:
    >>>>
    >>>>
    >>>>>I've tried debug/compile, but receive an invalid data format error.
    >>>>>
    >>>>>Could the MS system files for index and forms be corrupt? I found that
    >>>>>failing on the "acform" variable. I am also unable to import specific forms
    >>>>>in a new database; once imported they disappear; and invalid data format when
    >>>>>importing these specific forms.
    >>>>>
    >>>>>tb
    >>>>>
    >>>>>"strive4peace" <"strive4peace2006 at yaho" wrote:
    >>>>>
    >>>>>
    >>>>>
    >>>>>
    >>>>>>all DATA in the database is stored in tables, so no data
    >>>>>>will get deleted if you delete a module -- only program code
    >>>>>>
    >>>>>>have you compiled your code?
    >>>>>>
    >>>>>
    >>>>>>from the menu in a module:
    >>>>>
    >>>>>
    >>>>>>Debug, Compile
    >>>>>>
    >>>>>>
    >>>>>>Warm Regards,
    >>>>>>Crystal
    >>>>>>Microsoft Access MVP 2006
    >>>>>>
    >>>>>>*
    >>>>>> Have an awesome day ;)
    >>>>>>
    >>>>>> remote programming and training
    >>>>>> strive4peace2006 at yahoo.com
    >>>>>>
    >>>>>>*
    >>>>>>
    >>>>>>tb wrote:
    >>>>>>
    >>>>>>
    >>>>>>
    >>>>>>>I noticed a "Module 1" module which does not open. Receiving the error
    >>>>>>>Invalid Data Format. If I delete, will I delete any valid information
    >>>>>>>pertaining to my database?
    >>>>>>
     

Share This Page