I am new to VBA and am stuck
by djsmithuk123 » Sat, 13 Dec 2003 21:01:12 GMT
I am really stuck, plz help me
on my first sheet I have headers called, meeting, time, date, winner.
i have a vba user sheet to input data on the next available line.
this is where I am stuck,
I now need the data enterd to be sorted in the relevant sheets.
for example under the header meeting, i may have 1, 2, 3, 4, 5
what i need is for this data to be sent to other sheets automatically
depending on what meeting it was.
I also need the remaining data (time, date) to be shown on the
relevant sheet,
eg.
sheet 2
should show
meeting time date
1 9:15 20/12/03
1 10:00 20/12/03
sheet3
should show
meeting time date
2 9:20 19/05/03
2 10:45 21/05/03
2 3:15 21/05/03
and so on and so on.
I also need this data to be sorted in order as shown above.
but sheet 1 may not be in sorted order,
is this posable??
if so I would be very gratefull if someone could tell me how to do
this.
many thanx
David
---
Message posted from http://www.**--****.com/
Re: I am new to VBA and am stuck
by Tom Ogilvy » Sat, 13 Dec 2003 21:40:46 GMT
You can use the advanced filter to copy date meeting specified criteria from
one sheet to another sheet. Turn on the macro recorder, then apply and
advanced filter to you data, use the copy option rather the filter in place
option. It is easiest to have the destination be on the same sheet,
otherwise, you have to start the filtering process from the destination
sheet. Anyway, once you have gotten a copy of the data for one of the
meetings, turn off the macro recorder. As far as the advanced filter part,
you should have recorded a single command. You can now alter this command
to put data on another sheet and to reference a separate criteria range on
each of the destination sheets that will get the appropriate data. If you
want a subset of the columns, this is supported as well. You can then
record sorting the data on one of the sheets and modify that code also.
--
Regards,
Tom Ogilvy
Re: I am new to VBA and am stuck
by snoopy369 » Sat, 13 Dec 2003 23:13:01 GMT
Sounds like you're trying to do something similar to what I'm doing ...
if you're reading this on excelforum.com, browse down to my thread --
I'm creating new worksheets dynamically based on a list of names (or in
this case you're using a list of numbers, but it should be similar).
This is necessary if you don't know how many meetings there are ahead
of time, and want the worksheet to create them dynamically.
If you want the original tip that I used to help create that, do a
google search on "excel new worksheet" and there should be an
exceltip.com link there. :)
-Joe
---
Message posted from http://www.**--****.com/
Similar Threads:
1.Mail Merge application - I am Stuck and need help
Hi to all,
I am new in this newsgroup and new to .NET also. I am creating an
application where I have to perform Mail Merge from my program. I have
created a form which contain RTB and user can write letters. I
programmatically add tags for address, name, comp. name et while saving the
letter. I have a datasource - in for mof a dataset to whom I have to send the
letter.
This is where I am stuck. I don't know how to open the selected letter
and replace the tags and how to do mail merge.
I am working wiht VB 2005.NET. Please help me out.
Any advice, guidance, suggestions are appreciated. I am really stuck and
really need help. I hope for any help line from you. So, if you can, please
help me accordingly.
Thanks
2.I am stuck....
Ok This is driving me batty..
Dim aStudentEmail(1000),x, iCounter, iTotal
For iCounter = 1 To iTotal
if LastClass <> rs("ITIDNM") then
aStudentEmail(x) = studentEmail
x=x+1
studentEmail =""
end if
studentEmail = studentEmail & trim(rs("ITEMAL")) & ","
response.write x & "-" & aStudentEmail(x) & "-<br>"
LastClass = rs("S.ITIDNM")
rs.MoveNext
Next
when it response.writes out.. I see
1--
2--
3--
and so on
yet when I do this:
response.write x & "-" & aStudentEmail(1) & "-<br>"
I get
XXXX@XXXXX.COM , XXXX@XXXXX.COM
WHAT IS GOING ON ? Why cant I get the value of that arraywhen x is in there ???
3.I am using VBA, how do you test for new record in a form
What should I test my VBA code so that I know the User is working with record
as New in a Form. I am using Access 2007 under Windows XP.
I used PrimaryID as an auto generated number, therefore it is Null in the
begining that is how I know the user is trying to add a new record and not
editing an existing one.
So I test for IsNull(PrimaryID) which works if the user do not make mistake
but as the user enter more information made mistakes and need to correct the
PrimaryID is no longer Null. So my test passed as if the use is editing the
existing record when in fact the user is trying to add a new record.
Any help is appreciated.
4.I am new to VBA - Help needed on Macro
Although I consider myself fairly good with Excel (I use 2003) I have
never used VBA.
I want to achieve something and feel a macro is the only way I can
achieve it.
Imagine I have the following in Excel:
1 A B C D
2 test 0
3 abc 0
4 abc123 1
5 something 1
6 text 1
7 hello 0
I want a cell, say, D1, to display the corresponding text in column A
for where it finds the first instance of a '1' in the B column. So it
would find a 1 in B4 and therefore display the text 'abc123' in cell
D1. It would then stop looking and ignore the 1's in B5 and B6.
Any help in this would be greatly appreciated!
Many thanks,
Mat G
Birmingham, UK
5.Tax calculator - I am really stuck!
6. Sorry but i am stuck again
7. Please add this in excel 2007 if not I am stuck with 2003
8. I am stuck