Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
luk_sr
 
Posts: n/a
Default How do I sort data into 2 worksheets in excel vba?

Here's the situation...

I need to take the fifth digit of a six digit strText. If the fifth digit
is even, I need to store the data row in worksheet(Controlled), Else if the
fifth digit is odd, then store the data row in worksheet(Experimental).

After sorting current records, I need to create a form for data input. I
figure it would be easier to have the data separated during initial processes.

I thought of using the inStr function, but this would only work if I first
put spaces between each digit, right. If someone knows of an easier way to
do this, please help.
  #2   Report Post  
CLR
 
Posts: n/a
Default

Here's one way.............

=IF(ISODD(MID(A1,LEFT(A1,1)+4,1)),"ODD","EVEN")

This formula will determine if the 5th digit in A1 is odd or
even..........put it in a helper column and copy down (assuming your data
is in column A)..........then Copy PasteSpecial values on that column to
replace the formulas and do Autofilter and pick the odd's or the even's and
copy that field to another sheet, then do it again for the opposite
one............turn on the Macro recorder first and you got the whole thing
in a macro to run for next time..........

hth
Vaya con Dios,
Chuck, CABGx3

"luk_sr" wrote in message
...
Here's the situation...

I need to take the fifth digit of a six digit strText. If the fifth digit
is even, I need to store the data row in worksheet(Controlled), Else if

the
fifth digit is odd, then store the data row in worksheet(Experimental).

After sorting current records, I need to create a form for data input. I
figure it would be easier to have the data separated during initial

processes.

I thought of using the inStr function, but this would only work if I first
put spaces between each digit, right. If someone knows of an easier way

to
do this, please help.



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
External data Macro Problem Excel 97 Craig Kelly Excel Discussion (Misc queries) 1 January 17th 05 03:17 PM
HELP! How do you--> Lock a set of rows but also link worksheets to FRUSTRATED Excel Discussion (Misc queries) 6 December 29th 04 10:05 PM
Layout/Formatting problems of Data Queries in Excel? Andrew Harding Excel Discussion (Misc queries) 0 December 23rd 04 03:51 AM
Can you sort Excel data by font color? Help Me Sort Excel Discussion (Misc queries) 2 December 21st 04 10:35 PM
Named dynamic ranges, copied worksheets and graph source data WP Charts and Charting in Excel 1 November 28th 04 05:19 PM


All times are GMT +1. The time now is 08:27 PM.

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"