Tuesday, March 8, 2016

scExcelExport Component for Delphi 10 Seattle

As of this time of writings, scExcelExport component still not support Delphi 10 Seattle. Only Delphi XE8 will be able to compile the component without issue.

If you highly depend to this component, i will show you how to compile it in Delphi 10 Seattle (until the official release come out).
1. Open scExcelExportConfig.inc using text editor.
2. Add the code i have marked below inside scExcelExportConfig.inc:
{--------------------------------------------------------------------------------
* Description : scExcelExportConfig.inc - compiler directives
--------------------------------------------------------------------------------}
//******************* begin custom line ********************************
{$IFDEF VER300} // Delphi 10 : Default Excel2010, ExcelXP can also be used
  {$DEFINE EXCEL2010}
  {$DEFINE DELPHIXE8}
  {$DEFINE DELPHIXEORNEWER}
  {$DEFINE DELPHI2010ORNEWER}
  {$DEFINE DELPHI2006ORNEWER}
{$ENDIF}
//******************* end custom line ********************************
{$IFDEF VER290} // Delphi XE8 : Default Excel2010, ExcelXP can also be used {$DEFINE EXCEL2010} {$DEFINE DELPHIXE8} {$DEFINE DELPHIXEORNEWER} {$DEFINE DELPHI2010ORNEWER} {$DEFINE DELPHI2006ORNEWER} {$ENDIF}
Then you can compile the component as show in its documentation successfully.

Please drop your comment if you have issue.

Tuesday, January 20, 2015

Reset Files and Folders Permission on Windows

I often used windows permission to limit other user on the same PC to access application/Folder/File. But after the real owner of the file is resign, i had to change those files/folders permission to original or directly change to current user.

So if you need to reset file/folder permission setting to default, you can use command below:
ICACLS (Folder or File name) /T /Q /C /RESET
example:
D:\OILDATA>ICACLS IVAN /T /Q /C /RESET

Above command will help you to accomplish your need.

Monday, January 5, 2015

Laravel Release Download

I love to used Laravel as my Web Framework. Many Projects that i develop used Laravel.
But the downside of Laravel Release download, Laravel never put every version release as an archive, instead you have download it directly from source.

So to make my self and you who visit my blog easier in future to get Laravel when starting new project or update current project with new laravel release, i put every Laravel relese in my Dropbox then you can download it in single rar archive.

Laravel v4.1.18 - Download
Laravel v4.2 - Download
Laravel v4.2.4 - Download
Laravel v4.2.8 - Download
Laravel v4.2.9 - Download
Laravel v4.2.11 - Download
Laravel v4.2.16 - Download
Laravel v5.0.22 - Download

Hope this writing and Laravel Archive can help you.

ExtJS 5.x Download

With the launch for new ExtJS version 5.x, Sencha tried to push the developer for purchase their product. Because now as default, ExtJS will download as 30 Days Trial. But in the other side, Sencha still support for Open Source Application. So you can download ExtJS for free if you agree with their GPLv3 term.
So for the shortcut, here is the link to download ExtJS version 5.x :
http://www.sencha.com/products/extjs/details
The download button will be available on the bottom of the page.

Monday, December 29, 2014

List of VirtualMin error when configuring and the its solutions

I'am as a web developer, often use Virtualmin as Control Panel, but sometimes when configuring i got stuck with the following error. After some research i got the solution to fix the error. I wrote here as reminder for future and also for you if stuck with the same error.

"Your Postfix configuration is missing the system's mail hostname UNKNOWN from the mydestination line, which will cause mail to bounce."
Solution:
Put "UNKNOWN" string inside "/etc/postfix/main.cf" file and in line  "mydestination ="




Hope this writing can help you out there.

Thursday, September 18, 2014

Install Vala with GTK+ 3 in Windows

As you may know, vala have binary release for windows maintain by communities.
https://code.google.com/p/vala-win32/downloads/list
But the binary release are not up to date now, their last release is for vala v0.12.0 on April 2011.

But if you really want to develop an Application with this awesome cross platform programming language in Windows, you still have a way, "build from source".

For build Vala from source in Windows, you can follow my step-by-step guide bellow to install:
- Vala v0.25.4 (latest version when i write this post) with
- GTK+ 3 v3.6.4-20130921 (latest version when i write this post).

