How to access the BIOS Lenovo Z400 model

Hi guys

After trying some time to get this bad boy to work, I tried all of the old tactics from pressing the F8 or F2 or F1 keys. With LENOVO, it takes a little reading to get to the bottom of it. I was planning to format my friend’s laptop PC.

There is a small button at the side near the power cable. You need to turn off the laptop first and then press the button before you turn on the laptop.

Well, that’s it. I was able to get a pic of the side of the laptop. Will post it here for reference. Eventually, before I formatted the laptop, its a good practice to back up the files so that we can return them just the way it was.

Enjoy

Coffee Cup

 

Delphi – Create a single instance of your app

Hi guys. After searching for a while on how to lock and limit the app clicking. And this is now possible.

Here is the code for the main project file

program Project2;

 

uses

Forms, Windows, Messages, Dialogs,

Unit1 in ‘Unit1.pas’ {Form1};

 

{$R *.res}

 

function CreateSingleInstance(const InstanceName: string): boolean;

var

MutexHandle: THandle;

begin

MutexHandle := CreateMutex(nil, false, PChar(InstanceName));

// if MutexHandle created check if already exists

if (MutexHandle <> 0) then

begin

if GetLastError = ERROR_ALREADY_EXISTS then

begin

Result := false;

CloseHandle(MutexHandle);

end

else Result := true;

end

else Result := false;

end;

 

var

MyInstanceName: string;

begin

MyInstanceName := ‘Project2’;

Application.Initialize;

// Initialize MyInstanceName here

if CreateSingleInstance(MyInstanceName) then

begin

// Form creation

Application.CreateForm(TForm1, Form1);

Application.Run;

end

else Application.Terminate;

end.

Windows 10 : How to switch from VGA to HDMI on the same PC

On a windows 10 computer, sometimes you have an HDMI port and a VGA port. Normally, you only have 1 monitor. When you try to plug both ports together, windows guesses you have 2 monitors so when you scroll to the right, the mouse disappears.

Now if you remove the VGA cable you will see a black screen. The secret is the Windows+P key. When you press this button, the system automatically switches to HDMI port. Please note that this step would take around 10 seconds to kick-in.

At first I thought it did not work. But patience is truly a virtue.

Coffee Cup

InterBase Database Maximum User Connections

I got this quote from the operational guide itself.

* Maximum number of clients connected to one server

There is no single number for the maximum number of clients the InterBase server can serve—it depends on a combination of factors including capability of the operating system, limitations of the hardware, and the demands that each client puts on the server.

OPERATIONAL GUIDE MAXIMUM USER CONNECTION
OPERATIONAL GUIDE MAXIMUM USER CONNECTION

 

Avast Free Anti-Virus for WinXP using Universal Activation Key

Yup, you heard it right, avast just gave their universal key for avast free installed on windows xp. I am going to post the original message. There are still a few of us using windows xp

Good news! You no longer need to register

Newer versions of Avast Free Antivirus will no longer ask you to register, and older versions will keep working even after they’ve “expired”. If you’re using Avast Free Antivirus version 7 or older,

Universal Key: W11332244H9900A0420-8MRTR8W5

AVAST FREE - UNIVERSAL KEY WINXP
AVAST FREE – UNIVERSAL KEY WINXP

 

2018 Philippines – Globe , Smart , Sun – Mobile Numbers

As we text and call people, we need to know what network or telecommunication they are so that we don’t go overboard on extended calls and crossing over. Like for me, when I call a Globe number I don’t get charged since I am using a Globe Postpaid Plan. But if I call a Smart number, that is the time I get charged.

For now, here is my own compilation for the 2018 Philippines Globe / Smart / Sun Cellular telephone numbers.

Globe and Touch Mobile SMART and Talk N’Text SUN Cellular
817 905 906 813 900 907 908 922 923
915 916 917 909 910 911 912 924 925
926 927 935 913 914 918 919 931 932
936 937 945 920 921 928 929 933 934
955 956 965 930 938 939 940 942 943
966 975 977 946 947 948 949 944
994 995 996 950 989 998 999
997

Teamviewer : Activated the black screen feature but is not working on windows 10

Recently, I have tried to combine both the portable version and the installed version. If you are an IT guy and you need to update a PC on your office mates office remotely, you need to hide what you are doing by clicking the black screen feature.

And as an experiment, I tried to remotely connect to my laptop using the portable version. And as it turns out, it is not working on the client side. It seems that when you activate it on the portable version, the installer for the video card does not kick in thus, people on the client side can see what you are really doing although on the server side (where the IT guys is working, he can see the tick box activated).

In this post I will include the picture on how to activate the black screen on Teamviewer.

Teamviewer Black Screen Opion
Settings that show how to set the black screen on the client side

Delphi : Open Excel File using ShellExecute

This is a nifty code that i use whenever I do excel conversions. It helps users by seeing the excel file and not have to look for the file once the system has generated the output file

ShellExecute(Handle, 'open', 'c:\MyDocuments\MyFile.doc',nil,nil,SW_SHOWNORMAL);

In this example, the file is located inside the ‘My Documents’ folder with the file name ‘MyFile.xls’. Just in case the file name you are using is dynamic, you can enclose the variable with a PChar.

ShellExecute(Handle, 'open', PChar(varMyFilename),nil,nil,SW_SHOWNORMAL) ;

Enjoy

Coffee Cup

Delphi : Date and Time Format from ddd-mm-yy to mm/dd/yyyy

i had a case a few weeks back of a problem where the computer needs to have a date format of dd-mmm-yy which in today’s date is 21-Feb-18. What i need is for the program to act the same as it was with the format 02/21/2018.

After digging data, i came across these gems of a find. It’s so short and so obvious, i hope this code can help somebody out

Enjoy

Coffee Cup

 

 

 

{
CurrencyString, CurrencyFormat, NegCurrFormat, ThousandSeparator,
DecimalSeparator, CurrencyDecimals, DateSeparator, ShortDateFormat,
LongDateFormat, TimeSeparator, TimeAMString, TimePMString,
ShortTimeFormat, LongTimeFormat

//Change COMPUTER date and time
SetLocaleInfo(GetThreadLocale, LOCALE_SSHORTDATE, ‘MM/dd/yyyy’);
SendMessageTimeout(HWND_BROADCAST, WM_SETTINGCHANGE, 0, 0,
SMTO_ABORTIFHUNG, 1000, PDWord(Nil)^);

//Change formatting from within the APPLICATION
DateSeparator := ‘/’;
ShortDateFormat := ‘MM/dd/yyyy’;

SetLocaleInfo(DefaultLCID, LOCALE_SSHORTDATE, ‘m/d/yy’) (short form) and
SetLocaleInfo(DefaultLCID, LOCALE_SLONGDATE, ‘mmmm d, yyyy’) (long form)

SetLocaleInfo(GetThreadLocale, LOCALE_SSHORTDATE, ‘MM/dd/yyyy’);
SendMessageTimeout(HWND_BROADCAST, WM_SETTINGCHANGE, 0, 0,
SMTO_ABORTIFHUNG, 1000, PDWord(Nil)^);
}

// Change the display formatting
DateSeparator := ‘/’;
ShortDateFormat := ‘MM/dd/yyyy’;