472,344 Members | 2,250 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 472,344 software developers and data experts.

importing Data from access

I have been attempting to create a reservation planning form in excel
that imports Data from an Access database and inserts that information
automaticly into the correct spreed sheet and the correct cells within
that worksheet. The Excel Book is made up of 12 worksheets named
Jan-Dec. Each worksheet has columns labeled as each day of that month.
Column 'A' is reserved for 19 rows named "room1 - room19". The data I
am importing from the data base is " start date", "end date" and "room
number". I am also importing " surname" which i have intended to use
as the data that is actually inserted into the cell which is hopefull
pinpointed using the other information. I have had an attempt at using
VBA but totally unsuccessful. I am hoping that someone could point me
in the right direction. Please
Nov 13 '05 #1
7 2860
are you working on an hotel reservation system?
Nov 13 '05 #2
Hi Darren

i've just done something very similar (with heaps of help from this & other
ngs) the way i approached it was
1) use a make-table query in access to extract the data that i want to use
in excel to one table
2) open excel and use data / get external data / database query
to return all the data from the table into one sheet (called imported from
access)
3) then linked the fields in the other sheets to the correct fields in this
sheet (using a combination of offset / match & lookup functions - depending
on how "variable" the data is)
4) wrote code to prompt to refresh the data when the workbook is opened -
when the data is refreshed it saves the workbook with a new name & unlinks
the query from access

this might give you a plan of attack -

Cheers
JulieD
"Darren" <da*************@uk.easynet.net> wrote in message
news:67**************************@posting.google.c om...
I have been attempting to create a reservation planning form in excel
that imports Data from an Access database and inserts that information
automaticly into the correct spreed sheet and the correct cells within
that worksheet. The Excel Book is made up of 12 worksheets named
Jan-Dec. Each worksheet has columns labeled as each day of that month.
Column 'A' is reserved for 19 rows named "room1 - room19". The data I
am importing from the data base is " start date", "end date" and "room
number". I am also importing " surname" which i have intended to use
as the data that is actually inserted into the cell which is hopefull
pinpointed using the other information. I have had an attempt at using
VBA but totally unsuccessful. I am hoping that someone could point me
in the right direction. Please

Nov 13 '05 #3
"WindAndWaves" <ac****@ngaru.com> wrote in message news:<Pd*****************@news.xtra.co.nz>...
are you working on an hotel reservation system?


Thats right. Any Ideas
Nov 13 '05 #4
"JulieD" <Ju****@hctsReMoVeThIs.net.au> wrote in message news:<uk**************@TK2MSFTNGP10.phx.gbl>...
Hi Darren

i've just done something very similar (with heaps of help from this & other
ngs) the way i approached it was
1) use a make-table query in access to extract the data that i want to use
in excel to one table
2) open excel and use data / get external data / database query
to return all the data from the table into one sheet (called imported from
access)
3) then linked the fields in the other sheets to the correct fields in this
sheet (using a combination of offset / match & lookup functions - depending
on how "variable" the data is)
4) wrote code to prompt to refresh the data when the workbook is opened -
when the data is refreshed it saves the workbook with a new name & unlinks
the query from access

this might give you a plan of attack -

Cheers
JulieD
"Darren" <da*************@uk.easynet.net> wrote in message
news:67**************************@posting.google.c om...
I have been attempting to create a reservation planning form in excel
that imports Data from an Access database and inserts that information
automaticly into the correct spreed sheet and the correct cells within
that worksheet. The Excel Book is made up of 12 worksheets named
Jan-Dec. Each worksheet has columns labeled as each day of that month.
Column 'A' is reserved for 19 rows named "room1 - room19". The data I
am importing from the data base is " start date", "end date" and "room
number". I am also importing " surname" which i have intended to use
as the data that is actually inserted into the cell which is hopefull
pinpointed using the other information. I have had an attempt at using
VBA but totally unsuccessful. I am hoping that someone could point me
in the right direction. Please


Hi Julie
Thanks for the info. I have got as far as importing the data to a new
worksheet but I am now having problems linking the Data with my
original form ( basicly haven,t got a clue as to how this is done). i
assume that some of the data imported i.e (start date , end date and
room number) will somehow need to go into the offset formula to locate
the cell the data needs to go into. Would I be correct to say that
the formula should be similar to this:

offset (A1, startdate, room number, 1 , total number of days)
OFFSET (reference,column,row,hight,width)

I can see a little light at the end of the tunnel.

Darren
Nov 13 '05 #5
Hi Darren

glad you're getting somewhere with it .. .you don't need to use all the
parameters of the offset function - the last two are optional and, in this
case, i think, irrelevant for you.

=offset(Sheet_Name!$A$1,match(B1,StartDate,0),matc h(C1,RoomNumber,0))

where startdate and roomnumber are the names of the ranges (startdate the
rows & roomnumber the columns) where the start dates (B1) & room numbers
(C1) are held - so you're asking excel to go to the imported sheet, find the
appropriate start date and move across to the relevant room number and
return the information at the junction of these two bits of information.

hope this helps
Cheers
JulieD


"Darren" <da*************@uk.easynet.net> wrote in message
news:67**************************@posting.google.c om...
"JulieD" <Ju****@hctsReMoVeThIs.net.au> wrote in message

news:<uk**************@TK2MSFTNGP10.phx.gbl>...
Hi Darren

