Hi there,
First time poster, so feel free to throw sticks at me if this isn't clear (or, alternatively, if it's clearly a n00b question ).
I've been playing with VBA in Excel for about 6 weeks now, and so far, I've either been able to find the solution(s) I need on the internet**, or play around with the code enough to make it work.
Back in the late 80's I did a lot of Basic programming on the Amstrad, so the concept and syntax of VBA is fine with me, it's just some of the actual commands that I'm having trouble finding. Anyway...
+ + + + + + + + + +
I've got a worksheet (essentially a database, but the Access version of this is in such a mess, an Excel version is easier for me to work with) which lists various components, one row each. The file's 2mb so it seems silly attaching or linking to it. Screenshot here:
http://www.skittlez.co.uk/stuff/excel_01.jpg
Generally, the sheet is referenced by another spreadsheet, where VLOOKUP searches for the Cast number (Column B*) that a user inputs, and brings back the rest of the details (Columns C-H).
As new components arrive, they're manually entered into the sheet at the bottom. However, my department are given bundles of paper with component certificates to check, and 90% of those will be already in the system.
So, rather than the 'Find' function, I've built in a VLOOKUP section at the top of the page. When a user enters a Cast number into I2, the cert number (ie the value in Column C) is returned in J2. This basically lets you know if it's already in there, and is a lot neater than Excel's Edit/Find funtion, visually speaking.
From time to time, however, it's neccessary to actually go to the row containing the information, to inspect the other properties. So I'd like to assign a Macro to the 'Go' button to do just that.
Once a value is in J2, I'd like the macro to search for that value in Column C, then select that cell, effectively bypassing the Find dialog box.
I've tried playing with Index/Match, but it only seems to be returning information for me, not actually going to a cell. Although I suspect that's me not being familiar enough with Index/Match.
I think that's all the info you'll need, but I may well be wrong. Obviously, let me know if I've been vague about any of it
Many thanks in advance,
BLaCKouT.
*A few further notes on the attached pic:
• The green column (A) is concatenated info from B and F. This is what the external spreadsheet actually searches, as from time to time a user inputs information from the 'Plate' column (F), and I needed a VLookup to effectively search both.
• The blue, 'Go to end' button is a macro to search down column C until it finds the last entered number, then select the next one down. It's a quick way of getting to the 'fresh' part of the sheet.
• The Char.Count column (I) alerts a user if the Column F goes over 235 characters. This is because Excel won't do the VLookup I need if the concatenated information in Column A is over 256 characters.
** Largely down to this forum, thanks very much!
First time poster, so feel free to throw sticks at me if this isn't clear (or, alternatively, if it's clearly a n00b question ).
I've been playing with VBA in Excel for about 6 weeks now, and so far, I've either been able to find the solution(s) I need on the internet**, or play around with the code enough to make it work.
Back in the late 80's I did a lot of Basic programming on the Amstrad, so the concept and syntax of VBA is fine with me, it's just some of the actual commands that I'm having trouble finding. Anyway...
+ + + + + + + + + +
I've got a worksheet (essentially a database, but the Access version of this is in such a mess, an Excel version is easier for me to work with) which lists various components, one row each. The file's 2mb so it seems silly attaching or linking to it. Screenshot here:
http://www.skittlez.co.uk/stuff/excel_01.jpg
Generally, the sheet is referenced by another spreadsheet, where VLOOKUP searches for the Cast number (Column B*) that a user inputs, and brings back the rest of the details (Columns C-H).
As new components arrive, they're manually entered into the sheet at the bottom. However, my department are given bundles of paper with component certificates to check, and 90% of those will be already in the system.
So, rather than the 'Find' function, I've built in a VLOOKUP section at the top of the page. When a user enters a Cast number into I2, the cert number (ie the value in Column C) is returned in J2. This basically lets you know if it's already in there, and is a lot neater than Excel's Edit/Find funtion, visually speaking.
From time to time, however, it's neccessary to actually go to the row containing the information, to inspect the other properties. So I'd like to assign a Macro to the 'Go' button to do just that.
Once a value is in J2, I'd like the macro to search for that value in Column C, then select that cell, effectively bypassing the Find dialog box.
I've tried playing with Index/Match, but it only seems to be returning information for me, not actually going to a cell. Although I suspect that's me not being familiar enough with Index/Match.
I think that's all the info you'll need, but I may well be wrong. Obviously, let me know if I've been vague about any of it
Many thanks in advance,
BLaCKouT.
*A few further notes on the attached pic:
• The green column (A) is concatenated info from B and F. This is what the external spreadsheet actually searches, as from time to time a user inputs information from the 'Plate' column (F), and I needed a VLookup to effectively search both.
• The blue, 'Go to end' button is a macro to search down column C until it finds the last entered number, then select the next one down. It's a quick way of getting to the 'fresh' part of the sheet.
• The Char.Count column (I) alerts a user if the Column F goes over 235 characters. This is because Excel won't do the VLookup I need if the concatenated information in Column A is over 256 characters.
** Largely down to this forum, thanks very much!