If you have a favorite app or game on Android, you can use it on your PC easily with BlueStacks.
What is BlueStacks?
BlueStacks has full name as BlueStacks App Player, it is an Android emulator that lets you use Android apps or games on PC or MAC. Although it is free but it is one of the best Android emulator for PC or MAC. It can run smoothly on MAC OS, Windows XP, Windows 7, 8 without any special requirement. It just needs 2 GB of RAM to run apps well.
In this article, I'll share you 3 ways to bring an Android apps or game to BlueStacks.
1. Use Play Store
After downloading & installing BlueStacks, go to its Search function to search your wanted apps or games.
The click Search Play... button.
In the first time, it requires you login to your Google account. In the search result, choose your wanted app to install like installing app on Android mobile phone.
2. Use APK file
APK file is an Android Package file, and it is the installer file for Android apps.
For some reasons in some cases, Play Store on BlueStacks may not work well or the app isn't available on the Play Store, it just has APK file.
To install, just find & download APK file to your PC, double click on it OR drag & drop it to BlueStacks home screen, then confirm that you want to install the app.
3. Use BlueStacks Cloud Connect
If Play Store and APK file don't work for you, you still don't end up here, you can use this last solution. BlueStacks Cloud Connect helps you sync selected apps from your smart phone to your PC. Below are steps to do:
+Open BlueStacks Settings by dragging down the right upper part of BlueStacks
+Then click on Cloud Connect and proceed further. It will require youe email & phone, then give you a PIN code.
+On your smart phone, let install BlueStacks Cloud Connect from Play Store. Then open the app and pair your phone with your PC by typing in your PIN. After that, you can tap any app you want to sync and tap Sync button.
+Open BlueStacks on your PC and enjoy the synced app or game.
Any comment is welcome!
Tuesday, March 17, 2015
Tuesday, February 10, 2015
Transfer domain from GoDaddy to another registrar
GoDaddy is providing many web hosting services, but unlike the other web hosting company, almost its services are not free, they will push upsells to charge you in many ways.
Depend on your budget, if you want to move your domain out of GoDaddy, below is the process that I experienced:
1. Make sure your domain already registered with GoDaddy over 60 days and it isn't expired. This is a rule implemented by ICANN, the organization that governs domain registrations. For more information, please review ICANN's Policy on Transfer of Registrations between Registrars.
2. Log into your GoDaddy account. Under Domains section, on the domain that you want to transfer, click Manage button.
3. Go to DNS ZONE FILE and print out the information here to backup (you can use Export tool here). Absolutely you will need this information for configuration DNS info of your domain on new registrar.
4. Go to CONTACTS tab and review and/update the contact information exactly. It should have your email info.
5. Go to SETTINGS tab, unlock your domain. GoDaddy will send an email to you to confirm the domain is unlocked.
6. Go to your new registrar to request the domain transfer. The new registrar will send an email to your email (set up in CONTACTS tab above) with a link to confirm. The email may have a password to transfer.
7. Back to GoDaddy and request Authorization Code of the domain (in SETTINGS tab). GoDaddy will send you an email with Authorization Code.
8. Provide the Authorization Code (and transfer password if any) to new registrar.
9. The new registrar will process the transfer. And you will receive an email from GoDaddy to accept. Let accept the transfer. In your My Account >> Domains >> Transfers, click Manage button then make the agreement.
10. The process is done. You must wait for your domain is updated info to new registrar. I can take few hours or several days (max is 7 days). In my case, it takes nearly an hour. In the case you don't see your domain in new registrar after 7 days, let contact your new registrar.
Hope this article can help you. Any comment is welcome.
Depend on your budget, if you want to move your domain out of GoDaddy, below is the process that I experienced:
1. Make sure your domain already registered with GoDaddy over 60 days and it isn't expired. This is a rule implemented by ICANN, the organization that governs domain registrations. For more information, please review ICANN's Policy on Transfer of Registrations between Registrars.
2. Log into your GoDaddy account. Under Domains section, on the domain that you want to transfer, click Manage button.
3. Go to DNS ZONE FILE and print out the information here to backup (you can use Export tool here). Absolutely you will need this information for configuration DNS info of your domain on new registrar.
4. Go to CONTACTS tab and review and/update the contact information exactly. It should have your email info.
5. Go to SETTINGS tab, unlock your domain. GoDaddy will send an email to you to confirm the domain is unlocked.
6. Go to your new registrar to request the domain transfer. The new registrar will send an email to your email (set up in CONTACTS tab above) with a link to confirm. The email may have a password to transfer.
7. Back to GoDaddy and request Authorization Code of the domain (in SETTINGS tab). GoDaddy will send you an email with Authorization Code.
8. Provide the Authorization Code (and transfer password if any) to new registrar.
9. The new registrar will process the transfer. And you will receive an email from GoDaddy to accept. Let accept the transfer. In your My Account >> Domains >> Transfers, click Manage button then make the agreement.
10. The process is done. You must wait for your domain is updated info to new registrar. I can take few hours or several days (max is 7 days). In my case, it takes nearly an hour. In the case you don't see your domain in new registrar after 7 days, let contact your new registrar.
Hope this article can help you. Any comment is welcome.
Wednesday, January 7, 2015
Excel: Merge cells in rows having same values
All most people like me and you often use Excel to process Data. Some times you get a Data with cells in rows having same values, and you want to merge them into 1 cell by each column. For example, you have a Data like the screenshot below:
And you want to achieve new Data as the following:
In which, SUM column will have new value = SUM of rows on AllOrHalf column which are belong to the merged cell.
In this article, I'll show you a solution using VBA to make this work. On the sheet, press Alt+F11 to open Visual Basic Editor (VBE). Right click on your workbook name in the Project-VBAProject pane (at the top left corner of the editor window) and select Insert >> Module from the context menu.
Copy below code to the window:
That's it. Any comment is welcome.
And you want to achieve new Data as the following:
In which, SUM column will have new value = SUM of rows on AllOrHalf column which are belong to the merged cell.
In this article, I'll show you a solution using VBA to make this work. On the sheet, press Alt+F11 to open Visual Basic Editor (VBE). Right click on your workbook name in the Project-VBAProject pane (at the top left corner of the editor window) and select Insert >> Module from the context menu.
Option Explicit
Private Sub MergeCells()
Application.ScreenUpdating = False
Application.DisplayAlerts = False
Dim rngMerge As Range, cell As Range
Dim nrow As Integer: nrow = 0
Dim continue As Boolean: continue = True
Dim totalLeave As Double: totalLeave = 0
Set rngMerge = Range("A2:A9") 'range to check
For Each cell In rngMerge
Do
totalLeave = totalLeave + cell.Offset(nrow, 5).Value
If cell.Offset(nrow, 0).Value = cell.Offset(nrow + 1, 0).Value _
And cell.Offset(nrow, 1).Value = cell.Offset(nrow + 1, 1).Value _
And cell.Offset(nrow, 2).Value = cell.Offset(nrow + 1, 2).Value _
And cell.Offset(nrow, 3).Value = cell.Offset(nrow + 1, 3).Value _
And IsEmpty(cell) = False Then
nrow = nrow + 1 'check next row
continue = True
Else
continue = False
End If
Loop Until continue = False
If nrow > 0 Then
Range(cell.Offset(0, 3), cell.Offset(nrow, 3)).Merge
Range(cell.Offset(0, 2), cell.Offset(nrow, 2)).Merge
Range(cell.Offset(0, 1), cell.Offset(nrow, 1)).Merge
Range(cell, cell.Offset(nrow, 0)).Merge
nrow = 0
End If
cell.Offset(0, 3).Value = totalLeave 'assign value to SUM column
totalLeave = 0
Next
Application.DisplayAlerts = True
Application.ScreenUpdating = True
End Sub
Then press F5 to run the code. After that, you can format merged cells and you will get the result.Private Sub MergeCells()
Application.ScreenUpdating = False
Application.DisplayAlerts = False
Dim rngMerge As Range, cell As Range
Dim nrow As Integer: nrow = 0
Dim continue As Boolean: continue = True
Dim totalLeave As Double: totalLeave = 0
Set rngMerge = Range("A2:A9") 'range to check
For Each cell In rngMerge
Do
totalLeave = totalLeave + cell.Offset(nrow, 5).Value
If cell.Offset(nrow, 0).Value = cell.Offset(nrow + 1, 0).Value _
And cell.Offset(nrow, 1).Value = cell.Offset(nrow + 1, 1).Value _
And cell.Offset(nrow, 2).Value = cell.Offset(nrow + 1, 2).Value _
And cell.Offset(nrow, 3).Value = cell.Offset(nrow + 1, 3).Value _
And IsEmpty(cell) = False Then
nrow = nrow + 1 'check next row
continue = True
Else
continue = False
End If
Loop Until continue = False
If nrow > 0 Then
Range(cell.Offset(0, 3), cell.Offset(nrow, 3)).Merge
Range(cell.Offset(0, 2), cell.Offset(nrow, 2)).Merge
Range(cell.Offset(0, 1), cell.Offset(nrow, 1)).Merge
Range(cell, cell.Offset(nrow, 0)).Merge
nrow = 0
End If
cell.Offset(0, 3).Value = totalLeave 'assign value to SUM column
totalLeave = 0
Next
Application.DisplayAlerts = True
Application.ScreenUpdating = True
End Sub
That's it. Any comment is welcome.
Wednesday, December 24, 2014
How to use MS SQL to generate random unique number for scratchcard
Do you need a series random unique numbers for scratchcards, or bundle codes for vouchers?
There are many ways to do this work, in this articles I would like to share a way to generate these numbers in SQL server.
SQL server has a function calling NEWID(), it creates a unique GUID (uniqueidentifier) value. Depending on your purpose, you can use this function in several ways to generate unique numbers.
Generate a GUID:
SELECT NEWID()
It will generate a new random uniqueidentifier e.g. 4FEC77B5-83AC-485B-9B0A-9A3E58BE4A06
Generate a random unique number:
SELECT ABS(CAST(CAST(NEWID() AS VARBINARY(5)) AS Bigint))
It will generate a random unique number e.g. 685690842599
Generate a random unique number with fixed digit:
SELECT REPLACE(STR(CAST(CAST(NEWID() AS binary(6)) AS bigint),15),0,0)
You will have a random unique number with fixed digit e.g. 188125385042097. Then you can use it for your scratchcard or voucher etc.
That's all. Any comment is welcome!
There are many ways to do this work, in this articles I would like to share a way to generate these numbers in SQL server.
SQL server has a function calling NEWID(), it creates a unique GUID (uniqueidentifier) value. Depending on your purpose, you can use this function in several ways to generate unique numbers.
Generate a GUID:
SELECT NEWID()
It will generate a new random uniqueidentifier e.g. 4FEC77B5-83AC-485B-9B0A-9A3E58BE4A06
Generate a random unique number:
SELECT ABS(CAST(CAST(NEWID() AS VARBINARY(5)) AS Bigint))
It will generate a random unique number e.g. 685690842599
Generate a random unique number with fixed digit:
SELECT REPLACE(STR(CAST(CAST(NEWID() AS binary(6)) AS bigint),15),0,0)
You will have a random unique number with fixed digit e.g. 188125385042097. Then you can use it for your scratchcard or voucher etc.
That's all. Any comment is welcome!
Friday, November 28, 2014
Windows Server: prevent anonymous login and ban IP of attacker
On Windows Server 2008 R2 / Windows Server 2012 you can disable anonymous login by using Local Group Policy Editor. To open the Local Group Policy Editor: click Start button, key gpedit.msc in the Start Search box, and then press ENTER.
Under Computer Configuration\Windows Settings\SecuritySettings\Local Policies\SecurityOptions, there are 6 policies to control what information can be accessed anonymously:
1. Network access: Allow anonymous SID/Name translation
2. Network access: Do not allow anonymous enumeration of SAM accounts
3. Network access: Do not allow anonymous enumeration of SAM accounts and shares
4. Network access: Let Everyone permissions apply to anonymous users
5. Network access: Named Pipes that can be accessed anonymously
6. Network access: Shares that can be accessed anonymously
Just disable policy 1 and 4, enable policy 2 and 3, and clear empty for policy 5 and 6.
Disabling anonymous login is not enough for preventing attempts to attack your Windows Server, you should buying & install an application like Symantec Endpoint Protection to protect your server with advance functions.
However if your server just run SQL server and you use Remote Desktop to remote the server, you can do a security layer by your self. The first thing is you should change the default service port of Remote Desktop and SQL server. The second thing is you should use IPBan written by Jeffrey N. Johnson, it is a free tool tracking any IP that invokes services on your server and when number of fail events reaches to a predefined threshold, it will block the IP in the Windows Advanced Firewall by using a Blocking rule there.
If you like coding, you can download the code of IPBan from here. If not, you can download its binary from here (required .NET Framework 4). Below are main configurations for making it up & run:
1. Config Remote Desktop Session Host Configuration to log IP address in event log. To run it: click Start button, key Remote Desktop Session Host Configuration in the Start Search box, and then press ENTER. Double click the connection RDP-Tcp to change encryption settings to native RDP encryption. See the picture below for howto. After finishing, please reboot your server.
2. Copy IPBan binary to a folder, e.g. D:\IPBan. Then open and modify IPBan.exe.config file. Below are some rules that you should learn:
2.1 Group rules, for example:
<Group>
<Keywords>0x90000000000000</Keywords>
...
<XPath>//Provider[@Name='MSSQLSERVER']</XPath>
...
</Group>
This group is used for tracking Application events for logging on to MS SQL server which having keyword 0x90000000000000, see the following captured image in Application events for more detail:
In this case, Provider is MSSQL$SGSQL2012, so we'll change MSSQLSERVER to MSSQL$SGSQL2012.
2.2 Rule for attempts before banning
<add key="FailedLoginAttemptsBeforeBan" value="5" />
2.2 Ban time rule (DD:HH:MM:SS)
<add key="BanTime" value="00:00:30:00" />
2.2 Log file rotation rule
<target name="logfile" xsi:type="File" fileName="${basedir}\logfile.txt" archiveNumbering="Sequence" archiveEvery="Day" maxArchiveFiles="28" />
3. Create IPBan service and start it
#sc create IPBan type= own start= auto binPath= D:\IPBan\ipban.exe DisplayName= IPBan
#net start IPBan
That's all. Now you can monitor your server under your way.
Any comment is welcome!
Under Computer Configuration\Windows Settings\SecuritySettings\Local Policies\SecurityOptions, there are 6 policies to control what information can be accessed anonymously:
1. Network access: Allow anonymous SID/Name translation
2. Network access: Do not allow anonymous enumeration of SAM accounts
3. Network access: Do not allow anonymous enumeration of SAM accounts and shares
4. Network access: Let Everyone permissions apply to anonymous users
5. Network access: Named Pipes that can be accessed anonymously
6. Network access: Shares that can be accessed anonymously
Just disable policy 1 and 4, enable policy 2 and 3, and clear empty for policy 5 and 6.
Disabling anonymous login is not enough for preventing attempts to attack your Windows Server, you should buying & install an application like Symantec Endpoint Protection to protect your server with advance functions.
However if your server just run SQL server and you use Remote Desktop to remote the server, you can do a security layer by your self. The first thing is you should change the default service port of Remote Desktop and SQL server. The second thing is you should use IPBan written by Jeffrey N. Johnson, it is a free tool tracking any IP that invokes services on your server and when number of fail events reaches to a predefined threshold, it will block the IP in the Windows Advanced Firewall by using a Blocking rule there.
If you like coding, you can download the code of IPBan from here. If not, you can download its binary from here (required .NET Framework 4). Below are main configurations for making it up & run:
1. Config Remote Desktop Session Host Configuration to log IP address in event log. To run it: click Start button, key Remote Desktop Session Host Configuration in the Start Search box, and then press ENTER. Double click the connection RDP-Tcp to change encryption settings to native RDP encryption. See the picture below for howto. After finishing, please reboot your server.
2. Copy IPBan binary to a folder, e.g. D:\IPBan. Then open and modify IPBan.exe.config file. Below are some rules that you should learn:
2.1 Group rules, for example:
<Group>
<Keywords>0x90000000000000</Keywords>
...
<XPath>//Provider[@Name='MSSQLSERVER']</XPath>
...
</Group>
This group is used for tracking Application events for logging on to MS SQL server which having keyword 0x90000000000000, see the following captured image in Application events for more detail:
In this case, Provider is MSSQL$SGSQL2012, so we'll change MSSQLSERVER to MSSQL$SGSQL2012.
2.2 Rule for attempts before banning
<add key="FailedLoginAttemptsBeforeBan" value="5" />
2.2 Ban time rule (DD:HH:MM:SS)
<add key="BanTime" value="00:00:30:00" />
2.2 Log file rotation rule
<target name="logfile" xsi:type="File" fileName="${basedir}\logfile.txt" archiveNumbering="Sequence" archiveEvery="Day" maxArchiveFiles="28" />
3. Create IPBan service and start it
#sc create IPBan type= own start= auto binPath= D:\IPBan\ipban.exe DisplayName= IPBan
#net start IPBan
That's all. Now you can monitor your server under your way.
Any comment is welcome!
Subscribe to:
Posts (Atom)













