Saturday, June 26, 2010

Mutisoft Extreme Software Development company in Sri Lanka

Multisoft Extreme is a Software Development company in Sri Lanka. We develop customized software for all your business requirements. We provide quality software and service for our clients.

Web : www.multisoftextreme.com
E-mail : info@multisoftextreme.com
Tel : +94 (0) 772201066

Sunday, March 14, 2010

Ms Word Automation using C#, Filling a shape with a specific RGB values.

In the development process of Abey Limousines Management System for Monaco France we were asked to export their Invoices to Ms Word where they can have it totally editable. We were asked to insert a shape to the word document to show their Facture No (Invoice No), We had to fill that shape with RGB(51,102,153) values, but we found it extremely hard to fill the shape with the above specific RGB value.

The RGB(51,102,153) is close to a blue color, but the colors we got close to blue are WdColor.wdColorLightBlue which has RGB(51,102,255) and WdColor.wdColorBlue which has RGB(0,0,255). Above those colors were presets and we found it hard to set it to the color of RGB(51,102,153).

Finally we found the solution, It was creating the color RGB(51,102,153) from the preset colors WdColor.wdColorLightBlue and WdColor.wdColorBlue. It is like mixing color and creating a new color.
The amazing thing in computers is you can subtract colors, This is how we created RGB(51,102,153).


WdColor.wdColorLightBlue -WdColor.wdColorBlue*2/5 which means


RGB(51,102,255) – RGB(0,0,255)*2/5
= RGB(51, 102,255 – 255*2/5)
=RGB(51,102,153)

So finally we were able to get the color we wanted by subtracting two colors

Friday, February 12, 2010

"Input string was not in a correct format" - Exception when Parsing strings to float, double

When developing the Abey Limousines Management System for Monaco France we encountered a strange error from both from parsing a string to double or a float, The application worked fine in our environment and it didn’t parse accurately in the client environment.

The problem was in Sri Lanka we use dot(.) as the decimal symbol and in Monaco France they use comma(,) as the decimal symbol, we had a text box to show their tax rate as 5.5, When parsing this 5.5 string to float or double both float.Parse() and float.TryParse() methods throws a exception saying “Input string was not in a correct format”

We Multisoft Extreme was able to successfully solve that problem by changing the decimal symbol from dot(.) to comma(,) in every occurrence of the application and changing 5.5 to 5,5. Also most importantly changing our current format to French (Monaco) from the Regional and Language Options form the control panel.

Saturday, February 6, 2010

MySQL Service Not starting - "Could not connect to the Service Control Manager.Error:0"

While implementing a Software System for Abey Limousines of Monaco France we Multisoft Exreme encounted a problem in starting the MySQL server in our client machine. The installation was done remotely where we gave the instructions to the client using Skype. We sent the screen shots of the steps of the MySQL Server installation.

At the end of the installation the MySQL service did not start. The Error was "Could not connect to the Service Control Manager.Error:0"

The Client was using the machine of Windos 7 and unaware of whether they are using an Administrative account or not. They said they can install other softwares with out a problem.

Finally we were able to find the solution, The solution was running the installation setup as a administrator by right clicking on the setup and and selecting Run as Administrator. Also we asked our client to uninstall the current installation and delete the MySQL folder in the C:\Program Files

Then the service was started sucessfuly and the installation was a sucess.