[Last Call] Learn how to a build a cloud-first strategyRegister Now

x
?
Solved

The cells containing multiple languages, I want only the cell only English

Posted on 2016-11-03
5
Medium Priority
?
63 Views
Last Modified: 2016-11-03
Hi Expert ,

I will be very grateful if any one can give the solution :

I have spreadsheet  The cells containing multiple languages with English language, How do I transfer to new cells take English language only.

Thanks
Excel-English-Language.xlsx
0
Comment
Question by:Satech Jubara
  • 2
  • 2
5 Comments
 
LVL 54

Expert Comment

by:Ryan Chong
ID: 41871726
try create a custom function like this and call it as a formula in your target cell:
Function getEnglish(ByVal s As String) As String
    For i = 1 To Len(s)
        Select Case Asc(Mid(s, i, 1))
        Case 65 To 90
            t = t & Mid(s, i, 1)
        Case 97 To 122
            t = t & Mid(s, i, 1)
        End Select
    Next
    getEnglish = t
End Function

Open in new window


=getEnglish(D7)

Open in new window

Excel-English-Language_b.xlsm
0
 

Author Comment

by:Satech Jubara
ID: 41871733
Ho i can Published  this code to create the function , By steps please
0
 
LVL 54

Accepted Solution

by:
Ryan Chong earned 2000 total points
ID: 41871745
here you go, try this:
1. open up your Excel file.
2. open the Microsoft Visual Basic for Application window by pressing Alt + F11
3. Go to menu Insert > Module
4. Paste the script above
5. go to your Excel front end, and put formula : =getEnglish(D7)
    * you should able to find that custom formula after you start typing =getEngl....
6. try to save your file with macro enabled feature, like to save as a .xlsm file instead.
0
 
LVL 43

Expert Comment

by:Saqib Husain, Syed
ID: 41871749
Right-click on the sheet tab name
Select View code
Insert > Module
paste this code in the vba window
close the VBA window
Function english(r As String) As String
    For i = 1 To Len(r)
        Select Case Mid(r, i, 1)
            Case "A" To "Z", "a" To "z", " "
                english = english & Mid(r, i, 1)
        End Select
    Next i
    english = Trim(english)
End Function

Open in new window


Enter this in a cell

=english(d7)
0
 

Author Closing Comment

by:Satech Jubara
ID: 41871752
Thanks
0

Featured Post

Upgrade your Question Security!

Add Premium security features to your question to ensure its privacy or anonymity. Learn more about your ability to control Question Security today.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Do you use a spreadsheet like Microsoft's Excel?  Have you ever wanted to link out to a non excel file on your computer or network drive?  This is the way I found to do it!
You need to know the location of the Office templates folder, so that when you create new templates, they are saved to that location, and thus are available for selection when creating new documents.  The steps to find the Templates folder path are …
This Micro Tutorial will demonstrate in Google Sheets how to use the HYPERLINK function to create live links inside your spreadsheet.
Excel styles will make formatting consistent and let you apply and change formatting faster. In this tutorial, you'll learn how to use Excel's built-in styles, how to modify styles, and how to create your own. You'll also learn how to use your custo…

834 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question