OpenOffice.org Forum at OOoForum.orgThe OpenOffice.org Forum
 
 [Home]   [FAQ]   [Search]   [Memberlist]   [Usergroups]   [Register
 [Profile]   [Log in to check your private messages]   [Log in

Macro to search another document

 
Post new topic   Reply to topic    OOoForum.org Forum Index -> OpenOffice.org Calc
View previous topic :: View next topic  
Author Message
rgebap
Newbie
Newbie


Joined: 28 Mar 2012
Posts: 4

PostPosted: Wed Mar 28, 2012 5:29 am    Post subject: Macro to search another document Reply with quote

Hi first post here,

The company I work for currently hand types in every address for every packing slip and invoice. I was hoping to create one calc file that keeps all the information for each of our customers (addresses and what not). Then create a template that will allow you to search the customer contact information file (through a macro) and populate the fields in a packing slip and invoice based on the search. Or if it is a new customer, allow them to enter the information manually and with a macro create a new entry into the customer contact information file so it can be searched next time they order.

I am a real beginner at macros and would love some help. Maybe just an example of something like this and I would be able to go from there.

Thanks,

Rob
Back to top
View user's profile Send private message
Villeroy
Super User
Super User


Joined: 04 Oct 2004
Posts: 10106
Location: Germany

PostPosted: Wed Mar 28, 2012 6:38 am    Post subject: Reply with quote

It is extremely silly to do this in a spreadsheet. Each and every business software would always use some database software for this.

But even if somebody/something forces you to use calculator sheets as a primitive database surrogate, there is no need to write any macros in order to look up records from another sheet.
VLOOKUP tutorial

You should always store everything in one spreadsheet document. Simply copy the data you get from elsewhere into your single document.
If somebody/something forces you to work with references across documents:
[Tutorial] External Links In Calc

Writing amateur macros to emulate a database in a spreadsheet is by far more complex, error prone and laborious.
_________________
Rest in peace, oooforum.org
Get help on https://forum.openoffice.org
Back to top
View user's profile Send private message
rgebap
Newbie
Newbie


Joined: 28 Mar 2012
Posts: 4

PostPosted: Wed Mar 28, 2012 9:20 am    Post subject: Thanks Reply with quote

Thanks Villeroy,

I actually found that using a combination of vlookup and external links to be my best option. I will also look into migrating our customer contacts into Base. You have been very helpful.

-Rob
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    OOoForum.org Forum Index -> OpenOffice.org Calc All times are GMT - 8 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2005 phpBB Group