i've just done something very similar (with heaps of help from this & other ngs) the way i approached it was
1) use a make-table query in access to extract the data that i want to use in excel to one table
2) open excel and use data / get external data / database query
to return all the data from the table into one sheet (called imported from access)
3) then linked the fields in the other sheets to the correct fields in this sheet (using a combination of offset / match & lookup functions - depending on how "variable" the data is)
4) wrote code to prompt to refresh the data when the workbook is opened - when the data is refreshed it saves the workbook with a new name & unlinks the query from access

this might give you a plan of attack -

Cheers
JulieD
"Darren" <da*************@uk.easynet.net> wrote in message
news:67**************************@posting.google.c om...
I have been attempting to create a reservation planning form in excel
that imports Data from an Access database and inserts that information
automaticly into the correct spreed sheet and the correct cells within
that worksheet. The Excel Book is made up of 12 worksheets named
Jan-Dec. Each worksheet has columns labeled as each day of that month.
Column 'A' is reserved for 19 rows named "room1 - room19". The data I
am importing from the data base is " start date", "end date" and "room
number". I am also importing " surname" which i have intended to use
as the data that is actually inserted into the cell which is hopefull
pinpointed using the other information. I have had an attempt at using
VBA but totally unsuccessful. I am hoping that someone could point me
in the right direction. Please


Hi Julie
Thanks for the info. I have got as far as importing the data to a new
worksheet but I am now having problems linking the Data with my
original form ( basicly haven,t got a clue as to how this is done). i
assume that some of the data imported i.e (start date , end date and
room number) will somehow need to go into the offset formula to locate
the cell the data needs to go into. Would I be correct to say that
the formula should be similar to this:

offset (A1, startdate, room number, 1 , total number of days)
OFFSET (reference,column,row,hight,width)

I can see a little light at the end of the tunnel.

Darren

Nov 13 '05 #6
Dear Darren

I have written a large reservation system myself. If you would be keen to
share any ideas then do not hesitate to contact me.

Anyway, I am not a specialist for your question, but I would make an excel
file and link it to Access, rather than the other way round.

Having said that, why would you use Excel at all?

Let me know

- Nicolaas
Nov 13 '05 #7
Hi Julie

I have been attempting as suggested to use OFFSET and MATCH functions
to a certain degree of success. I have also used the ADDRESS function.
These have both located the cell or cells successfully. The OFFSET
function just tells me that no value is inserted in the located cell
and ADDRESS returns the cell reference. Any Idea how I can force a
particular value to the located cell or cells.

Thanks

Darren
Nov 13 '05 #8

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

11
by: Grim Reaper | last post by:
I am importing a .csv file into Access that has 37 fields. My problem is that sometimes the last field only has data at the end of the column (it...
1
by: sparks | last post by:
I have never done this and wanted to ask people who have what is the best way. One person said import it to excel, then import it into access...
5
by: dixie | last post by:
If I sent a user an empty database container - dB with no tables and I needed them to import their tables into it and one of their tables was a...
2
by: nutthatch | last post by:
I want to be able to import an Excel spreadsheet into Access 2K using the macro command Transferspreadsheet. However, the file I am importing...
1
by: Geoff Jones | last post by:
Hi I have a question which I hope somebody can answer. I have written a VB application with which I want to import an Excel file, analyze the...
11
by: kaisersose1995 | last post by:
Hi, I've got an import procedure working, using a standard import specification to import a .csv file into a temporary table. The problem i'm...
1
by: winzy | last post by:
I have a table in Access which needs updating from an Excel file. Instead of importing the whole Excel like a new table in Acess, how do I do a...
5
by: hharriel | last post by:
Hi, I am hoping someone can help me with an issue I am having with excel and ms access. I have collected data (which are in individual excel...
3
by: mukeshsrivastav | last post by:
dear sir i want to move form excel to access. i have 5 excel file having same formats and fields.now i want to import all data in one access...
0
by: concettolabs | last post by:
In today's business world, businesses are increasingly turning to PowerApps to develop custom business applications. PowerApps is a powerful tool...
0
better678
by: better678 | last post by:
Question: Discuss your understanding of the Java platform. Is the statement "Java is interpreted" correct? Answer: Java is an object-oriented...
0
by: Kemmylinns12 | last post by:
Blockchain technology has emerged as a transformative force in the business world, offering unprecedented opportunities for innovation and...
0
jalbright99669
by: jalbright99669 | last post by:
Am having a bit of a time with URL Rewrite. I need to incorporate http to https redirect with a reverse proxy. I have the URL Rewrite rules made...
0
by: antdb | last post by:
Ⅰ. Advantage of AntDB: hyper-convergence + streaming processing engine In the overall architecture, a new "hyper-convergence" concept was...
2
by: Matthew3360 | last post by:
Hi, I have a python app that i want to be able to get variables from a php page on my webserver. My python app is on my computer. How would I make it...
0
by: AndyPSV | last post by:
HOW CAN I CREATE AN AI with an .executable file that would suck all files in the folder and on my computerHOW CAN I CREATE AN AI with an .executable...
0
by: Arjunsri | last post by:
I have a Redshift database that I need to use as an import data source. I have configured the DSN connection using the server, port, database, and...
0
by: Matthew3360 | last post by:
Hi, I have been trying to connect to a local host using php curl. But I am finding it hard to do this. I am doing the curl get request from my web...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.