I am creating a macro that saves a file using the value in X1 as a variable name to save the file. I want to check if the last character in cell X1 is a period ("."), and if it is I want to either remove the period from X1 and continue to save, or tell the user it is not possible to save the name that ends in a period.
I have a cell range that is passed as a String to a function, and within that function I need to extract only the Column letter. If it was just 1 letter it would be simple, but it may be 2, so does anybody know of a way of testing to see if the second character is a letter or a number?
I have a cell which will contain SER01+SER02+SER03
and what i need it to contain is [SER01]+[SER02]+[SER03]
and shocker is i've got this to work for the first instance but not the other two
code as below... be grateful for your help
Sub measure1() Dim list As String, pos As Integer, refl As String, refr As String, newlist As String list = Cells(1472, 16).Value pos = InStr(list, "+") refl = Left(list, pos - 1) refr = Right(list, pos + 1) newlist = "[" & refl & "]" Cells(1472, 17) = newlist End Sub
I have data in Row 53 that spans 7 columns, but stays in the same row. I want to design a loop to select every 7th cell in that row and check if it is empty. If not, add onto a "counter" then display the final number of occupied cells (the value of the counter) at the end. This is what I have so far, but I get all sorts of errors.
Code: Sub Tester()
Dim WB As Workbook Dim WS As Worksheets Dim modCounter As Long Dim Cell As Range
Set WB = Workbook("Transverse Series.xlsm") Set WS = WB.Sheets(BM18)
I have got a list of numeric abbreviations, for instance 10739011/21/31/41. What it should really display are the numbers 10739011, 10739021, 10739031 and 10739041 (the first six figures stay the same). All the numbers in my list are 8 figures long. I want to change the list from the list seperated by the backward slash to the complete numbers. I have uploaded an example of the list with backward slash between the numbers. Is there a way that Excel can automatically change these numbers to the full numbers?
Because all the numbers are 8 figures long, I thought the first 6 figures of the 1st number can be copied and those 6 figures pasted before the other two figures after the backslash. Auto Merged Post Until 24 Hrs Passes;sorry, pressed OK too quickly. The problem is that there are sometimes 4 numbers in the cell, sometimes 6 and once three. I would like Excel to complete all the numbers in the cell and then move on to the cell underneath it and so on. Also, I would like each number to have it's own cell.
I have a string of text in cell A2. In cell B2 of my spreadsheet is a formula that calculates a number based on the text string in cell A2.
I want to write a VBA loop that removes a single character from the cell A2 string, then calculate the new value in cell B2. I want this loop to continue until the value in B2 falls below a set value (in this case 60).
My code so far Sub trim_text() Dim mytext As String Dim myanswer As Integer mytext = Range("A2") myanswer = Range("B2") Do While myanswer > 60 mytext = (Right(mytext, Len(mytext) - 1)) Loop End Sub
This obviously does not work. In my excel table I have a formula in cell B2 to calculate "myanswer" will this work, or does that code have to be placed into the VBA code?
if a cell contains character A THEN multiply by cell B * 0.02,if a cell contains character B THEN multiply by cell B * 0.05,if a cell contains character C THEN multiply by cell B * 0.010
i have a column that is 1900 long and i need to add a "comma" to the end of everything in each cell in that column. How do i go about this? so at the moment it look like this:
I want to test a cell for the type of value as 678/256 or 345/872/098/987 etc. The common character in each would be the "/". First, I need to check the cell for this, then take the first number and compare it to an integer(if it is <> , or = to). I hope I am clear with my situation.
I'm using the hidden-row trick to auto-fill cells beneath the hidden rows.
For this to work, every cell that is to be auto-filled in must have a character in every cell above it.
How can I make sure that my unfilled cells always have a character in them? If a user deletes the contents of the cell, I want a single character to stay in the cell (I want a backslash). This way, there will always be either a backslash, or the user-filled data in the cell. It can never be empty.
I am using an exported dbf from filemaker pro. This is an established dbf, with over 2,000 sku's in it. Here is what I want to do.
I am using Indata and InDesign to create a catalog. I need for excel to pull the first character from a cell and put it in another cell. i.e.
I have a dbf where I have author last name, and title of book. I need for excel to pull the first character of each of these fields and put them in their own cell/column. This will allow me to use these new columns to make the " headers" for my InData/InDesign doc.
I enter for example in a cell : 0625-C0/01 sometime 0 is entered as O a letter and not zero.Is there a way to ensure that only 0 (zero) is allowed in that string using data validation rules.
Essentially what I'm trying to accomplish is import a file from Quickbooks and determine whether it was a Credit Card, Check or Invoice based on the account number.
For example:
45-12345 should return the value CC in an adjacent cell because it contains the "-" character. I0123456 should return the value INV in an adjacent cell because it contains the "I" character. 01234567 should return the value ACH in an adjacent cell because it doesn't contain either character.
I tried using VLookup, but I can't figure out how to write a formula for when it just contains a character, only if it matches it or is text/number.
I have a requirement... which need to search from a cel if it march then replace with below name. When user gives a selection screen, month displays in a cell A1.
For example: If this cel (A1) is jan then it should replace with Jan, if mar then replace with mar, if MAI then replace with MAY, if sep then replace with SEP, if OKT then replace with OCT.... and so on... or It search the cell A1 for MAI, then replace with MAY & also should search for if A1 is OKT then replace OCT, & also if A1 is DZC then replace with DEC.
I know the function of ....
[=IF(ISNUMBER(SEARCH("*MAI*",A1)),"MAY",A1)] =
This formula brings me only 1 search, but I need 3 search if match replace with respective character. this should search for OKT & DZC ALSO....
present - new
JAN - JAN FEB - FEB MAR - MAR APR - APR MAI - MAY JUN - JUN JUL - JUL AUG - AUG SEP - SEP OKT - OCT NOV - NOV DZC - DEC
I'm trying to speed up some work on an excel sheet. The sheet converts degrees latitude and longitude to Northing and Easting coordinates, but right now we have to type them in directly.
For example, the degrees would be 81.0056 and I want to reference just the .0056 from the cell that contains the whole 81.0056 degrees. Is there any way to just reference character place three through seven of that cell? All I'll need it to do is copy it over, the rest of the program will convert it for me.
I am trying to create a button that when clicked it will add a character to the existing cell. Eg if cell had LDs and I click button I like it show LDs₂
I'm trying to use Excel 2003 macros for the first time and am very frustrated by it's recorder function. I've used several standalone TSR macro recorders several years ago and they were much easier but certainly not as feature rich.
I have a spreadsheet that I've been using for a couple of years where I have manually entered data. My company has recently started to dump data into an Excel sheet but instead of pure numeric or date values being used they are extracting the values with the ' character starting the value. I want to strip this ' character.
What I do is select the cell I want to edit and invoke the macro. Then press {F2} to edit the contents of the cell, {Home} to move to the left, {Del} to delete the first character - the apostrophe, and {Enter} to complete the edit and move down one cell.
Using the recorder captures the following. Unfortunately it doesn't simply delete the first character, it copies the value of the previous cell to the next cell when I invoke the macro again.
Is there any neat little way of preventing a character say '=' from been entered in a cell, kinda similar to the validation but for a 'dont allow' function.
Cells A1:A5 all have a vlookup formula that will pull one of the following into it:
1. The word "NONE" 2. #N/A error since it doesn't exist in the table 3. A text value that has the format 13.55.46.91
I want a formula that will look at these 5 cells and give me #3. That #3 value can only appear once in the 5 cells in any of those 5. The other 4 cells will contain either 1 or 2.
3 always has length equal to 11. It always has periods in those places. The digits do change.