Microsoft Office

Microsoft Office Questions? Ask a IT Expert for Support ASAP

Ask a Computer Expert,
Get an Answer ASAP!

Microsoft Office

How do I get a total from a multi value field in Access? I

Customer Question
have a build list that...
How do I get a total from a multi value field in Access? I have a build list that has 1 multivalue field that contains the relationship to the inventory including part #, part name, and part price. I want to make the next column total just the part price from that multivalue field.
Submitted: 2 years ago.Category: Microsoft Office
Show More
Show Less
Ask Your Own Microsoft Office Question
Answered in 1 hour by:
10/18/2015
Microsoft Office Technician: R. Michael, MIS Analyst replied 2 years ago
R. Michael
R. Michael, MIS Analyst
Category: Microsoft Office
Satisfied Customers: 60
Experience: Masters of Info. Systems; 10+ years using Microsoft Office.
Verified

Hi thank you for using JustAnswer.com. It will be my pleasure to assist you today. I will re-create your list above and post back with the solution. PS: I know the books don't offer much for multivalue fields and they are tricky but a little vba should do the trick

Ask Your Own Microsoft Office Question
Customer reply replied 2 years ago
Thank you. Do you need any more info?
Microsoft Office Technician: R. Michael, MIS Analyst replied 2 years ago

Can you provide that exact table names and Field names, this way I can write a custom fuction whithout you having to change them. Also the Bound column in your multi-value lookup field would be helpful

I don't want to make assumptions.

Also just an FYI, Access doesn't suppot multi-value fields in calculated field expressions, so the solution is to trigger a function in vba and populate the totals.

Ask Your Own Microsoft Office Question
Customer reply replied 2 years ago
I have one table named Inventory with Part Number, Part Name, Description, Price, and QTY. the other table is Build Sheet that has the multivalue cell named Parts List that include Part Name, Description, and Price from the Inventory Table.
Microsoft Office Technician: R. Michael, MIS Analyst replied 2 years ago

I saw phone request but it wouldn't let me accept. I am finalizing the function now should have result shortly

Ask Your Own Microsoft Office Question
Customer reply replied 2 years ago
I don't know why. It is on and working....
Microsoft Office Technician: R. Michael, MIS Analyst replied 2 years ago

I proposed same offer Offer proposed: Live discussion via phone (We can have a live discussion via phone to make it easier and faster to get all the information you need. 1-***-***-****), $10

Ask Your Own Microsoft Office Question
Microsoft Office Technician: R. Michael, MIS Analyst replied 2 years ago

See code below: I will also provide a sample db with the code for you.

Function SumMultiValueField()

Dim dbs As Database
Dim sqlTable As String
Dim rstTable As Recordset
Dim rstMultiValueField As Recordset
Dim sqlPartPrice As String
Dim rstPartPrice As Recordset
Dim InventoryID As Long
Dim TotalPrice As Double

Set dbs = CurrentDb
'Selects All Fields of table that contains Multi-Value Field
sqlTable = "SELECT * FROM [Build Sheet]"
Set rstTable = dbs.OpenRecordset(sqlTable, dbOpenDynaset)

'Loops through all records of table that contains Multi-Value Field
Do While Not rstTable.EOF

'Sets Multi-Value Field equal to a recordset(list of prices selected)
Set rstMultiValueField = rstTable("Parts List").Value

'Initialize Total Price (in case no items selected)
TotalPrice = 0

'Loops through Selected Values of Multi=Value Field
Do While Not rstMultiValueField.EOF

InventoryID = rstMultiValueField.Fields(0).Value
sqlPartPrice = "SELECT Inventory.Price " & _
"FROM Inventory " & _
"WHERE (Inventory.[Part Number]=" & InventoryID & ")"
Set rstPartPrice = dbs.OpenRecordset(sqlPartPrice, dbOpenDynaset)

If rstPartPrice.RecordCount > 0 Then
TotalPrice = TotalPrice + rstPartPrice("Price").Value
End If

rstMultiValueField.MoveNext
Loop

'Edits Total Field
rstTable.Edit
rstTable("Total Price").Value = TotalPrice
rstTable.Update

rstTable.MoveNext
Loop

End Function

Ask Your Own Microsoft Office Question
Microsoft Office Technician: R. Michael, MIS Analyst replied 2 years ago

Also here is a link to the database i mocked up. The macro calls the function that calculates total price. See Link Below

https://drive.google.com/file/d/0B3hbJgQW_-OINmQtcGVVOXhicEk/view?usp=sharing

Ask Your Own Microsoft Office Question
Ask R. Michael Your Own Question
R. Michael
R. Michael
R. Michael, MIS Analyst
Category: Microsoft Office
Satisfied Customers: 60
60 Satisfied Customers
Experience: Masters of Info. Systems; 10+ years using Microsoft Office.

