Welcome to SPN

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

Sign Up Now!

Super Easy Word Merge

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

  1. Nikki

    Nikki
    Expand Collapse
    Guest

    Hi,

    I have used the advice and examples from the website including data on
    "Super Easy Word Merge"
    http://www.members.shaw.ca/AlbertKallal/msaccess/msaccess.html

    Everything works fine except...

    The data I want to merge is in a subform. When I use the merge function it
    keeps trying to merge my main form even though I have the command button
    located on my subform.
    If I open the subform separately it works fine but when I want to do it all
    from the main form it doesn't work.

    Does anyone know if there is a section of the code that I need to change to
    point it to the correct table?
     
  2. Loading...


  3. Pieter Wijnen

    Pieter Wijnen
    Expand Collapse
    Guest

    haven't used it but..
    exchange

    Set frmF = Screen.ActiveForm
    for
    Set frmF = Screen.ActiveForm.[NameOfSubFormControl].Form
    in the code

    I'm sure dr Kallal will ammend the code for this eventuality <g>

    Pieter

    "Nikki" <Nikki@discussions.microsoft.com> wrote in message
    news:6F783DB2-D04E-48AA-94D9-46F16AFA71B3@microsoft.com...
    > Hi,
    >
    > I have used the advice and examples from the website including data on
    > "Super Easy Word Merge"
    > http://www.members.shaw.ca/AlbertKallal/msaccess/msaccess.html
    >
    > Everything works fine except...
    >
    > The data I want to merge is in a subform. When I use the merge function
    > it
    > keeps trying to merge my main form even though I have the command button
    > located on my subform.
    > If I open the subform separately it works fine but when I want to do it
    > all
    > from the main form it doesn't work.
    >
    > Does anyone know if there is a section of the code that I need to change
    > to
    > point it to the correct table?
     
  4. Pieter Wijnen

    Pieter Wijnen
    Expand Collapse
    Guest

    haven't used it but..
    exchange

    Set frmF = Screen.ActiveForm
    for
    Set frmF = Screen.ActiveForm.[NameOfSubFormControl].Form
    in the code

    I'm sure dr Kallal will ammend the code for this eventuality <g>

    Pieter

    "Nikki" <Nikki@discussions.microsoft.com> wrote in message
    news:6F783DB2-D04E-48AA-94D9-46F16AFA71B3@microsoft.com...
    > Hi,
    >
    > I have used the advice and examples from the website including data on
    > "Super Easy Word Merge"
    > http://www.members.shaw.ca/AlbertKallal/msaccess/msaccess.html
    >
    > Everything works fine except...
    >
    > The data I want to merge is in a subform. When I use the merge function
    > it
    > keeps trying to merge my main form even though I have the command button
    > located on my subform.
    > If I open the subform separately it works fine but when I want to do it
    > all
    > from the main form it doesn't work.
    >
    > Does anyone know if there is a section of the code that I need to change
    > to
    > point it to the correct table?




    --
    ----------------------------------------
    I am using the free version of SPAMfighter for private users.
    It has removed 4231 spam emails to date.
    Paying users do not have this message in their emails.
    Get the free SPAMfighter here: http://www.spamfighter.com/len
     
  5. Nikki

    Nikki
    Expand Collapse
    Guest

    Perfect!
    Thanks!

    "Pieter Wijnen" wrote:

    > haven't used it but..
    > exchange
    >
    > Set frmF = Screen.ActiveForm
    > for
    > Set frmF = Screen.ActiveForm.[NameOfSubFormControl].Form
    > in the code
    >
    > I'm sure dr Kallal will ammend the code for this eventuality <g>
    >
    > Pieter
    >
    > "Nikki" <Nikki@discussions.microsoft.com> wrote in message
    > news:6F783DB2-D04E-48AA-94D9-46F16AFA71B3@microsoft.com...
    > > Hi,
    > >
    > > I have used the advice and examples from the website including data on
    > > "Super Easy Word Merge"
    > > http://www.members.shaw.ca/AlbertKallal/msaccess/msaccess.html
    > >
    > > Everything works fine except...
    > >
    > > The data I want to merge is in a subform. When I use the merge function
    > > it
    > > keeps trying to merge my main form even though I have the command button
    > > located on my subform.
    > > If I open the subform separately it works fine but when I want to do it
    > > all
    > > from the main form it doesn't work.
    > >
    > > Does anyone know if there is a section of the code that I need to change
    > > to
    > > point it to the correct table?

    >
    >
    >
     
  6. Pieter Wijnen

    Pieter Wijnen
    Expand Collapse
    Guest

    de nada

    "Nikki" <Nikki@discussions.microsoft.com> wrote in message
    news:D2A3189C-7053-4950-A477-8D59FA166F13@microsoft.com...
    > Perfect!
    > Thanks!
    >
    > "Pieter Wijnen" wrote:
    >
    >> haven't used it but..
    >> exchange
    >>
    >> Set frmF = Screen.ActiveForm
    >> for
    >> Set frmF = Screen.ActiveForm.[NameOfSubFormControl].Form
    >> in the code
    >>
    >> I'm sure dr Kallal will ammend the code for this eventuality <g>
    >>
    >> Pieter
    >>
    >> "Nikki" <Nikki@discussions.microsoft.com> wrote in message
    >> news:6F783DB2-D04E-48AA-94D9-46F16AFA71B3@microsoft.com...
    >> > Hi,
    >> >
    >> > I have used the advice and examples from the website including data on
    >> > "Super Easy Word Merge"
    >> > http://www.members.shaw.ca/AlbertKallal/msaccess/msaccess.html
    >> >
    >> > Everything works fine except...
    >> >
    >> > The data I want to merge is in a subform. When I use the merge
    >> > function
    >> > it
    >> > keeps trying to merge my main form even though I have the command
    >> > button
    >> > located on my subform.
    >> > If I open the subform separately it works fine but when I want to do it
    >> > all
    >> > from the main form it doesn't work.
    >> >
    >> > Does anyone know if there is a section of the code that I need to
    >> > change
    >> > to
    >> > point it to the correct table?

    >>
    >>
    >>
     
  7. Pieter Wijnen

    Pieter Wijnen
    Expand Collapse
    Guest

    de nada

    "Nikki" <Nikki@discussions.microsoft.com> wrote in message
    news:D2A3189C-7053-4950-A477-8D59FA166F13@microsoft.com...
    > Perfect!
    > Thanks!
    >
    > "Pieter Wijnen" wrote:
    >
    >> haven't used it but..
    >> exchange
    >>
    >> Set frmF = Screen.ActiveForm
    >> for
    >> Set frmF = Screen.ActiveForm.[NameOfSubFormControl].Form
    >> in the code
    >>
    >> I'm sure dr Kallal will ammend the code for this eventuality <g>
    >>
    >> Pieter
    >>
    >> "Nikki" <Nikki@discussions.microsoft.com> wrote in message
    >> news:6F783DB2-D04E-48AA-94D9-46F16AFA71B3@microsoft.com...
    >> > Hi,
    >> >
    >> > I have used the advice and examples from the website including data on
    >> > "Super Easy Word Merge"
    >> > http://www.members.shaw.ca/AlbertKallal/msaccess/msaccess.html
    >> >
    >> > Everything works fine except...
    >> >
    >> > The data I want to merge is in a subform. When I use the merge
    >> > function
    >> > it
    >> > keeps trying to merge my main form even though I have the command
    >> > button
    >> > located on my subform.
    >> > If I open the subform separately it works fine but when I want to do it
    >> > all
    >> > from the main form it doesn't work.
    >> >
    >> > Does anyone know if there is a section of the code that I need to
    >> > change
    >> > to
    >> > point it to the correct table?

    >>
    >>
    >>




    --
    ----------------------------------------
    I am using the free version of SPAMfighter for private users.
    It has removed 4231 spam emails to date.
    Paying users do not have this message in their emails.
    Get the free SPAMfighter here: http://www.spamfighter.com/len
     
  8. Nikki

    Nikki
    Expand Collapse
    Guest

    Any chance you know how to delete a template after one has been added to the
    word template form?

    "Pieter Wijnen" wrote:

    > haven't used it but..
    > exchange
    >
    > Set frmF = Screen.ActiveForm
    > for
    > Set frmF = Screen.ActiveForm.[NameOfSubFormControl].Form
    > in the code
    >
    > I'm sure dr Kallal will ammend the code for this eventuality <g>
    >
    > Pieter
    >
    > "Nikki" <Nikki@discussions.microsoft.com> wrote in message
    > news:6F783DB2-D04E-48AA-94D9-46F16AFA71B3@microsoft.com...
    > > Hi,
    > >
    > > I have used the advice and examples from the website including data on
    > > "Super Easy Word Merge"
    > > http://www.members.shaw.ca/AlbertKallal/msaccess/msaccess.html
    > >
    > > Everything works fine except...
    > >
    > > The data I want to merge is in a subform. When I use the merge function
    > > it
    > > keeps trying to merge my main form even though I have the command button
    > > located on my subform.
    > > If I open the subform separately it works fine but when I want to do it
    > > all
    > > from the main form it doesn't work.
    > >
    > > Does anyone know if there is a section of the code that I need to change
    > > to
    > > point it to the correct table?

    >
    >
    >
     
  9. Pieter Wijnen

    Pieter Wijnen
    Expand Collapse
    Guest

    Nope
    Will if I look through the code though <g>

    Pieter

    "Nikki" <Nikki@discussions.microsoft.com> wrote in message
    news:0CF6F080-BE72-4712-B100-8AF3CEAD8766@microsoft.com...
    > Any chance you know how to delete a template after one has been added to
    > the
    > word template form?
    >
    > "Pieter Wijnen" wrote:
    >
    >> haven't used it but..
    >> exchange
    >>
    >> Set frmF = Screen.ActiveForm
    >> for
    >> Set frmF = Screen.ActiveForm.[NameOfSubFormControl].Form
    >> in the code
    >>
    >> I'm sure dr Kallal will ammend the code for this eventuality <g>
    >>
    >> Pieter
    >>
    >> "Nikki" <Nikki@discussions.microsoft.com> wrote in message
    >> news:6F783DB2-D04E-48AA-94D9-46F16AFA71B3@microsoft.com...
    >> > Hi,
    >> >
    >> > I have used the advice and examples from the website including data on
    >> > "Super Easy Word Merge"
    >> > http://www.members.shaw.ca/AlbertKallal/msaccess/msaccess.html
    >> >
    >> > Everything works fine except...
    >> >
    >> > The data I want to merge is in a subform. When I use the merge
    >> > function
    >> > it
    >> > keeps trying to merge my main form even though I have the command
    >> > button
    >> > located on my subform.
    >> > If I open the subform separately it works fine but when I want to do it
    >> > all
    >> > from the main form it doesn't work.
    >> >
    >> > Does anyone know if there is a section of the code that I need to
    >> > change
    >> > to
    >> > point it to the correct table?

    >>
    >>
    >>
     
  10. Pieter Wijnen

    Pieter Wijnen
    Expand Collapse
    Guest

    Nope
    Will if I look through the code though <g>

    Pieter

    "Nikki" <Nikki@discussions.microsoft.com> wrote in message
    news:0CF6F080-BE72-4712-B100-8AF3CEAD8766@microsoft.com...
    > Any chance you know how to delete a template after one has been added to
    > the
    > word template form?
    >
    > "Pieter Wijnen" wrote:
    >
    >> haven't used it but..
    >> exchange
    >>
    >> Set frmF = Screen.ActiveForm
    >> for
    >> Set frmF = Screen.ActiveForm.[NameOfSubFormControl].Form
    >> in the code
    >>
    >> I'm sure dr Kallal will ammend the code for this eventuality <g>
    >>
    >> Pieter
    >>
    >> "Nikki" <Nikki@discussions.microsoft.com> wrote in message
    >> news:6F783DB2-D04E-48AA-94D9-46F16AFA71B3@microsoft.com...
    >> > Hi,
    >> >
    >> > I have used the advice and examples from the website including data on
    >> > "Super Easy Word Merge"
    >> > http://www.members.shaw.ca/AlbertKallal/msaccess/msaccess.html
    >> >
    >> > Everything works fine except...
    >> >
    >> > The data I want to merge is in a subform. When I use the merge
    >> > function
    >> > it
    >> > keeps trying to merge my main form even though I have the command
    >> > button
    >> > located on my subform.
    >> > If I open the subform separately it works fine but when I want to do it
    >> > all
    >> > from the main form it doesn't work.
    >> >
    >> > Does anyone know if there is a section of the code that I need to
    >> > change
    >> > to
    >> > point it to the correct table?

    >>
    >>
    >>




    --
    ----------------------------------------
    I am using the free version of SPAMfighter for private users.
    It has removed 4231 spam emails to date.
    Paying users do not have this message in their emails.
    Get the free SPAMfighter here: http://www.spamfighter.com/len
     
  11. Albert D.Kallal

    Albert D.Kallal
    Expand Collapse
    Guest

    "Nikki" <Nikki@discussions.microsoft.com> wrote in message
    news:0CF6F080-BE72-4712-B100-8AF3CEAD8766@microsoft.com...
    > Any chance you know how to delete a template after one has been added to
    > the
    > word template form?


    This comes up once in a while.....

    Do you think users can handle a delete button? Would this cause them to
    accident delete temples that they need?

    (right now, to delete a template, you use the windows explore. Simply browse
    to the folder where the application is (your mdb, or mde file), and then
    look for a directory called word...you can then simply delete any template
    you want....

    So, what do you folks think....should I add a delete button?

    --
    Albert D. Kallal (Access MVP)
    Edmonton, Alberta Canada
    pleaseNOOSpamKallal@msn.com
    http://www.members.shaw.ca/AlbertKallal
     
  12. Albert D.Kallal

    Albert D.Kallal
    Expand Collapse
    Guest

    > The data I want to merge is in a subform. When I use the merge function
    > it
    > keeps trying to merge my main form even though I have the command button
    > located on my subform.
    > If I open the subform separately it works fine but when I want to do it
    > all
    > from the main form it doesn't work.
    >
    > Does anyone know if there is a section of the code that I need to change
    > to
    > point it to the correct table?


    Well, you REALLY don't wan tot change the code (you can, and I don't care if
    you do!!!).

    The reason why you don't want to change the code is then you can't use a
    another form or have a another location in your application that does a
    merge also, and in that case, you might not be using a sub-form. So....

    How is the sub-form being filtered? The best solution is to simply pass the
    merge routines the sql of your choice.

    dim strSql as string

    strSql = "select * from tblCustomers where city = 'Edmonton'"

    You can also use the name of a query. So, how did you set the data source of
    the sub-form?

    To merge using the above sql of your choice (or query)...just go

    MergeAllWord strSql

    That is all you need (just make sure the sql has the same records, or
    restriction that you have in the sub-form).

    That way you don't have to modify the library code. (and, maintain it
    either.....). If you use the merge code in 10 applications, and modify it
    10 times, then you create a considerable amount of maintains work, not to
    mention the difficulty of replacing code when I issue bug fixes....


    --
    Albert D. Kallal (Access MVP)
    Edmonton, Alberta Canada
    pleaseNOOSpamKallal@msn.com
    http://www.members.shaw.ca/AlbertKallal
     

Share This Page