Here's the guide to follow:
1. Download MinGW-builds from http://sourceforge.net/projects/mingwbuilds/
2. Run "mingw-builds-install.exe", select :
  • Architecture = "x32"
  • Threads = "win32"
  • Exception = "sjlj"
like picture below:

3. Continue installation wizard, then choose directory where to install MinGW to:
C:\mingw-builds


4. After installation finish, download the latest "external-binary-packages" from http://sourceforge.net/projects/mingwbuilds/files/external-binary-packages/ then copy/extract the "msys" directory to:
C:\mingw-builds\mingw32


5. Open "C:\mingw-builds\mingw32\msys\etc\fstab" with Notepad++ and add this line:
C:\mingw-builds\mingw32 /mingw
in it then save.

6. Download the Win32 GTK+ v3 "all-in-one bundle" from http://www.gtk.org/download/win32.php and then copy/extract it's content to "C:\mingw-builds\mingw32".

7. In order to get a nice shell, create a new shortcut, e.g. on the Desktop and set shortcut location to:
C:\mingw-builds\mingw32\msys\bin\mintty.exe /bin/bash -l
then leave shortcut name to "mintty.exe" or "mintty" or "MinGW-Console".

8. Create "home" folder inside "C:\mingw-builds\mingw32\msys" folder then create folder with the name same as your windows login name inside "home" folder.

You can get your windows login name simply with opening "command prompt".

9. Download the latest source tarball from https://wiki.gnome.org/Projects/Vala/Release and then copy/extract it's content to "C:\mingw-builds\mingw32\msys\home\{Your Username}"

10. Add Vala Directory path to your System Variable Path.
Open "Control Panel > System > Advanced system settings > Environment Variables ..."
Add New System Variable with :

  • Variable name = "ValaPath"
  • Variable value = "C:\mingw-builds\mingw32\msys\build\bin"

Then add "ValaPath" to System Variable Path
;%ValaPath%



11. Run the Mintty shortcut you created in step 7 and switch with "cd" to the vala source directory then execute command below:
cd vala-0.25.4/
./configure --prefix=/build
make
make install

If no error found, then your step to install Vala is complete. You can try to execute syntax below to check Vala is Ready:
gcc --version
valac --version
it will return versions for each compiler.

If no error found again, then you may try to create a GUI Application using Vala and GTK+ in windows. For express, you can try sample code from https://wiki.gnome.org/Projects/Vala/GTKSample eg, like below:

Create new File inside "C:\mingw-builds\mingw32\msys\home\{Your Username}" with "gtk-hello.vala" as filename. Then type code below as it's content:
using Gtk;

int main (string[] args) {
    Gtk.init (ref args);

    var window = new Window ();
    window.title = "First GTK+ Program";
    window.border_width = 10;
    window.window_position = WindowPosition.CENTER;
    window.set_default_size (350, 70);
    window.destroy.connect (Gtk.main_quit);

    var button = new Button.with_label ("Click me!");
    button.clicked.connect (() => {
        button.label = "Thank you";
    });

    window.add (button);
    window.show_all ();

    Gtk.main ();
    return 0;
}
then compile that source code using Vala Compiler:
valac --pkg gtk+-3.0 --cc=gcc gtk-hello.vala
if no error found when compile, you can execute the result application with call it:
gtk-hello.exe
it will show window like below:

Ok, Thanks for Reading. If you have problem when following my guide, drop me a comment below.

In other post i will show you how to:
- Run Created Application outside MinGW.
- Remove Empty Command Prompt behind Created Application if run outside MinGW.
- Publish application created using Vala & GTK+ in Windows for Windows OS

Wednesday, August 6, 2014

Free Download ExtJS 4.2.2

If you are an ExtJs Developer, you should know that ExtJs v4.2.2 only available for subscriber-only release. So if you wanna get that but you're not support subscriber then, here's the trick:

Download the extjs 4.2.2 full documentation:
http://cdn.sencha.com/downloads/docs/extjs-docs-4.2.2.zip
then extjs v4.2.2 sources are in: extjs-docs-4.2.2\extjs-build

See You.. :D