Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 9
Default creating database help please!

Hi!

I would like to create an entry form, where the user inputs data into cells
in a column format, lets say from F5 to F8 in sheet1, and then these get
copied to sheet2 into a row format from lets say A1 to D1 respectively. So
where F5 gets copied to A1 then F6 to B1 etc etc. And then the next time I
enter data in sheet1 and run the macro I want the data to fill the next row
in sheet2, for example, from F5 to A2, F6 to B2 etc etc

THANK YOU!


  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1,533
Default creating database help please!

Hi

Try this:

Sub CopyData()
Dim CopyRng As Range
Dim DestRng As Range

Set CopyRng = Range("F5:F8")
With Worksheets("Sheet2")
If .Range("A1") < "" Then
Set DestRng = .Range("A1").End(xlDown).Offset(1, 0)
Else
Set DestRng = .Range("A1")
End If
End With
CopyRng.Copy DestRng
End Sub

Regards,
Per

"deemo85" skrev i meddelelsen
...
Hi!

I would like to create an entry form, where the user inputs data into
cells
in a column format, lets say from F5 to F8 in sheet1, and then these get
copied to sheet2 into a row format from lets say A1 to D1 respectively.
So
where F5 gets copied to A1 then F6 to B1 etc etc. And then the next time
I
enter data in sheet1 and run the macro I want the data to fill the next
row
in sheet2, for example, from F5 to A2, F6 to B2 etc etc

THANK YOU!


  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1,522
Default creating database help please!

try this to copy f8:f8 transposed to the next availalble row
Sub transposecolumntorows()
dim nar as long
with sheets("sheet2")
nar = .Cells(Rows.Count, 1).End(xlUp).Row + 1
sheets("sheet1").range("f5:f8").copy
..Cells(nar, 1).PasteSpecial Paste:=xlPasteValues, _
Operation:=xlNone, SkipBlanks:=False, Transpose:=True
end with
End Sub

--
Don Guillett
Microsoft MVP Excel
SalesAid Software

"deemo85" wrote in message
...
Hi!

I would like to create an entry form, where the user inputs data into
cells
in a column format, lets say from F5 to F8 in sheet1, and then these get
copied to sheet2 into a row format from lets say A1 to D1 respectively.
So
where F5 gets copied to A1 then F6 to B1 etc etc. And then the next time
I
enter data in sheet1 and run the macro I want the data to fill the next
row
in sheet2, for example, from F5 to A2, F6 to B2 etc etc

THANK YOU!



Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
creating database help please! deemo85 Excel Discussion (Misc queries) 3 February 14th 10 09:52 PM
Creating worksheets from a database PaulVeilleux Excel Discussion (Misc queries) 3 August 22nd 06 08:37 PM
Creating A Search Database..Need Help ajaffer Excel Discussion (Misc queries) 6 December 3rd 05 09:50 PM
Creating a Database with VBA Philip Spitzer Excel Programming 2 April 12th 05 09:03 AM
creating a database and database query Tim Excel Programming 1 March 5th 04 06:17 PM


All times are GMT +1. The time now is 01:04 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"