R. Michael is online now

A new question is answered every 9 seconds

How JustAnswer works:

  • Ask an ExpertExperts are full of valuable knowledge and are ready to help with any question. Credentials confirmed by a Fortune 500 verification firm.
  • Get a Professional AnswerVia email, text message, or notification as you wait on our site. Ask follow up questions if you need to.
  • 100% Satisfaction GuaranteeRate the answer you receive.

JustAnswer in the News:

Ask-a-doc Web sites: If you've got a quick question, you can try to get an answer from sites that say they have various specialists on hand to give quick answers... Justanswer.com.
JustAnswer.com...has seen a spike since October in legal questions from readers about layoffs, unemployment and severance.
Web sites like justanswer.com/legal
...leave nothing to chance.
Traffic on JustAnswer rose 14 percent...and had nearly 400,000 page views in 30 days...inquiries related to stress, high blood pressure, drinking and heart pain jumped 33 percent.
Tory Johnson, GMA Workplace Contributor, discusses work-from-home jobs, such as JustAnswer in which verified Experts answer people’s questions.
I will tell you that...the things you have to go through to be an Expert are quite rigorous.

What Customers are Saying:

My Expert answered my question promptly and he resolved the issue totally. This is a great service. I am so glad I found it I will definitely use the service again if needed.

One Happy CustomerNew York

Wonderful service, prompt, efficient, and accurate. Couldn't have asked for more. I cannot thank you enough for your help.

Mary C.Freshfield, Liverpool, UK

This expert is wonderful. They truly know what they are talking about, and they actually care about you. They really helped put my nerves at ease. Thank you so much!!!!

AlexLos Angeles, CA

Thank you for all your help. It is nice to know that this service is here for people like myself, who need answers fast and are not sure who to consult.

GPHesperia, CA

I couldn't be more satisfied! This is the site I will always come to when I need a second opinion.

JustinKernersville, NC

Just let me say that this encounter has been entirely professional and most helpful. I liked that I could ask additional questions and get answered in a very short turn around.

EstherWoodstock, NY

Thank you so much for taking your time and knowledge to support my concerns. Not only did you answer my questions, you even took it a step further with replying with more pertinent information I needed to know.

RobinElkton, Maryland

< Previous | Next >

Meet the Experts:

jstinehelfer

jstinehelfer

Information Systems Manager

36 satisfied customers

A+ Comptia Certified computer repair

JasonJames122

JasonJames122

Computer Enthusiast

0 satisfied customers

