How to Code LibreOffice Basic (VBA) to Automatically Increase Number

Problem: I am using LibreOffice version 4.4, currently I use “drag down method” to automatically increase the number, e.g. LT1, LT2, LT3, …., LT100

How do I achieve the same result using LirbreOffice Basic (VBA)?

 

Solution:

REM ***** BASIC *****
Sub Main

rem define variables
dim document as object
dim dispatcher as object

rem get access to the document
document = ThisComponent.CurrentController.Frame
dispatcher = createUnoService("com.sun.star.frame.DispatchHelper")

dim args1(0) as new com.sun.star.beans.PropertyValue
dim args2(0) as new com.sun.star.beans.PropertyValue
dim i as integer 
dim iLT as integer
 rem goto cell "A1"
 args1(0).Name = "ToPoint"
 args1(0).Value = "$A$1"
 dispatcher.executeDispatch(document, ".uno:GoToCell", "", 0, args1())
 
 rem loop and insert suffix for "LT" of the item code
 For iLT = 401 to 500
 
 rem loop and insert suffix from "00" until "99" into the item code
 For i = 0 to 99
 
 
 args2(0).Name = "StringName"
 if len(i) = 1 then
 args2(0).Value = "06-st-0888-LT" & iLT & "-0" & i
 else
 args2(0).Value = "06-st-0888-LT" & iLT & "-" & i
 end if
 
 rem to enter the item code into the cell
 dispatcher.executeDispatch(document, ".uno:EnterString", "", 0, args2())
 
 rem move down one cell
 dispatcher.executeDispatch(document, ".uno:GoDown", "", 0, args1())
 
 Next i
 
 Next iLT
End Sub

How to Code LibreOffice Basic (VBA) to Automatically Increase Number

How to Resize Hard Disk Partition Without 3rd Party Software

Problem: my PC’s partition C drive is full, I need to increase the size or volume of the C drive. I have a lot of space in D drive. I do not have any 3rd party software like Paragon Partition Manager, EaseUS Partition Manager, etc. How do move or allocate free space in D drive to C drive?

 

Solution: you do not need any 3rd party software, Windows 7 and above should able to allocate free space from 1 partition to another (provided both partitions are on the same hard disk). Refer to the steps below …

  1. goto Disk Management
  2. if you wish to increase of the C drive volume, then right click on the partition next to C drive (in this case it is D drive)
  3. right click on D drive, select “Shrink Volume… ” to reduce the size of D drive:-
  4. 01-How to Resize Partition-Shrink the volume of Dright click on C drive, select “Extend Volume…” to increase the size of C drive
    02-How to Resize Partition-Extend the volume of C partition

 

How to Connect to MySQL Server (Host Machine) from VMWare (Virtual Machine)




Problem: I have an application in VMWare that needs to connect to MySQL database server in host machine. Both host machine and virtual machine are on the same server. How do I do it?

 

Solution: refer to the steps below …

  1. In host machine, one has to create a new MySQL User and assign privileges as below in Query prompt via phpMyAdmin or SQL editor:-
    CREATE USER 'username'@'localhost' IDENTIFIED BY 'password';
    GRANT ALL PRIVILEGES ON *.* TO 'username'@'localhost' WITH GRANT OPTION;
    CREATE USER 'username'@'%' IDENTIFIED BY 'password';
    GRANT ALL PRIVILEGES ON *.* TO 'username'@'%' WITH GRANT OPTION;
    FLUSH PRIVILEGES;
  2. Once done with all four queries, the virtual machine should able to connect with IP address, user name and password of database’s host machine, e.g.:-
    IP address: 192.168.0.59
    Port: 3306
    User: (username)
    Password: (Password)

Source: http://stackoverflow.com/questions/1559955/host-xxx-xx-xxx-xxx-is-not-allowed-to-connect-to-this-mysql-server

Good Read -> To Lead a Digital Transformation, CEOs Must Prioritize

source: https://hbr.org/2017/01/to-lead-a-digital-transformation-ceos-must-prioritize

Key Points:-

  1. most companies simply launched their own apps, deployed robotics, established partnerships with digital players, or are using data to analyze their business and make better decisions. The problem is that that these efforts tend to be ad-hoc and uncoordinated
  2. three ways to manage the digital transition are:
    1. Define where change is needed most
    2. Choreograph the change
    3. Empower people
  3. appoint a Chief Digital Officer – manger or orchestrator of digital transformation in company

