You are reading the article How To Use Excel Hacks With Keyboard Shortcuts? updated in December 2023 on the website Tai-facebook.edu.vn. We hope that the information we have shared is helpful to you. If you find the content interesting and meaningful, please share it with your friends and continue to follow and support us for the latest updates. Suggested January 2024 How To Use Excel Hacks With Keyboard Shortcuts?
Excel Hacks (Table of Contents)
Start Your Free Excel Course
Excel functions, formula, charts, formatting creating excel dashboard & others
Introduction to Excel Hacks How to Use Excel Hacks?Here we discuss the list of most of Microsoft Excel’s significant shortcut buttons and main combinations with examples.
You can download this Excel Hacks Template here – Excel Hacks Template
Example #1 – Use of Important Keyboard Shortcuts1. Selection of Data
2. Column Width Size Adjustment
3. Insertion of Date or Time or Comments in Excel
In some scenarios, we need to enter today’s date & time; instead of looking into the calendar or time at the bottom, we can use the below-mentioned shortcut key.
For date: CTRL + ; or For time: SHIFT + CTRL + ;
4. Addition of a New Line in a Cell
Suppose you are entering address details, and you need to add multiple lines of data in the same cell; for that, you need to enter short cut key “Alt + Enter”, it will move the cursor down so that you can enter or type the text in the next line.
5. Addition or insertion of multiple columns or rows
6. Autosum the Selected Data Range
Suppose I have a numeric data range, so I want to do a sum up for that data range. To perform this task faster, you need to select the data range.
After pressing the “ALT key and Enter”, it will give the range’s total value.
7 Addition of Cell Border
Here we want to add a cell border across the data range.
After pressing on “Ctrl + Shift + &”, cell borders are automatically added.
8. Number Formatting
You can select a date range if you want a dollar sign displayed before each number.
9. Make a Copy of your Worksheet in the Same Workbook
Suppose you have a quarterly report in sheet 1 of a workbook, so you need to re-create it from scratch for the next quarter’s sales data, which is very difficult and time-consuming; you can use the “Move or Copy” option under the worksheet.
10. Freeze the Top Row
11. Addition of Filter for a Data Range
Suppose you want to filter data in a worksheet.
Example #2 – Usage of Important Formulas1. To Count Blank Cells in the Data Range with the help of the COUNTBLANK Formula
Here in the below-mentioned example, I want to count a blank cell in the data range (A2 to A7).
2. To Count Only Text Value in the Data Range with the help of COUNTA Formula
In the below-mentioned example, I want to count only a cell containing text values in the data range (A12 To A17); I can use the combination of the count formula, i.e., the COUNTA formula will count everything, including text & numeric value.
After using the COUNT formula, it will count only the numbers, i.e., = COUNTA (A2:A7)-COUNT (A2:A7). The difference between these two will result in an output value of 2.
3. To know the Formula Text or which formula you have used
If you know which formula is present in a cell, you can check it out with the help of the =FORMULATEXT(cell reference) formula. Here I have used cell A8 (as a cell reference).
After using the formula, the output is shown below.
4. To Pullout Only Decimal Values with the help of MOD & INT Function
I have a cell value of 98.23 in cell “A2” I want only the decimal portion in cell “B2”; to get this, I can use the formula MOD & INT function.
After using the formula, the output is shown below.
Things to RememberWith the help of the symbols or arithmetic operators explained in the above examples in user or predefined Excel formulas, you can quickly perform various required calculations between numbers, cells, entire rows, and columns or ranges of cells.
Recommended ArticlesThis is a guide to Excel Hacks. Here we discuss How to Use Excel Hacks with Excel shortcut keys, practical examples, and a downloadable Excel template. You can also go through our other suggested articles –
You're reading How To Use Excel Hacks With Keyboard Shortcuts?
How To Use Excel Vba Instrrev With Examples?
VBA InStrRev Function
Knowing the occurrence of a string in another string can be very handy while working with day to day data. Obviously, we can do it manually by calculating the occurrence of the string in another string but that would the task very hefty. So to make it easier we have a function in VBA which is known as INSTRREV which is used to find the occurrence.
As explained above, INSTRREV in Excel VBA is used to find an occurrence of a string in another string. This function finds the first occurrence of a string in the target string and returns the value. Now we have to remember that as it gives the occurrence of the string so the returned value is numeric. Also as it is a comparison function so like other functions in VBA there are three basic comparisons methods.
Watch our Demo Courses and Videos
Valuation, Hadoop, Excel, Mobile Apps, Web Development & many more.
Syntax of InStrRev in Excel VBAThe syntax for VBA InStrRev function in excel is as follows:
Now let us break down the syntax and learn about it, String is the main string from where we want to find the occurrence of a substring, Start is the numeric occurrence we provide to the string. If no start parameter is provided the function starts looking a string from the end of it. And compare is the comparison method we provide to the function. There are three types of comparison for this function:
To use Option Compare which is (-1). It is also known as VbUseCompareOption.
To use Binary Compare which is (0). It is also known as VbBinaryCompare.
To use Text Compare which is (1). It is also known as VbTextCompare.
Again if none of the compare options is provided then the function automatically considers it as a binary compare.
Now let us use this function in a few examples and look at how to use this function.
How to Use Excel VBA InStrRev?Now let us try with some examples on VBA InStrRev in Excel.
You can download this VBA InStrRev Excel Template here – VBA InStrRev Excel Template
Example #1 – VBA InStrRevStep 2: Once we enter the VB editor we can see in the header section, there is an option of insert. Insert a new module from that option as shown below.
Step 3: Now let us start our subprocedure in the module as shown below.
Code:
Sub
Sample()End Sub
Step 4: Now declare a variable as an integer which will hold the output value of the function for us.
Code:
Sub
Sample()Dim
AAs Integer
End Sub
Step 5: Now in the variable use the INSTRREV function to find the occurrence of “ “ in the string “ I am a Good Boy” as follows.
Code:
Sub
Sample()Dim
AAs Integer
A = InStrRev(" I am a Good Boy", " ")End Sub
Step 6: Now display the value stored in variable A using the msgbox function.
Code:
Sub
Sample()Dim
AAs Integer
A = InStrRev(" I am a Good Boy", " ") MsgBox AEnd Sub
Step 7: Let us execute the above code to get the following result.
We get the result as 13 because we did not provide the start position to the function so it automatically calculated the occurrence from the end and so the result. It is found that “ “ is on the 13th position of the string when we search it from the end.
Example #2 – VBA InStrRevIn the above example, we did not provide any start position to the string. Let us provide this time in this example. Let us find out from the second position where does the “ “ occurs in the string.
Step 1: Insert a new module from that option as shown below.
Step 2: Let us again define a subprocedure for our second example.
Sub
Sample1()End Sub
Step 3: Declare another integer variable for the example.
Code:
Sub
Sample1()Dim
AAs Integer
End Sub
Step 4: Now in Variable A let us find the occurrence of the “ “ from the second position using the INSTRREV function as follows.
Code:
Sub
Sample1()Dim
AAs Integer
A = InStrRev(" I am a Good Boy", " ", 2)End Sub
Step 5: Now use msgbox function to display the value stored in A.
Code:
Sub
Sample1()Dim
AAs Integer
A = InStrRev(" I am a Good Boy", " ", 2) MsgBox AEnd Sub
Step 6: Now run the above code to find out the below result as shown below,
We get 1 as a result as we count 2 we get I and after one position we get the occurrence of “ “.
Example #3 – VBA InStrRevIn this example let us use the compare methods. We have a string “ India is the Best” and let us find the string “E” using both text and binary compare methods.
Step 1: In the same module 1, write another subprocedure for example 3.
Code:
Sub
Sample2()End Sub
Code:
Sub
Sample2()Dim
A, BAs Integer
End Sub
Step 3: In variable A let us use the INSTRREV function with the text comparison as follows.
Code:
Sub
Sample2()Dim
A, BAs Integer
A = InStrRev("India is the Best", "E", , vbTextCompare)End Sub
Step 4: Now display the value stored in A using the msgbox function.
Code:
Sub
Sample2()Dim
A, BAs Integer
A = InStrRev("India is the Best", "E", , vbTextCompare) MsgBox AEnd Sub
Step 5: In variable B let’s use the binary comparison for the same string as follows.
Code:
Sub
Sample2()Dim
A, BAs Integer
A = InStrRev("India is the Best", "E", , vbTextCompare) MsgBox A B = InStrRev("India is the Best", "E", , vbBinaryCompare) MsgBox BEnd Sub
Step 6: Execute the above code to find the first result stored in variable A which is as follows.
Step 7: Press OK to see the result stored in variable B.
We get 0 as the result for binary compare because in our string “e” is present not “E”. In binary values both of these are different. So if a value is not found in the string we get a result as 0.
Things to Remember
The value returned by this function is numeric.
If the substring is not found the value returned is 0.
Start position is optional. If it is not provided, by default function search the occurrence from the end of the string.
The comparison methods are also optional.
Recommended ArticlesThis is a guide to VBA InStrRev. Here we discuss how to use Excel VBA InStrRev along with practical examples and downloadable excel template. You can also go through our other suggested articles –
87 Indesign Keyboard Shortcuts (Updated 2023)
There are very few other tools that have such a profound impact on how quickly you can complete your projects, and they really help to minimize the delay between thinking of what you want to do and it actually happening.
Once keyboard shortcuts become second nature to you, you’ll wonder how you ever got by without them!
Note: because InDesign is available on both Mac and PC, the keyboard shortcuts sometimes vary between the two versions.
21 Essential InDesign Shortcuts
These are some of the most common shortcuts that you’ll use day in and day out during your InDesign layout work. If you’re not already using these shortcuts, you should be!
Place
Command + D / Ctrl + D
The Place command is used to add graphics and other external files to your InDesign layout, so this is arguably the most useful shortcut to learn.
Duplicate
Command + Option + Shift + D / Ctrl + Alt + Shift + D
The Duplicate command saves you from using Copy and then Paste to duplicate any object within your document.
Paste in Place
Command + Option + Shift + V / Ctrl + Alt + Shift + V
Once you’ve copied an item to the clipboard, you can change pages and then paste the object into the same location as on the original page.
Undo
Command + Z / Ctrl + Z
Without a doubt, this is my favorite keyboard shortcut. It’s useful across almost every single app ever created on any operating system.
Redo
Command + Shift + Z / Ctrl + Shift + Z
When used after the Undo command, Redo allows you to re-perform the same action. This makes it useful for comparing the before and after results of a formatting change.
Group
Command + G / Ctrl + G
The Group command unites multiple different selected design elements into a single group so that they can be modified as a whole.
Ungroup
Command + Shift + G / Ctrl + Shift + G
The Ungroup command breaks apart a group so that objects can be modified individually.
Lock
Command + L / Ctrl + L
The Lock command prevents additional changes to the selected element.
Unlock All on Spread
Command + Option + L / Ctrl + Alt + L
This unlocks all the elements on the current spread (pair of pages).
Find/Change
Command + F / Ctrl + F
The Find/Change command is used to search and modify text within InDesign. GREP searches can also be applied using this command.
Show Hidden Characters
Command + Option + I / Ctrl + Alt + I
If your text is behaving unexpectedly, there may be a hidden character causing issues. Show Hidden Characters will display a guide character for line breaks, paragraph breaks, tabs, and other parts of a text frame that are usually hidden.
Fit Frame to Content
Command + Option + C / Ctrl + Alt + C
Instantly resizes the object frame to match the size of the contents.
Fit Content to Frame
Command + Option + E / Ctrl + Alt + E
Scales the object contents of a frame to match the frame boundaries.
Text Frame Options
Command + B / Ctrl + B
Opens the Text Frame Options dialog to customize the settings for the selected text frame(s).
Go to Page
Command + J / Ctrl + J
Jumps to a specific page within the current document.
Zoom In
Command + = / Ctrl + =
Enlarges the view within the main document window.
Zoom Out
Command + – / Ctrl + –
Shrinks the view within the main document windows.
Fit Page in Window
Command + 0 / Ctrl + 0
Automatically adjust the view magnification to display the full dimensions of the currently selected page.
Preview Screen Mode
W
This is one of the few shortcuts that is the same on Mac and PC, used for cycling between Normal and Preview screen modes. The Preview screen mode hides all guides, grids, margins, and frame borders to give you a more accurate look at the final look of your document.
Export
Command + E / Ctrl + E
Saves your InDesign file in a specific format such as PDF or JPG.
Package
Command + Option + Shift + P / Ctrl + Alt + Shift + P
The Package command copies all linked external files used in the document (including fonts, where applicable) to a central location, while also saving PDF, IDML and INDD versions of your current document.
35 InDesign Tool Shortcuts
Learning the keyboard shortcuts for your most commonly used InDesign tools can really speed up your workflow. Here’s the complete list of shortcuts found in the Tools panel, from top to bottom.
You might not need all of them, but they’re usually the simplest shortcuts to remember. Fortunately, Tools panel shortcuts are the same on Mac and PC versions of InDesign, so your reflexes will stay useful no matter which operating system you’re using.
Selection Tool
V / Escape
The Selection tool is used to select and reposition elements throughout your document.
Direct Selection Tool
A
The Direct Selection tool allows you to select and adjust anchor points on frames, objects, clipping masks, and more.
Page Tool
Shift + P
Used to modify the page size of your currently selected page(s).
Gap Tool
U
The Gap tool specifies the desired and minimum amount of space between objects in a flexible layout.
Content Collector Tool
B
This tool allows you to duplicate and reposition multiple objects at the same time.
Type Tool
T
The Type tool is used to create text frames, place the text cursor, and select text.
Type on a Path Tool
Shift + T
The Type on a Path tool allows you to convert any vector path into a text frame.
Line Tool
The Line tool draws perfectly straight lines. Shocking, I know!
Pen Tool
P
The Pen tool allows you to create freeform lines and shapes by placing anchor points in sequence.
Add Anchor Point Tool
+
Adds an anchor point to an existing path, shape, or frame.
Delete Anchor Point Tool
–
Deletes an anchor point from an existing path, shape, or frame.
Convert Direction Point Tool
Shift + C
Toggles an anchor point from a sharp corner into a curve.
Pencil Tool
N
The Pencil tool draws flowing lines that are automatically converted into a vector path.
Rectangle Frame Tool
F
This tool draws a rectangular placeholder frame.
Rectangle Tool
M
This tool draws a rectangular vector shape.
Ellipse Tool
L
This tool draws an elliptical vector shape.
Scissors Tool
C
The Scissors tool divides shapes into multiple separate parts.
Free Transform Tool
E
The Free Transform tool can be used to apply any of InDesign’s transform operations to the selected object.
Rotate Tool
R
Rotates the selected object.
Scale Tool
S
Scales the selected object.
Shear Tool
O
Applies shear to the selected object.
Gradient Swatch Tool
G
This tool allows you to control the location and positioning of a gradient fill within the selected object.
Gradient Feather Tool
Shift + G
The Gradient Feather tool allows you to fade an object to transparency.
Color Theme Tool
Shift + I
Eyedropper Tool
I
The Eyedropper tool is used to select a specific color from an object or image for use as a stroke or fill color.
Measure Tool
K
Measures the distance between two points in your chosen unit.
Hand Tool
H
The Hand tool allows you to move your document around the main document window.
Zoom Tool
Z
The Zoom tool allows you to quickly zoom in and out of your document in the main document window.
Default Fill / Stroke Color
D
Sets the Fill and Stroke swatches in the Tools panel to the default of black stroke and empty fill. If an object is selected, it will have the default Fill and Stroke applied.
Toggle Fill / Stroke Selection
X
Toggles between the Fill swatch and the Stroke swatch in the Tools panel.
Swap Fill / Stroke Color
Shift + X
Swaps the Fill and Stroke colors.
Formatting Affects Container / Formatting Affects Object
J
Toggles whether formatting changes will apply to the containing frame itself or the object within the frame.
Apply Color
,
Applies the last-used color to the selected object.
Apply Gradient
.
Applies the last-used gradient to the selected object.
Apply None
/
Removes all colors and gradients from the selected object.
17 InDesign Panel Shortcuts
These shortcuts are used to display or hide the relevant InDesign panel.
Control
Command + Option + 6 / Ctrl + Alt + 6
Pages
Command + F12 / F12
Layers
F7
Links
Command + Shift + D / Ctrl + Shift + D
Stroke
Command + F10 / F10
Color
F6
Swatches
F5
Character
Command + T / Ctrl + T
Paragraph
Command + Option + T / Ctrl + Alt + T
Glyphs
Option + Shift + F11 / Alt + Shift + F11
Paragraph Styles
Command + F11 / F11
Character Styles
Command + Shift + F11 / Shift + F11
Table
Shift + F9
Text Wrap
Command + Option + W / Ctrl + Alt + W
Align
Shift + F7
Info
F8
Preflight
Command + Option + Shift + F / Ctrl + Alt + Shift + F
14 Document Views & Guides Shortcuts
These shortcuts will help you navigate through your document and control how it displays.
View Actual Size
Command + 1 / Ctrl + 1
First Page
Command + Shift + Up Arrow / Ctrl + Shift + Numpad 9
Previous Page
Shift + Up Arrow / Shift + Numpad 9
Next Page
Shift + Down Arrow / Shift + Numpad 3
Last Page
Command + Shift + Down Arrow / Ctrl + Shift + Numpad 3
Next Spread
Option + Down Arrow / Alt + Numpad 3
Previous Spread
Option + Up Arrow / Alt + Numpad 9
Show / Hide Rulers
Command + R / Ctrl + R
Command + Option + Y / Ctrl + Alt + Y
Show / Hide Guides
Command + ; / Ctrl + ;
Lock / Unlock Guides
Command + Option + ; / Ctrl + Alt + ;
Enable / Disable Smart Guides
Command + U / Ctrl + U
Show / Hide Baseline Grid
Ctrl + Alt + ‘
To clarify, that’s an apostrophe!
Show / Hide Document Grid
Command + ‘ / Ctrl + ‘
To clarify again, that’s also an apostrophe!
How to Find Keyboard Shortcuts in InDesign
In the Product Area dropdown menu, select the aspect of InDesign that is most closely related to the command you want to find. The listed categories can be a bit vague, so don’t feel bad if you have to look through several areas to find the right location.
Select the appropriate command from the Commands section, and InDesign will display any currently active shortcuts.
While InDesign comes with plenty of helpful predefined shortcuts, you can also create customized keyboard shortcuts to speed up your workflow.
You can also create custom sets of shortcuts for different usages, although I’ve never found it necessary to do this. That being said, Adobe has helpfully included keyboard shortcut sets that replicate the shortcuts used by competing page layout apps so that newly-converted InDesign users can stick to the shortcuts they’re used to from their old app.
A Final Word
If you’re feeling a bit overwhelmed by all the InDesign keyboard shortcuts listed in this post, then don’t feel bad – there is a lot to take in! Focus on learning the keyboard shortcuts for your most common InDesign tasks, and you’ll quickly begin to see how much easier they are to complete.
As you grow more comfortable, you can add more shortcuts to your repertoire, and eventually, you’ll be navigating InDesign like a pro on a deadline.
Enjoy your shortcuts!
How To Use Shortcuts To Change Wallpapers Automatically On Iphone
iOS 16.2 dev beta was just released to the public, and many enthusiasts have been scrambling to find all the new features and changes in iOS 16.2. A surprising addition comes to the Shortcuts app, where you can now add custom shortcuts to change and switch your wallpaper automatically.
The Shortcuts app has been a godsend for many users as it opens up new possibilities and new ways to perform tasks automatically in the background with a single tap. Apple took this a step further by adding automation which even takes away the need to tap an icon to perform your action.
The Shortcuts app now has additional actions to choose and set wallpapers on your iPhone, which you can use to change wallpapers automatically. Here’s how you can do that on your device.
Related: How to Switch Between Multiple Lock Screens Automatically on iPhone
How to use Shortcuts to change your wallpaper automatically
You will need iOS 16.2 update (available as dev beta on October 27, 2023) or higher to change your wallpapers automatically using Shortcuts. Here’s how you can set custom shortcuts once you’ve updated your iPhone as required above.
Method 1: Change and switch between existing wallpapers automatically
If you have multiple wallpapers set up on your iPhone, then you can create shortcuts to automatically switch to a specific one, depending on your preferences. You can then add If variables or automation to further automate this process at your discretion. Use the steps below to help you along the way.
Open the Shortcuts app on your iPhone and tap the + (Plus) icon in the top right corner.
Tap New Shortcut and select Rename.
Name your shortcut based on your preferences and tap Done on your keyboard.
Now tap Add Action.
Use the search bar at the top to search for Switch Between Wallpapers.
Tap and select the same once it shows up in your search results.
Tap Wallpaper.
Now tap and select an existing wallpaper you wish to switch to.
Tap Done.
You can now add further variables and automate your shortcut further as needed. Tap Done in the top right corner once finished.
And that’s it! Your wallpaper will now automatically change to the chosen wallpaper once the shortcut is triggered on your iPhone.
Method 2: Set a copied photo as your wallpaper from your clipboard
You can also use a copied custom photo to be set as your wallpaper whenever you trigger a shortcut. Here’s how you can do that on your iPhone.
Open the Shortcuts app on your iPhone and tap the + (Plus) icon in the top right corner.
Tap New Shortcut and select Rename.
Name your shortcut based on your preferences and tap Done on your keyboard.
Now tap Add Action.
Tap and use the searchbar to search for Set Wallpaper Photo.
Tap and select the same from your search results.
Now tap Default Wallpaper if you wish to set the photo as the wallpaper for an existing one you have already created. Leave this option alone if you wish to set the photo as your current default wallpaper.
Tap and select Image.
Now select Clipboard. This will allow you to set a copied image as your wallpaper.
Tap Lock Screen and Home Screen.
Choose one of the options based on your preferences. You can select both the lock screen and home screen to use the same wallpaper everywhere on your iPhone. Ask Each Time will allow you to choose whether you wish to use the wallpaper on your lock screen or home screen.
Lock Screen
Home Screen
Ask Each Time
Tap Done once you’ve made your choice.
Add any additional variables or conditions based on your preferences to automate this process a step further. Tap Done once finished.
Now when this shortcut is triggered, the wallpaper won’t set automatically, but instead, you will be taken to the add new wallpaper screen if you choose the lock screen as your choice. Proceed to customize your lock screen and tap Done when finished.
Additionally, when selecting Home Screen, the wallpaper will automatically be set for your home screen and lock screen without any prompt. We suspect this is a bug and not the intended behavior. It should get fixed in the coming beta releases and should get polished by the time iOS 16.2 Release Candidate is released.
And that’s how you can set a copied photo as your wallpaper automatically on iOS 16.2 and higher.
Related:
How To Use Excel Vba Split Function?
VBA Split Function
As the name suggests, a Split is a function that splits strings into different parts. We have many such functions in excel worksheets, such as a left-right and mid function to do so. But when we need any string to differentiate in parts, we use a Split function in VBA. It is one of the best functions in VBA to perform different types of operations on strings.
The split function is basically a substring function that takes a string as an input and gives another string as an output. The only difference between the other substring function like left, right, and mid and split function is that the LEFT, RIGHT & MID function just take one string as an input or argument and returns one string as an output while the SPLIT function returns an array of strings as output.
Watch our Demo Courses and Videos
Valuation, Hadoop, Excel, Mobile Apps, Web Development & many more.
Formula for Split Function in Excel VBAVBA Split function has the following syntax:
Given below are the arguments for the VBA split function first:
Expression as String: This is a mandatory argument in VBA Split function. Expression as string refers to the string we want to break into parts.
Delimiter: This is an optional argument. It is the character that is used to break strings into parts. But if we do not provide any delimiter, VBA treats space “ “ as default delimiter.
Limit: This is also an optional argument. Limit means the maximum number of parts we want to do of a string. But again, if we do not provide a limit to the function, VBA treats it as default -1, which means the string will break apart each time there is a delimiter in the string.
Compare: This final argument is also an optional argument. Compare is a method that is described as one of the two below:
Either it is 0, which means Split will perform a binary comparison which means every character should match itself.
Or it can be 1, which means the Split function will do a textual comparison.
Everything will be clear in a few examples. But let me give a very basic example first of what this function does. Suppose we have an input string as ANAND IS A GOOD BOY. The split string will break it into parts, each word separately. We can also use the Split function to count a number of words in a string, or we can use it to output only a certain amount of words in a given string.
How to Use Excel VBA Split Function?We will see how to use a VBA Split Excel function with few examples:
You can download this VBA Split Excel Template here – VBA Split Excel Template
VBA Split Function – Example #1How about we use the above string ANAND IS A GOOD BOY with split function.
Note: In order to use a Split function in VBA, make sure that the developer option is turned on from File Tab from the options section.
Step 3: When the code window appears, declare a sub-function to start writing the code.
Code:
Sub
Sample()End Sub
Step 4: Declare two variables arrays and one as strings A & B.
Code:
Sub
Sample()Dim
AAs String
Dim
B()As String
End Sub
Step 5: Store the value of the string in A.
Code:
Sub
Sample()Dim
AAs String
Dim
B()As String
A = "ANAND IS A GOOD BOY"End Sub
Step 6: In the B array, store the value of A using the split function as shown below.
Code:
Sub
Sample()Dim
AAs String
Dim
B()As String
A = "ANAND IS A GOOD BOY" B = Split(A)End Sub
Step 7: Use For Loop to break every string.
Code:
Sub
Sample()Dim
AAs String
Dim
B()As String
A = "ANAND IS A GOOD BOY" B = Split(A)For
i =LBound
(B)To UBound
(B) strg = strg & vbNewLine & "String Number " & i & " - " & B(i)Next
iEnd Sub
Step 8: Display it using the Msgbox function.
Code:
Sub
Sample()Dim
AAs String
Dim
B()As String
A = "ANAND IS A GOOD BOY" B = Split(A)For
i =LBound
(B)To UBound
(B) strg = strg & vbNewLine & "String Number " & i & " - " & B(i)Next
i MsgBox strgEnd Sub
Step 9: Run the code from the run button provided below.
We get this as output once we run the above code.
VBA Split Function – Example #2We will now try to take input from a user and split the string into parts.
Step 3: In the code window, declare a sub-function to start writing the code.
Code:
Sub
Sample1()End Sub
Step 4: Declare two variables, one as String and one as an Array String.
Code:
Sub
Sample1()Dim
AAs String
Dim
B()As String
End Sub
Step 5: Take the value from the user and store it in the A using the Inputbox function.
Code:
Sub
Sample1()Dim
AAs String
Dim
B()As String
A = InputBox("Enter a String", "Should Have Spaces")End Sub
Step 6: Store the value of A in Array B using the Split Function.
Code:
Sub
Sample1()Dim
AAs String
Dim
B()As String
A = InputBox("Enter a String", "Should Have Spaces") B = Split(A)End Sub
Step 7: Use For Loop to break every string.
Code:
Sub
Sample1()Dim
AAs String
Dim
B()As String
A = InputBox("Enter a String", "Should Have Spaces") B = Split(A)For
i =LBound
(B)To UBound
Next
iEnd Sub
Step 8: Display it using the Msgbox function.
Code:
Sub
Sample1()Dim
AAs String
Dim
B()As String
A = InputBox("Enter a String", "Should Have Spaces") B = Split(A)For
i =LBound
(B)To UBound
(B) strg = strg & vbNewLine & "String Number " & i & " - " & B(i)Next
i MsgBox strgEnd Sub
Step 9: Run the code from the run button. Once we run the code, we get an input message to write a string. Write “I AM A GOOD BOY” as input in the input box and press ok to see the result.
VBA Split Function – Example #3We can also use the VBA Split Function to count the number of words in the string. Let us take input from the user and count the number of words in it.
Step 3: Once the code window is open, declare a sub-function to start writing the code.
Code:
Sub
Sample2()End Sub
Step 4: Declare two variables, one as a string and one as an array string.
Code:
Sub
Sample2()Dim
AAs String
Dim
B()As String
End Sub
Step 5: Take input from the user and store it in A using the input box function.
Code:
Sub
Sample2()Dim
AAs String
Dim
B()As String
A = InputBox("Enter a String", "Should Have Spaces")End Sub
Step 6: Use the Split function and store it in B.
Code:
Sub
Sample2()Dim
AAs String
Dim
B()As String
A = InputBox("Enter a String", "Should Have Spaces") B = Split(A)End Sub
Step 7: Use a Msgbox function to display the total number of words.
Code:
Sub
Sample2()Dim
AAs String
Dim
B()As String
A = InputBox("Enter a String", "Should Have Spaces") B = Split(A) MsgBox ("Total Words You have entered is : " &UBound
(B()) + 1)End Sub
Step 8: Run the code from the run button provided. Once we have run the code, it asks for an input for the string. Write “INDIA IS MY COUNTRY” in the box and press ok to see the result.
Explanation of Excel VBA Split FunctionNow we know that the split function in VBA is a substring function that is used to split strings into different parts. The input we take is as a string, while the output displayed is an array.
It is very similar to the other worksheet function, but it is superior as it can break multiple words and return them as an array.
Things to RememberThere are a few things we need to remember about VBA split function:
The VBA split function is a substring function.
It returns the output as a string.
Only the expression is the mandatory argument, while the rest of the arguments are optional.
Recommended ArticlesThis has been a guide to VBA Split Function. Here we discussed how to use Excel VBA Split Function along with practical examples and a downloadable excel template. You can also go through our other suggested articles to learn more –
How To Add, Use, Edit And Delete Google Assistant Shortcuts
Google lets you do a lot many things on your phone handsfree, without even needing to touch your phone to initiate a query, for example. While you can get results on any of your queries, wouldn’t it be even more convenient if you can use an app installed on your phone by using just your voice? Thanks to a new feature on Assistant, you can say a hotword to Assistant and it will open a specific screen in your app as you design it.
What are Google Assistant Shortcuts?
The new Shortcuts feature allows users to speak to Google Assistant to open and run some specific actions inside an app on Android. Spotted first by Android Police, Shortcuts is a revamp of the feature with the same name that first debuted in 2023 that allowed users to create commands that performed multiple tasks. The feature was later replaced with a Routines option that lets you create custom actions by creating phrases as actions.
Google now seems to be bringing back the Shortcuts option but with some significant changes. These shortcuts are made to behave in a similar fashion to that of Apple Siri and will let you execute one particularly specific action inside an app that’s installed on your phone. This means that while you can use Shortcuts to reach a specific screen of an app, you cannot chain together a string of commands to do a particular task.
Why should you use Shortcuts on Google Assistant?
The new Assistant Shortcuts can let you create a new message, make a new tweet, see messages on Twitter, open places or your timeline on Google Maps, and other specific tasks or screens you can think of. Although the feature is dependent on what the developer of an app finds helpful, Shortcuts can let you get the job done with a limited number of taps.
Since the integration is being done to all apps including the ones not developed by Google, users can avoid opening apps and skip directly to the screen they want. This makes the feature fall in the same category as Siri Shortcuts which also lets users on iPhone and iPad jump to a specific section of an app with their voice.
Currently, the Assistant supports integration with Maps, Mail, WhatsApp, Instagram, and Twitter to provide quick access to the app’s shortcuts.
Who can use the new Assistant Shortcuts?
The new Assistant Shortcuts appear to be in the early stages of testing but from the looks of it, the feature remains independent of whether your device has the new-look Assistant enabled. Since this will be coming as a server-side update, you can expect Google Pixel devices to be the first ones to receive it, followed by Android One phones and smartphones from other manufacturers.
We have tried looking for the feature on our Google Pixel 3a but it’s yet to pop up on our unit.
How to add Google Assistant Shortcuts
Inside the Assistant Settings screen, scroll down and locate the Shortcuts option. This option needs to be visible on your phone to get the next steps to work. If it doesn’t, then the new Assistant Shortcuts aren’t yet available on your device and it’s best left if you wait for the feature to drop to your phone.
When you open the Shortcuts screen for the first time, you will see two tabs at the top – ‘Explore’ and ‘Your Shortcuts’. Explore showcases all the shortcuts that you can enable for the Google Assistant on your phone across all the apps that are installed while the latter will only show those ones which are enabled.
At the top portion of the ‘Explore’ tab, you will see a list of preset shortcuts for apps that you frequently use under the ‘Shortcuts you might like’ section. This section will then be succeeded by a list of all apps with shortcuts enabled under ‘All shortcuts for your apps’.
If you wish to enable any of the suggested shortcuts under the ‘Shortcuts you might like’ section, tap on the ‘+’ icon adjacent to the shortcut you want to add to your list.
For viewing all the shortcuts that are available for an app, hit the ‘View all’ button on the bottom left, tap on the desired app, and then hit the ‘+’ icon adjacent to the app shortcut you want to add to Assistant.
All your shortcuts when added will also be visible inside the ‘Routines’ section inside Assistant Settings where you can also make necessary changes to them however you feel like.
How to use Assistant shortcuts to do something in an app
Once you have enabled a shortcut, open the Google Assistant, and say the relevant command that was assigned to do the action that the shortcut was intended to do.
If enabled, you can use any one of the following commands and more to do a certain action:
“Hey Google, Explore Instagram”
“Hey Google, new Twitter message”
“Hey Google, add WhatsApp photo”
“Hey Google, share location”
“Hey Google, send email”
“Hey Google, Twitter messages”
“Hey Google, new Instagram post”
“Hey Google, my Instagram profile”
“Hey Google, My status”
“Hey Google, Youtube subscriptions”
“Hey Google, my places”
“Hey Google, Map timeline”
How to customize voice commands for Assistant Shortcuts
Apart from the default voice command mentioned on the screen, Google also lets you access Assistant shortcuts through your own custom voice command. To customize the commands to Assistant shortcuts, go to the Shortcuts screen from inside Assistant Settings and tap on the ‘Your shortcuts’ tab at the top.
This will show you a list of shortcuts that have already been enabled. If you haven’t enabled an Assistant shortcut yet, get it done by following the instructions mentioned in the section above. Inside the ‘Your shortcuts’ tab, tap on the Pencil icon adjacent to the shortcut you want to customize and then tap on the ‘Edit’ button at the bottom.
You can now replace the default voice command with any set of words you wish to add for the particular task, provided your command doesn’t conflict with any of the pre-existing commands that are used with the Assistant. After you have entered the new voice command, tap on the Done button.
You have successfully customized voice commands to use with Assistant Shortcuts.
How to delete Assistant Shortcuts
Shortcuts once added can also be removed from Google Assistant, meaning you can disable it in case you no longer want it to work. To delete an Assistant Shortcut, go to go to the Shortcuts screen from inside Assistant Settings and then select the ‘Your shortcuts’ tab at the top.
You will now see a list of shortcuts that have been enabled with Assistant on your phone. To disable any one of them, tap on the Pencil icon adjacent to the desired shortcut, and then tap on the ‘Delete’ button at the bottom.
The selected shortcut will now be disabled and removed from the ‘Your shortcuts’ tab but you can still re-enable it at a later time from inside the ‘Explore’ tab.
Screenshots source: Android Police
Are you excited about Assistant shortcuts on Android?
Update the detailed information about How To Use Excel Hacks With Keyboard Shortcuts? on the Tai-facebook.edu.vn website. We hope the article's content will meet your needs, and we will regularly update the information to provide you with the fastest and most accurate information. Have a great day!