![]() |
formatting question
I'm creating a Excel spreadsheet on the fly using C# with data from a text
file. My question is how can I add Groups to the spreadsheet and add some formatting? Example: my text file has cars in it (these can change daily) BMW Lexus VW GM Chevy so in my excel file how can i show BMW Lexus VW Gm Chevy and show information pertaining to that make of car? I have dates, prices, etc for each make. I want to group them all together so i don't see BMW 20 times or VW 20 times, I want to see BMW, VW once and then show all the data linked to the make. |
formatting question
Hi,
You are going to have to be more specific. What information are you trying to link to? What fields will be in the linked files? Does the text file only contain the general make of a vehicle? To link to another file you will need a unique ID for each text record, like the VIN number to do a lookup to and pull specific information. You might be able to set something up on a FIFO inventory basis or something similar to that, if all you have is the general make. Thanks, "microsoft.news.com" wrote: I'm creating a Excel spreadsheet on the fly using C# with data from a text file. My question is how can I add Groups to the spreadsheet and add some formatting? Example: my text file has cars in it (these can change daily) BMW Lexus VW GM Chevy so in my excel file how can i show BMW Lexus VW Gm Chevy and show information pertaining to that make of car? I have dates, prices, etc for each make. I want to group them all together so i don't see BMW 20 times or VW 20 times, I want to see BMW, VW once and then show all the data linked to the make. |
formatting question
my data in the text file looks like this:
BMW1999 325CI VIN123456789101236JohnSmith 4500020051212 Lexus2004ES300 VIN123456789101236BarneyRubble 2566020051214 BMW2005 325C VIN123456789101236BettySmith 6950020050105 I'm already parsing it out, I just now want to group it by make "David" wrote in message ... Hi, You are going to have to be more specific. What information are you trying to link to? What fields will be in the linked files? Does the text file only contain the general make of a vehicle? To link to another file you will need a unique ID for each text record, like the VIN number to do a lookup to and pull specific information. You might be able to set something up on a FIFO inventory basis or something similar to that, if all you have is the general make. Thanks, "microsoft.news.com" wrote: I'm creating a Excel spreadsheet on the fly using C# with data from a text file. My question is how can I add Groups to the spreadsheet and add some formatting? Example: my text file has cars in it (these can change daily) BMW Lexus VW GM Chevy so in my excel file how can i show BMW Lexus VW Gm Chevy and show information pertaining to that make of car? I have dates, prices, etc for each make. I want to group them all together so i don't see BMW 20 times or VW 20 times, I want to see BMW, VW once and then show all the data linked to the make. |
formatting question
Hi,
If it is coming through s you indicate, only with more lines and vehicles, it appears you could sort it as it is? The make is the first part of each line, all the bmws, lexus, etc should group naturally. What have you attempted so far? It may not be possible to answer your question with out your specific data in a file. Once it is sorted, you have indicated you want more things done? The only thing I see that is consistant and can be searched in these strings in the letters "VIN", possibly there is consistancy in the spacing? You want at this point to put specific information into columns? Thanks, "microsoft.news.com" wrote: my data in the text file looks like this: BMW1999 325CI VIN123456789101236JohnSmith 4500020051212 Lexus2004ES300 VIN123456789101236BarneyRubble 2566020051214 BMW2005 325C VIN123456789101236BettySmith 6950020050105 I'm already parsing it out, I just now want to group it by make "David" wrote in message ... Hi, You are going to have to be more specific. What information are you trying to link to? What fields will be in the linked files? Does the text file only contain the general make of a vehicle? To link to another file you will need a unique ID for each text record, like the VIN number to do a lookup to and pull specific information. You might be able to set something up on a FIFO inventory basis or something similar to that, if all you have is the general make. Thanks, "microsoft.news.com" wrote: I'm creating a Excel spreadsheet on the fly using C# with data from a text file. My question is how can I add Groups to the spreadsheet and add some formatting? Example: my text file has cars in it (these can change daily) BMW Lexus VW GM Chevy so in my excel file how can i show BMW Lexus VW Gm Chevy and show information pertaining to that make of car? I have dates, prices, etc for each make. I want to group them all together so i don't see BMW 20 times or VW 20 times, I want to see BMW, VW once and then show all the data linked to the make. |
formatting question
the data below is the acutal data coming from the text file. I have a C# app
that is getting the data and populating my excel spread sheet fine. But what I want is to Group the Make and only see the make once in the spreadsheet with all the data linked to it instead of seeing multiple lines for the make. in my excel file i'm seeing BMW BMW Lexus VW BMW Lexus and I want BMW YEAR MAKE VIN who bought it when they bought it and price Lexus YEAR MAKE VIN who bought it when they bought it and price I dont' want BMW BMW Lexus BMW etc. "David" wrote in message ... Hi, If it is coming through s you indicate, only with more lines and vehicles, it appears you could sort it as it is? The make is the first part of each line, all the bmws, lexus, etc should group naturally. What have you attempted so far? It may not be possible to answer your question with out your specific data in a file. Once it is sorted, you have indicated you want more things done? The only thing I see that is consistant and can be searched in these strings in the letters "VIN", possibly there is consistancy in the spacing? You want at this point to put specific information into columns? Thanks, "microsoft.news.com" wrote: my data in the text file looks like this: BMW1999 325CI VIN123456789101236JohnSmith 4500020051212 Lexus2004ES300 VIN123456789101236BarneyRubble 2566020051214 BMW2005 325C VIN123456789101236BettySmith 6950020050105 I'm already parsing it out, I just now want to group it by make "David" wrote in message ... Hi, You are going to have to be more specific. What information are you trying to link to? What fields will be in the linked files? Does the text file only contain the general make of a vehicle? To link to another file you will need a unique ID for each text record, like the VIN number to do a lookup to and pull specific information. You might be able to set something up on a FIFO inventory basis or something similar to that, if all you have is the general make. Thanks, "microsoft.news.com" wrote: I'm creating a Excel spreadsheet on the fly using C# with data from a text file. My question is how can I add Groups to the spreadsheet and add some formatting? Example: my text file has cars in it (these can change daily) BMW Lexus VW GM Chevy so in my excel file how can i show BMW Lexus VW Gm Chevy and show information pertaining to that make of car? I have dates, prices, etc for each make. I want to group them all together so i don't see BMW 20 times or VW 20 times, I want to see BMW, VW once and then show all the data linked to the make. |
formatting question
Hi,
Seems the best you will get is: BMW: Yr/Make/Vin/Who/When/Price Yr/Make/Vin/Who/When/Price Yr/Make/Vin/Who/When/Price Lex Yr/Make/Vin/Who/When/Price Yr/Make/Vin/Who/When/Price Yr/Make/Vin/Who/When/Price Etc. This is more parsing, based on the detail. BMW1999 325CI VIN123456789101236JohnSmith 4500020051212 The line above would have to be worked on. Chances are someone would have to work through enough examples to do this consistantly. The data all appears to be there probobly working through your real data is the only way someone will really be able to help you. A lot Text functions and stuff to look at. Thanks, "microsoft.news.com" wrote: the data below is the acutal data coming from the text file. I have a C# app that is getting the data and populating my excel spread sheet fine. But what I want is to Group the Make and only see the make once in the spreadsheet with all the data linked to it instead of seeing multiple lines for the make. in my excel file i'm seeing BMW BMW Lexus VW BMW Lexus and I want BMW YEAR MAKE VIN who bought it when they bought it and price Lexus YEAR MAKE VIN who bought it when they bought it and price I dont' want BMW BMW Lexus BMW etc. "David" wrote in message ... Hi, If it is coming through s you indicate, only with more lines and vehicles, it appears you could sort it as it is? The make is the first part of each line, all the bmws, lexus, etc should group naturally. What have you attempted so far? It may not be possible to answer your question with out your specific data in a file. Once it is sorted, you have indicated you want more things done? The only thing I see that is consistant and can be searched in these strings in the letters "VIN", possibly there is consistancy in the spacing? You want at this point to put specific information into columns? Thanks, "microsoft.news.com" wrote: my data in the text file looks like this: BMW1999 325CI VIN123456789101236JohnSmith 4500020051212 Lexus2004ES300 VIN123456789101236BarneyRubble 2566020051214 BMW2005 325C VIN123456789101236BettySmith 6950020050105 I'm already parsing it out, I just now want to group it by make "David" wrote in message ... Hi, You are going to have to be more specific. What information are you trying to link to? What fields will be in the linked files? Does the text file only contain the general make of a vehicle? To link to another file you will need a unique ID for each text record, like the VIN number to do a lookup to and pull specific information. You might be able to set something up on a FIFO inventory basis or something similar to that, if all you have is the general make. Thanks, "microsoft.news.com" wrote: I'm creating a Excel spreadsheet on the fly using C# with data from a text file. My question is how can I add Groups to the spreadsheet and add some formatting? Example: my text file has cars in it (these can change daily) BMW Lexus VW GM Chevy so in my excel file how can i show BMW Lexus VW Gm Chevy and show information pertaining to that make of car? I have dates, prices, etc for each make. I want to group them all together so i don't see BMW 20 times or VW 20 times, I want to see BMW, VW once and then show all the data linked to the make. |
formatting question
Several approaches come to mind, eg
Gouped Outline Pivot Table Filters Series of linked dropdown lists With such little information it's difficult to suggest which to opt for, though a table with filters is probably the easiest to set up. Regards, Peter T "microsoft.news.com" <CSharpCoder wrote in message ... the data below is the acutal data coming from the text file. I have a C# app that is getting the data and populating my excel spread sheet fine. But what I want is to Group the Make and only see the make once in the spreadsheet with all the data linked to it instead of seeing multiple lines for the make. in my excel file i'm seeing BMW BMW Lexus VW BMW Lexus and I want BMW YEAR MAKE VIN who bought it when they bought it and price Lexus YEAR MAKE VIN who bought it when they bought it and price I dont' want BMW BMW Lexus BMW etc. "David" wrote in message ... Hi, If it is coming through s you indicate, only with more lines and vehicles, it appears you could sort it as it is? The make is the first part of each line, all the bmws, lexus, etc should group naturally. What have you attempted so far? It may not be possible to answer your question with out your specific data in a file. Once it is sorted, you have indicated you want more things done? The only thing I see that is consistant and can be searched in these strings in the letters "VIN", possibly there is consistancy in the spacing? You want at this point to put specific information into columns? Thanks, "microsoft.news.com" wrote: my data in the text file looks like this: BMW1999 325CI VIN123456789101236JohnSmith 4500020051212 Lexus2004ES300 VIN123456789101236BarneyRubble 2566020051214 BMW2005 325C VIN123456789101236BettySmith 6950020050105 I'm already parsing it out, I just now want to group it by make "David" wrote in message ... Hi, You are going to have to be more specific. What information are you trying to link to? What fields will be in the linked files? Does the text file only contain the general make of a vehicle? To link to another file you will need a unique ID for each text record, like the VIN number to do a lookup to and pull specific information. You might be able to set something up on a FIFO inventory basis or something similar to that, if all you have is the general make. Thanks, "microsoft.news.com" wrote: I'm creating a Excel spreadsheet on the fly using C# with data from a text file. My question is how can I add Groups to the spreadsheet and add some formatting? Example: my text file has cars in it (these can change daily) BMW Lexus VW GM Chevy so in my excel file how can i show BMW Lexus VW Gm Chevy and show information pertaining to that make of car? I have dates, prices, etc for each make. I want to group them all together so i don't see BMW 20 times or VW 20 times, I want to see BMW, VW once and then show all the data linked to the make. |
formatting question
Hi,
If column "A" contains the make than look through all entries in column A For rw = Cells(Rows.COUNT, "A").End(xlUp).Offset(1, 0).row to 2 step -1 If cells(rw,1) = cells(rw-1,1) then cells(rw,1).clearcontents else = cells(rw,1)<cells(rw-1) Rows(rw).Insert cells(rw,1)=cells(rw+1,1) cells(rw+1,1).clear contents end if next You will need additional code for row 1 if it also contains a car make. add to end of code Rows(1).Insert cells(1,1)=cells(2,1) cells(2,1).clear contents rand451 "David" wrote in message ... Hi, Seems the best you will get is: BMW: Yr/Make/Vin/Who/When/Price Yr/Make/Vin/Who/When/Price Yr/Make/Vin/Who/When/Price Lex Yr/Make/Vin/Who/When/Price Yr/Make/Vin/Who/When/Price Yr/Make/Vin/Who/When/Price Etc. This is more parsing, based on the detail. BMW1999 325CI VIN123456789101236JohnSmith 4500020051212 The line above would have to be worked on. Chances are someone would have to work through enough examples to do this consistantly. The data all appears to be there probobly working through your real data is the only way someone will really be able to help you. A lot Text functions and stuff to look at. Thanks, "microsoft.news.com" wrote: the data below is the acutal data coming from the text file. I have a C# app that is getting the data and populating my excel spread sheet fine. But what I want is to Group the Make and only see the make once in the spreadsheet with all the data linked to it instead of seeing multiple lines for the make. in my excel file i'm seeing BMW BMW Lexus VW BMW Lexus and I want BMW YEAR MAKE VIN who bought it when they bought it and price Lexus YEAR MAKE VIN who bought it when they bought it and price I dont' want BMW BMW Lexus BMW etc. "David" wrote in message ... Hi, If it is coming through s you indicate, only with more lines and vehicles, it appears you could sort it as it is? The make is the first part of each line, all the bmws, lexus, etc should group naturally. What have you attempted so far? It may not be possible to answer your question with out your specific data in a file. Once it is sorted, you have indicated you want more things done? The only thing I see that is consistant and can be searched in these strings in the letters "VIN", possibly there is consistancy in the spacing? You want at this point to put specific information into columns? Thanks, "microsoft.news.com" wrote: my data in the text file looks like this: BMW1999 325CI VIN123456789101236JohnSmith 4500020051212 Lexus2004ES300 VIN123456789101236BarneyRubble 2566020051214 BMW2005 325C VIN123456789101236BettySmith 6950020050105 I'm already parsing it out, I just now want to group it by make "David" wrote in message ... Hi, You are going to have to be more specific. What information are you trying to link to? What fields will be in the linked files? Does the text file only contain the general make of a vehicle? To link to another file you will need a unique ID for each text record, like the VIN number to do a lookup to and pull specific information. You might be able to set something up on a FIFO inventory basis or something similar to that, if all you have is the general make. Thanks, "microsoft.news.com" wrote: I'm creating a Excel spreadsheet on the fly using C# with data from a text file. My question is how can I add Groups to the spreadsheet and add some formatting? Example: my text file has cars in it (these can change daily) BMW Lexus VW GM Chevy so in my excel file how can i show BMW Lexus VW Gm Chevy and show information pertaining to that make of car? I have dates, prices, etc for each make. I want to group them all together so i don't see BMW 20 times or VW 20 times, I want to see BMW, VW once and then show all the data linked to the make. |
All times are GMT +1. The time now is 12:30 PM. |
Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com