List of Manuals/Guides Revised as at 2016-12-23

Here is a list of manuals or guides that were revised or recently published:-

MOBITEK S80 is the Solution to Singapore Shutting Down 2G Network

Singapore government has confirmed that they will shut down 2G or GSM network:-

The Infocomm Development Authority of Singapore (IDA) has approved the request of the mobile network operators (MNOs) – M1, Singtel Mobile and StarHub Mobile – to close their 2G networks with effect from 1 April 2017.

Therefore, for Singapore, there is no choice and all equipments must move to 3G.

If you are currently using GSM/SMS modem that only supports 2G network (e.g. Wavecom M1306B, Wavecom Supreme 10, Sierra Wireless FXT009) we recommend MOBITEK® S80.

Supporting Letter for APEC Business Travel Card

Please be informed that the Chinese Chamber of Commerce and Industry of Kuala Lumpur and Selangor (KLSCCCI) revises the conditions of the applicant on the requirements of application for the supporting letter for APEC Business Travel Card with effect from 1st November 2016.

Conditions of the Applicant:

KLSCCCI’s Life Member

– Company’s senior position

– Company’s Directors (eg: Executive Director, Managing Director, Chairman and CEO)

For KLSCCCI’s existing ordinary members who would like to renew or apply for APEC Business Travel Card, please convert your membership to life member. The conversion application form can be obtained from the Secretariat. For further inquiry, please contact Ms. Mei or Mr. Koh of KLSCCCI Secretariat at Tel: 03-4253 2135 or e-mail: yowcm@chinesechamber.org.myor kohks@chinesechamber.org.my .

Thank you.

Yours faithfully,

HO SOO FONG

Executive Director

Invitation to “Moments of Unity” Happy Gathering

Ref : C-2016-140
Date : 16th December 2016
To : All Honorary Life Presidents, Honorary Presidents and Advisers

All Council Members

All Committee Members

Invitation to “Moments of Unity” Happy Gathering
(21-1-2017)

 

We are pleased inform that the National Chamber of Commerce and Industry of Malaysia (NCCIM), the Associated Chinese Chambers of Commerce and Industry of Malaysia (ACCCIM) and the Chinese Chamber of Commerce and Industry of Kuala Lumpur and Selangor (KLSCCCI) will jointly organise the “Moments of Unity” Happy Gathering on 21st January 2017, 8.30 a.m. at Canopy, Lake Garden, Kuala Lumpur. Details of the event are as follows:

 

Date : 21st January 2017 (Saturday)
Time : 8.30 a.m. ~ 12.00 noon

 

Venue : Canopy, Lake Garden, Kuala Lumpur

 

Guest of Honour : YAB Dato’ Sri Mohd Najib b. Tun Abdul Razak,
Prime Minister of Malaysia.

 

We enclose herewith the location map, invitation card and tentative programme for your perusal.

 

All Honorary Life Presidents, Honorary Presidents, Advisers, Council Members and Committee members of KLSCCCI are cordially invited to this event. The Organiser will provide a “Unity T-shirt” to all participants of this event.

 

Please revert to Ms. Mei or Ms. Wong of Secretariat by 3rd January 2017 (Tuesday) to facilitate arrangement. Tel: 03-4253 2135; Fax: 03-4253 2524; E-mail: inquiry@chinesechamber.org.my.

 

Thank you.

 

Yours faithfully,

HO SOO FONG

Executive Director

UNITY-01  UNITY-02

UNITY-03

Suggestion to ACCCIM to Support Local Payment Gateway Providers

To: Members of ICT Group
From: K.L. Ng
Re: Suggestion to ACCCIM to Support Local Payment Gateway Providers

I am been pondering about this for few days. I like to bring up these to all of you for consideration:-

  1. I suggest that ACCCIM/KLSCCCI to take lead in using local e-payment gateway providers (e.g. ipay88, MOL or other payment gateway providers who are ACCCIM members).
  2. ACCCIM/KLSCCCI organise seminars all year round, when members receive seminar invitation via e-mail, there is a link to pay for the registration/seminar fee) and to register for the event.

Disclaimer: I do not have any vested interest in any local e-payment gateway providers. In fact, I am using overseas payment gateway — PayPal.