I manage all information systems (network of Windows PC's and servers with Microsoft Office products) for a small business

Jess M.

Jess M.

Computer Support Specialist

684 satisfied customers

Computer Software Specialist for more than 10 years

The-PC-Guy

The-PC-Guy

Computer Manager

579 satisfied customers

20 years experience providing remote computer support

James K.

James K.

Consultant

260 satisfied customers

Technical Director of IT Company

IT Miro

IT Miro

Computer Scientist

156 satisfied customers

Bachelor's Degree in Information Technology, Microsoft Certified Professional

Chris L.

Chris L.

Support Specialist

143 satisfied customers

Certified Expert with over 10 years experience.

< Previous | Next >

Related Microsoft Office Questions
My Exel 2016 and powerpoint 2016 aren't working and I need
My Exel 2016 and powerpoint 2016 aren't working and I need to get them fixed right away please.… read more
Mr.Med
Mr.Med
893 satisfied customers
Justine, Here. I have installed Office 365 Personal but
Hello Justine, Edward Here. I have installed Office 365 Personal but cannot get any of the Items. Need help. … read more
Viet - Computer Tech
Viet - Computer Tech
Computer Technican
Bachelor\u0027s Degree
952 satisfied customers
I purchased a new HP computer on Oct. 26, 2017. I am not
I purchased a new HP computer on Oct. 26, 2017. I am not happy with it and plan to return it to Walmart in the morning. I have already subscribed to the Microsoft Office. Is it transferable or do I ne… read more
Viet - Computer Tech
Viet - Computer Tech
Computer Technican
Bachelor\u0027s Degree
952 satisfied customers
I have just replaced my failed computer and I am having
I have just replaced my failed computer and I am having trouble loading Windows and getting up and running. I cannot seem to be able to create an account with Microsoft. … read more
Jess M.
Jess M.
Computer Support Specialist
Bachelor's Degree
684 satisfied customers
Just updated my mac software and my outlook 15.1.9 will not
just updated my mac software and my outlook 15.1.9 will not open … read more
Jess M.
Jess M.
Computer Support Specialist
Bachelor's Degree
684 satisfied customers
I have a virus in my excel. Can you help? I have
i have a virus in my excel. Can you help? JA: What's the make and model of your computer? And what version of Excel are you using? Customer: I have streamlining in my letters on my excel JA: Have you … read more
Richard
Richard
IT Manager
IT Manager, Consultant
3,207 satisfied customers
How much moneyisneeded to have a Microsoft licence for our
how much moneyisneeded to have a Microsoft licence for our computer? … read more
ChrisC
ChrisC
PC Technician
Associate Degree
659 satisfied customers
I recently upgraded to word 10. I now cannot get my old
I recently upgraded to word 10. I now cannot get my old macros to work … read more
Kris R
Kris R
IT Manager
Computing
2,257 satisfied customers
I have owned microsoft office suite 2013 and recently after
I have owned microsoft office suite 2013 and recently after an malware attack the programme no longer functions - will not open or allow a file to be opened. … read more
Michelle
Michelle
Manager operations
Bachelor\u0027s Degree
1,273 satisfied customers
I recently switched from PC to iMac.I wanted to use Word
I recently switched from PC to iMac.I wanted to use Word instead of Pages so I downloaded an app from the Apple Apps store called Document writer which had a Word icon on it. I have been going crazy a… read more
Jason Jones
Jason Jones
AAS Information Technology
6,316 satisfied customers
I am having trouble e-mailing my excel file to a mail
I am having trouble e-mailing my excel file to a mail recipient. I open the file, use the Quick Access Toolbar to "Send to Mail Recipient" and click send and the words "General mail failure" keep comi… read more
Specialist Sean S.
Specialist Sean S.
Computer Support Technician
663 satisfied customers
I have a Microsoft account but I am still locked out of
I have a Microsoft account but I am still locked out of Microsoft office … read more
Viet - Computer Tech
Viet - Computer Tech
Computer Technican
Bachelor\u0027s Degree
952 satisfied customers
How do you get rid of http:bl163.blu163.mail.live.com/ma
how do you get rid of http:bl163.blu163.mail.live.com/ma from an excel cell … read more
Jess M.
Jess M.
Computer Support Specialist
Bachelor's Degree
684 satisfied customers
I have tried unsuccesfully with Geek Squad to solve this
I have tried unsuccesfully with Geek Squad to solve this problem and I need your help. I cannot connect Outlook with its folders such as "deleted files", Junk files", "sent files", and make them work … read more
caraleneK
caraleneK
Service Manager
1,636 satisfied customers
I am being charged $7.57 per month by Microsoft for
I am being charged $7.57 per month by Microsoft for Microsoft Office 36. I don't use this product and wish to have the charges stopped. How do I get that done? … read more
Kamil Anwar
Kamil Anwar
IT Consultant / Systems Engineer
Bachelor\u0027s Degree
426 satisfied customers
Something is wrong...I am unable to "Send" my message....the
Something is wrong...I am unable to "Send" my message....the option does not appear on my screen as it usually does. … read more
Isaac Franklin
Isaac Franklin
Associate of Science in Social Sciences
837 satisfied customers
I have a document typed in Word 2010. I have Windows 10.
I have a long document typed in Word 2010. I have Windows 10. When I made some changes in the document, the page started to roll up rapidly to the top of the document. I have no idea why. Now I can't … read more
PC_Wizzard
PC_Wizzard
IT Technician
32 satisfied customers
TROUBLE USING THR $ SYMBOLS IN FORULMAS. TO BUILD A CHECK
i AM HAVING TROUBLE USING THR $ SYMBOLS IN FORULMAS. i AM TRYING TO BUILD A CHECK REGISTER. … read more
Richard
Richard
IT Manager
IT Manager, Consultant
3,207 satisfied customers
Disclaimer: Information in questions, answers, and other posts on this site ("Posts") comes from individual users, not JustAnswer; JustAnswer is not responsible for Posts. Posts are for general information, are not intended to substitute for informed professional advice (medical, legal, veterinary, financial, etc.), or to establish a professional-client relationship. The site and services are provided "as is" with no warranty or representations by JustAnswer regarding the qualifications of Experts. To see what credentials have been verified by a third-party service, please click on the "Verified" symbol in some Experts' profiles. JustAnswer is not intended or designed for EMERGENCY questions which should be directed immediately by telephone or in-person to qualified professionals.

Disclaimer: Information in questions, answers, and other posts on this site ("Posts") comes from individual users, not JustAnswer; JustAnswer is not responsible for Posts. Posts are for general information, are not intended to substitute for informed professional advice (medical, legal, veterinary, financial, etc.), or to establish a professional-client relationship. The site and services are provided "as is" with no warranty or representations by JustAnswer regarding the qualifications of Experts. To see what credentials have been verified by a third-party service, please click on the "Verified" symbol in some Experts' profiles. JustAnswer is not intended or designed for EMERGENCY questions which should be directed immediately by telephone or in-person to qualified professionals.

Show MoreShow Less

Ask Your Question

x