Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default VBA Report How?


I want to code a module below using 2 worksheets i.e "Data" and "Query"
but not good in vba code.

Look in the datasheet at row2 for a value of 1, if found, then look at
next row i.e. row3 for value found in the querysheet. If the individual
value found is the same as in the querysheet individual column, it will
write the date & rowno of row2 of datasheet and the value of 1 or 0
will be insert accordingly to the column into the querysheet.

This macro will run the loops from row2 of datasheet until the last
row. New found items/values will be written row after row in the
querysheet. Can anyone help.

Some questions concerning VBA syntax.

Q1) To use a workbook/worksheet
Q2) Do whil not eof() & Enddo.
Q3) Checking a range of cells for value
Q4) Skipping next row
Q5) Writing value to particular cell into particular cell
Q6) Do Case & Endcase with Select.

Can someone tell me what are these syntax in VBA.

Thank you.


------------------------------------------------
~~ Message posted from http://www.ExcelTip.com/
~~View and post usenet messages directly from http://www.ExcelForum.com/

  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 109
Default VBA Report How?

Don't have time to work out all your query. In any case, the Excel
macro recorder is excellent, so you can always start out by doing the
job manually and checking the code it produces.
'Q1) To use a workbook/worksheet
Workbooks("MyBook.xls").Open
'Q2) Do whil not eof() & Enddo.
rw = 1
While Cells(rw, 1).Value < ""
'--code
Wend
'Q3) Checking a range of cells for value
'See VB Editor Help "Find"
'Q4) Skipping next row
'??
'Q5) Writing value to particular cell into particular cell
Workbooks("MyBook.xls").Cells(1, 1).Value =
Workbooks("YourBook.xls").Range("A1").Value
'Q6) Do Case & Endcase with Select.
See VBE Help - "Select Case"

Regards
BrianB
================================================== ===



Michael168 wrote in message ...
I want to code a module below using 2 worksheets i.e "Data" and "Query"
but not good in vba code.

Look in the datasheet at row2 for a value of 1, if found, then look at
next row i.e. row3 for value found in the querysheet. If the individual
value found is the same as in the querysheet individual column, it will
write the date & rowno of row2 of datasheet and the value of 1 or 0
will be insert accordingly to the column into the querysheet.

This macro will run the loops from row2 of datasheet until the last
row. New found items/values will be written row after row in the
querysheet. Can anyone help.

Some questions concerning VBA syntax.

Q1) To use a workbook/worksheet
Q2) Do whil not eof() & Enddo.
Q3) Checking a range of cells for value
Q4) Skipping next row
Q5) Writing value to particular cell into particular cell
Q6) Do Case & Endcase with Select.

Can someone tell me what are these syntax in VBA.

Thank you.


------------------------------------------------
~~ Message posted from http://www.ExcelTip.com/
~~View and post usenet messages directly from http://www.ExcelForum.com/

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
How do I make a vertical report export into a vertical report? April Excel Discussion (Misc queries) 3 January 18th 10 11:13 PM
Getting missing data from one report into another report... vlookupabyss Excel Discussion (Misc queries) 3 January 8th 08 03:26 PM
Print Report W/Sub Report Roger Excel Discussion (Misc queries) 0 September 6th 06 10:53 PM
Automate Excel report to place certain data into existing report? Craig Harrison Excel Worksheet Functions 3 July 25th 06 01:54 PM
Header in Report Manager Report Steve K Excel Discussion (Misc queries) 0 March 7th 06 07:32 PM


All times are GMT +1. The time now is 02:21 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"