?
Solved

How to Save a Memo box to Queried records

Posted on 2015-01-13
9
Medium Priority
?
130 Views
Last Modified: 2015-01-14
Hello,

I have one memo box on my form for each change.  I need to save the memo comment to all my queried records.  How do I do that??
0
Comment
Question by:Jass Saini
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 5
  • 3
9 Comments
 

Author Comment

by:Jass Saini
ID: 40547179
Here is my code..It updates everything and I just need to to update the queried records...

Private Sub Remarks1_Click()
    Dim strMsg As String, strQry As String, strRemark As String
    
    strMsg = "Update All Comments in the Current view.  IMPORTANT!!! Will update a the Viewed records."
    
    If vbYes = MsgBox(strMsg, vbYesNo, "IMPORTANT!!  Confirmation") Then
        strMsg = "Please enter the remark"
        
       strRemark = InputBox(strMsg, "Remark")
        
       If Len(strRemark) > 0 Then
            strQry = "Update Final_Table set Remarks1 = Remarks1 &  '--" & strRemark & "'"
            QuickQry strQry, False
            Me.Requery
        End If
    Else
        MsgBox "Action cancelled."
    End If
    
End Sub

Open in new window

0
 

Author Comment

by:Jass Saini
ID: 40547247
I am not asking how to combine it anymore..I figured out to into in to one..now I need to update and save to the other records.  Which is different than combining...
0
 
LVL 38

Expert Comment

by:PatHartman
ID: 40547559
If you are taking a memo field and applying it to multiple rows, you almost certainly have a design flaw.  The memo field probably belongs in the parent record.
0
Use Case: Protecting a Hybrid Cloud Infrastructure

Microsoft Azure is rapidly becoming the norm in dynamic IT environments. This document describes the challenges that organizations face when protecting data in a hybrid cloud IT environment and presents a use case to demonstrate how Acronis Backup protects all data.

 

Author Comment

by:Jass Saini
ID: 40547599
Pat...what do you mean parent record.  Is my coding incorrect too??
0
 
LVL 38

Accepted Solution

by:
PatHartman earned 2000 total points
ID: 40547686
I didn't look at the coding.  I am questioning why you would want records to all have the same comment.  For example, in an order entry system we have tblOrder and tblOrderDetails.  If I wanted to put a note about the delivery of the order, I would not put it in the tblOrderDetails, I would put it tblOrder.  Why would I want the same note to appear on each line item when it could appear once on the order.  However, if the note was specific to a line item, then the note belongs on the line item.  In your case, you are saying that each line item should have the identical note as every other line item for a given order.  The problem may be the way your tables are structured.  If you don't have a "parent" table to group the rows where you can store information about ALL the rows, then perhaps you should.  Technically, you can create an order entry application with only tblOrderDetails.  The problem is that you would have the order number, client name, billing address, shipping address, tax, shipping cost, etc all repeated for each OrderDetail.
0
 

Author Comment

by:Jass Saini
ID: 40547703
That's is what I asked...But I have a set of records from a query and my boss wants all of them to have the same memo...

Don't ask me why...I was told to just say yes..anything can be done in access.. My boss doesn't know the limitation of access.  It's a great tool if you know how to use it???
0
 
LVL 38

Expert Comment

by:PatHartman
ID: 40547936
We are not talking about a limitation of Access.  We are talking about properly structuring your schema.   If you get the schema right, many things will simply fall into place and you won't have to struggle so much.  If you get the schema wrong (as you may be in this case), you'll have a nightmare on your hands.   The "boss" shouldn't be telling you how to store data, that is for you to decide.  You are the technical person.  What he is telling you is how he wants to "see" the data and that is a completely different topic.  To "see" the memo attached to each row, you only have to join to the table where it is stored and select it.  That satisfies the boss' request for how he wants to view data and doesn't cause any structural problem with the schema because you haven't stored duplicate data.

Once you manage to follow the directions the others will give you, you will have succeeded in committing the crime of the century from the perspective of proper database design.  Once you duplicate the data, do you have a plan for keeping all the separate copies in sync?
0
 

Author Comment

by:Jass Saini
ID: 40549157
Thanks Pat....I have been following directions...everything time I think I am at the end of my road..I end up at a crossroad.  Thanks for your help!
0

Featured Post

Does Your Cloud Backup Use Blockchain Technology?

Blockchain technology has already revolutionized finance thanks to Bitcoin. Now it's disrupting other areas, including the realm of data protection. Learn how blockchain is now being used to authenticate backup files and keep them safe from hackers.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

In Part II of this series, I will discuss how to identify all open instances of Excel and enumerate the workbooks, spreadsheets, and named ranges within each of those instances.
This article shows how to get a list of available printers for display in a drop-down list, and then to use the selected printer to print an Access report or a Word document filled with Access data, using different syntax as needed for working with …
With Microsoft Access, learn how to start a database in different ways and produce different start-up actions allowing you to use a single database to perform multiple tasks. Specify a start-up form through options: Specify an Autoexec macro: Us…
Visualize your data even better in Access queries. Given a date and a value, this lesson shows how to compare that value with the previous value, calculate the difference, and display a circle if the value is the same, an up triangle if it increased…
Suggested Courses

762 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question