Number/Word Splicer for Google Spreadsheets - google-sheets

I am trying to make a google spreadsheet that splits a word or string of numbers in half and puts the back half in front of the first half in a new column. However, I am new to this who process and so I came here to ask for help. I originally tried macros but couldn't get them to copy and paste information from columns.
Here is the basic idea:
The spreadsheet cuts the number or word in half putting the back in front.
Thanks for everyone's time.

In case of an odd number of chars, ROUNDUP must be used in RIGHT or LEFT function:
=ArrayFormula(RIGHT(A1:A,ROUNDUP(LEN(A1:A)/2)) & left(A1:A,LEN(A1:A)/2))

I think your problem shall be solved using the following code:
=CONCATENATE(right(A2,len(A2)/2),LEFT(A2,len(A2)/2))

Related

Extracting Wanted Data from the Raw Cell

I have been trying to extract the required data from a single cell and I have tried using some common formulas but its not working for all the cells exactly.
I would appreciate your help in this regards.
Google Sheet
Formula 1
=LEFT(A2,FIND(C2,A2)-1)
Formula 2
=SUBSTITUTE(TRIM(SUBSTITUTE(SUBSTITUTE(LEFT(RIGHT(A2,len(A2)-FIND(") ",A2)),6),")",""),"(","")),"|","")
I duplicated your tab and entered the following formula in cell E2:
=ArrayFormula(ifna(regexextract(A2:A,"\[\s\]\s(.+)?\s\((.+)\)")))
Explanation
\[\s\]\s - find [ ]
(.+)?\s\( - extract everything after it until the next occurence of (
(.+)\) - extract everything after the above ( and before the next occurence of )
EDIT: The first time I've tried #ztiaa answer it didn't work... don't know why. I kept investigating REGEX and gave it another try, and it did... You'd probably prefer that. I leave my answer just as a memory, and if it's useful for someone else in another scenario
Honestly, I don't handle regex as #ztiaa, but what I've found difficult about your example is that there are sometimes more than one opening parenthesis... that's why I looked for a way of finding the last appearance of "(". You can learn more about this workaround here
I changed "#" with "CUT HERE" in my example, just in case "#" may appear in your example. With that in mind, you can set these two formulas:
=ArrayFormula(IF(A3:A="","",MID(A3:A,5,FIND("CUT HERE",SUBSTITUTE(A3:A,"(","CUT
HERE",LEN(A3:A)-LEN(SUBSTITUTE(A3:A,"(",""))))-5)))
=arrayformula(if(A3:A="","",mid(A3:A,FIND("CUT HERE",SUBSTITUTE(A3:A,"(","CUT
HERE",LEN(A3:A)-LEN(SUBSTITUTE(A3:A,"(",""))))+1,FIND(")",A3:A,FIND("CUT
HERE",SUBSTITUTE(A3:A,"(","CUT
HERE",LEN(A3:A)-LEN(SUBSTITUTE(A3:A,"(",""))))+1)-FIND("CUT
HERE",SUBSTITUTE(A3:A,"(","CUT
HERE",LEN(A3:A)-LEN(SUBSTITUTE(A3:A,"(",""))))-1)))
The second one is really long because it has to find the amount of characters in between brackets. But it appears to work. Probably there's a more ellegant way with Regex, I repeat :)
Look in J and K of your example:

Replace user created blanks with 0's

I made a binary calculator with bitwise functions (bitand, bitor, bitxor, ect.) in google sheets (yes I am aware that there are built in functions to do this, this seemed more fun). It is an 8 bit calculator, and I currently have addition and subtraction implemented. Multiplication is planned, but seems way too hard at the moment
One of the things I came across is once a calculation is done, the user has to manually 0 out the addends/minuend and subtrahend one digit at a time. I would like to optimize this process.
I can easily create a script that will input 0 into all the cells and hook that up to a button. I have a feeling that's the route I'm going to have to go. But I want to challenge myself in making cool stuff, so I want the coolest solution.
My question is: is there a way I can do this without a script attached? I've been experimenting with ARRAYFORMULA and VLOOKUP, but I don't have a clear answer yet.
Expected behavior:
User inputs their calculation. User records the answer. User selects both 8 bit binary numbers (currently residing in A1:H2) and presses backspace. Google Sheet automatically translates those blank cells to 0's.
take a look into custom internal formatting. any text can be converted to "0"
then see shifted arrays:
={"", "x"}
formula from G9 will print "0" into H9. also, you can anytime enter value in H9 to "overwrite" the zero and after you don't need the entered value you just clear it with backspace or delete key and it will be filled with "0" again.
also, note that after you enter value in H9, G9 will error out and such error cant be suppressed so see hidden cells:
not sure if it's cool enough but it works (with compromises)

=LEN Function in Google Sheet not working corretly

I have a column with lots of rows containing text. I want to highlight cells with over an x-amount of characters, but how? The code I'm using in combination with 'Conditional Formatting' is not working all the time. Sometimes it highlights text over the x amount and sometimes it doesn't, so there is something I'm doing wrong here. The x-amount in the example below is: 300.
you may also need to lock it like:
=LEN(E$1:E$170)>300
Silly me... I found the answer myself. I need to put in the same range in the formula as well. Formula with the range E1:E170 needs to be: =LEN(E1:E170)>300

How do i stop google sheet from auto-calculation?

I have a sheet that will record delivery information. However one of the record we have right now have a barcode that start with equal (=) symbol(=00000-00). So whenever we fired our barcode reader at it. it return as 5 digits number (10000) with minus calculation instead of our office-use 7 digits number format. (10077-77)
From what i know, In excel you can turn auto-calculation off as simple as turning format into text for use manual setting for calculation. However that doesn't seems to be the case here for Google Sheet. Is there any workaround for this? I tried =right(B2, len(B2)-1) but all it does is removing first number out and ignore equal symbol entirely.
I believe the best workaround is to treat it like a string:
You also have the option of displaying formulas:
Yet if you use a value of =0000-00 or something with starting zeros, it will not display the zeros:

How do I increment a string value in Google Spreadsheet?

Long time Lurker reporting in! My issue is I'm not sure how to increment an Item no. It follows this format : LK0001 the row below it will be LK0002, below that LK0003 and so on I'm not sure how to automate this process, as you can tell I'm fairly new to google spreadsheets Sorry if it's already answered , I just can't seem to find it! Thanks!
Weej
First of all, I would suggest using the following ID build-up:
LK1000
This way characters (LK) can be separated from integers (1000). Otherwise you would face the problem, that if you increase LK0009 by 1 it becomes LK00010 and not LK0010
ID's need to be "hard coded", meaning =CONCAT or =A1+1 or =MAX(A:A)+1 are not allowed.
Either go by typing LK+max. number and use the ID as a text or go for the integers and use CONCAT when needed.
If you chose to go with the integers, you can easily increment them by doing this:
and then dragging it downwards, yielding:
I've prepared an example for you: How do I increment a string value in Google Spreadsheet?

Resources