So you might have heard it by now: Microsoft has launched a remote desktop client for mobile OSs iOS and Android. The application is available in the respective stores here and here. Surprisingly still missing: A Windows Phone version.
There is competition (and some are cross-platform). Some names can be checked here.
sábado, 26 de outubro de 2013
Function Reference for Google Spreadsheets
So Office ain't free, at least the local installed version (not talking of the 365 version of which I recognize my current ignorance) and lately I've been finding Google Docs, altough laughable when looking at the feature support, convenient for quickly collaborating with people (in a and out of the company).
I've found this handy reference to the functions supported on spreadsheets.
If we compare this to the full Excel support we'll find somethings missing, but we have a Portuguese saying here in Angola (just kidding): "A cavalo dado não se olha o dente".
I've found this handy reference to the functions supported on spreadsheets.
If we compare this to the full Excel support we'll find somethings missing, but we have a Portuguese saying here in Angola (just kidding): "A cavalo dado não se olha o dente".
Etiquetas:
Excel,
Google Docs,
Office,
Spreadsheet
sexta-feira, 25 de outubro de 2013
TIOBE: The monthly programming languages index
An interesting link to analyse the trends and maybe plan your future is the TIOBE Programming Community Index.
This is a monthly updated chart of programming languages highlighting those that are moving up and other moving down.
The criteria being considered are defined in the TIOBE site.
Also interesting is the "Long Term trands" section, showing data since 2001 and the very long term.
All of these are sections in the link above (you'll have to scroll down).
terça-feira, 5 de janeiro de 2010
[TECH] Utilities I can't live without
Useful for complementing Windows (Windows XP I shall say):
- Windows live search - Indexes your drives (no big overolad) and searches documents (text, PDFs, Office formats, e-mail, MSN history, ...);
- ARS Clip - clipboard manager utility. Press Ctrl-Shift-Z anywhere and a context menu appears!
- CopyFilenames: http://www.extrabit.com/copyfilenames/ - copies a file name in to the clipboard;
- Minimize to tray - Minimizes any application with a standard caption bar to the tray. Examples of applications without a standard caption bar are Apple iTunes;
- SyncToys from Microsoft - can be used in command line mode (useful for scheduling copies to external hard drives with the AT command);
The list will grow over the time as I remember some more.
As usual, I hope this helps!
- Windows live search - Indexes your drives (no big overolad) and searches documents (text, PDFs, Office formats, e-mail, MSN history, ...);
- ARS Clip - clipboard manager utility. Press Ctrl-Shift-Z anywhere and a context menu appears!
- CopyFilenames: http://www.extrabit.com/copyfilenames/ - copies a file name in to the clipboard;
- Minimize to tray - Minimizes any application with a standard caption bar to the tray. Examples of applications without a standard caption bar are Apple iTunes;
- SyncToys from Microsoft - can be used in command line mode (useful for scheduling copies to external hard drives with the AT command);
The list will grow over the time as I remember some more.
As usual, I hope this helps!
[TECH] Time Trackers
Searching for an alternative for using the iPhone clock aplication. It wastes battery...
Found this interesting article (which includes the RescueTime which I know a long time ago since 2007):
http://mashable.com/2008/08/28/time-tracking-tools/
RescueTime in the paid version allows you to track time per project. An API is provided. It allows you to categorize time detected (by a client app) as work, non-work. Stats are presented online.
RescueTime is non disruptive, in the sense that it does not require you to start and stop a task.
I am sure that if you use time tracking tools for some days at work you'll find some surprising stats.
Found this interesting article (which includes the RescueTime which I know a long time ago since 2007):
http://mashable.com/2008/08/28/time-tracking-tools/
RescueTime in the paid version allows you to track time per project. An API is provided. It allows you to categorize time detected (by a client app) as work, non-work. Stats are presented online.
RescueTime is non disruptive, in the sense that it does not require you to start and stop a task.
I am sure that if you use time tracking tools for some days at work you'll find some surprising stats.
quarta-feira, 23 de dezembro de 2009
Why Delphi BDE applications sometimes will fail with shared memory errors
SHAREDMEMADDRESS BDE Configuration Parameter
Borland Database Engine (BDE) is a data access technology introduced by Borland a long time ago with Borland C++ and later on used by Delphi as a way of unifying access to DB data sources. At that time it had some interesting features that gave it some edge over ODBC for instance. For instance, if you followed some best practices, you were able to write applications accessing heterogeneous DB with the same client code (fat clients were common at the time). Also data access was fast, as Delphi was and still is (for Win32 applications). Over the time additional data access technologies surfaced but many legacy applications were kept accessing data over BDE native drivers. Incompatibilities can start to appear with new OS. Also, BDE is a Black Box. Documentation is scarce and it is no longer supported (so if you are using newer databases, chances are that you cannot access some of its new features or that somethings that worked before on previous DB engines do not work with the new versions. So when you or a customer decides to upgrade a DB, careful analysis and testing has to be performed.
After a long period of analysing stability problems of custom apps at a customer I have found the reason for some random errors "$210D: Shared Memory Conflict" occurring on Windows Server 2008 (that did not occur on another deployment server Windows 2003). The reason was traced to the address space layout randomization (ASLR) mechanism. For Windows, ASLR appeared first on Vista and aimed to introduce some randomness into the load address of some specially marked EXEs and DLLs (with the ASLR bit on) into the 32-bit address space of a Win32 process. For these operating systems some of OS DLLs are already marked with those flags. I am talking of DLLs like NTDLL.DLL, KERNEL32.DLL, etc.
To make a very long story short:
- BDE by default is configured to allocate the shared memory buffer it uses at 6BDE (0x6BDE0000, for Windows NT and above). This is inside the region used by the ASLR mechanism (above 0x50000000). This address is controlled by the SHAREDMEMADDRESS changeable in the BDE Administrator Control Panel applet or in the registry ([HKEY_LOCAL_MACHINE\SOFTWARE\Borland\Database Engine\Settings\SYSTEM\INIT] key).
- Every time a reboot is performed on the server a new randomization occurs and DLLs can from then on start to load on a different zone than the preferred load address. If a DLL is loaded into the 6BDE zone (or whatever address is set in SHAREDMEMADDRESS above 5000) then BDE tries to allocate the SHAREDMEMSIZE buffer into another region and typically succeeds. I haven't reached to the point of fully understanding the algorithm used for this rellocation since I was not given enough effort to debug this BDE behaviour (assembly).
- When in the same BDE client (i.e. same Windows Session on a PC with BDE installed locally) you open a second BDE app it will never be able to locate successfully the shared memory block in the rellocated address and will fail miserably with the "$210D: Shared memory conflict". Again I did not fully understand why this failure occurs (i.e. what kind of search is done and why it fails to locate a block of memory previously allocated by the same BDE code). A little more time spent debugging this should allow a full comprehension of this issue. But the customer needed a quick fix, so I had to move on.
The solution:
First list all BDE applications that a specific user will use. Using some memory mapping tool like VMMap, analyse all your BDE applications for a specific user. Find a region out of the ASLR region (below 0x50000000 minus the shared memory size configured in the BDE Admin) that is not being used consistently for every application. Notice that Delphi apps load at a preferred address (AFAIR 0x40000000) by default and this can be changed in Delphi compiler options. Also notice that old DLLs like BDE ones (IDAPI32.DLL) are not marked with the ASLR bit and as such they load at the preferred address stated in the file (PFE), unless another DLL is already loaded there.
After that analysis is done choose a valid address for SHAREDMEMADDRESS like 3BDE. But let me explain which addresses are valid addresses: Valid values for Windows NT and above are from 1000 to 7F00 but, as you have seen, if you are using Vista, Windows Server or any other OS that has the ASLR mechanism working, do NOT leave this setting at its default setting 6BDE. It could be a matter of time before you start having these errors reported from the users. The worst thing is that you will not be able to reproduce the issue easily on other test machines.
To locate the BDE shared memory location in VMMap, look for a block of memory with the indicated SHAREDMEMSIZE (if needed, close all BDE apps and change SHAREDMEMSIZE to a unique value so that you are able to spot it from other blocks).
I was able to reproduce this error in XP (SP2) by doing the reverse procedure and this was important to conclude that the reason for the error had been found. To reproduce the error you can follow this steps: Analyse the memory map for a BDE app, locate a DLL with the ASLR bit off (like IDAPI32.DLL) and take note of its load address. If it is in the valid range for SHAREDMEMADDRESS values (described above) configure this parameter to the same value. If not choose another DLL in the same conditions. Close all BDE applications. Open the first one and notice that the shared memory block is not being allocated at the configured address because it collides with that DLL (I have described how above). Open the same BDE application again and the $210D error will surface even in XP.
Note: ProcMon will allow you to detect if a process is ASLR activated or not (add the right column to the DLLs list for instance).
SHAREDMEMSIZE
Oh and BTW, if the error "$2501: Insufficient memory for this operation" is appearing to some of other users, increase the SHAREDMEMSIZE to 8192 or even a greater value (the maximum is 60000K; the minimum and default is 2048). Each BDE app consumes a fixed part of this shared memory buffer and a bigger buffer will allow for more applications to be open at the same time. This will increase each BDE EXE footprint in the OS after being loaded into memory but this should not be a problem if you have still enough virtual memory available in the OS. Another interesting thing i have discovered in the process was that by using the maximum value for SHAREDMEMSIZE I managed to open the maximum number of simultaneous BDE clients in a Windows session: 48. This was something I have also learned during this time. The limit to the number of BDE apps that can be opened at the same time is described in the "BDE Limits" help topic of BDEADMIN.HLP.
I leave you with a tip: Migrate this BDE apps to newer technologies ASAP.
You'll be doing yourself and your customer a big favor. Problems are around the corner and if you have to spot them by yourself you are alone in the dark (no support, no technical documentation, no source code, etc).
For details on these BDE parameters and another ones you can look at the BDEADMIN.HLP help file.
Borland Database Engine (BDE) is a data access technology introduced by Borland a long time ago with Borland C++ and later on used by Delphi as a way of unifying access to DB data sources. At that time it had some interesting features that gave it some edge over ODBC for instance. For instance, if you followed some best practices, you were able to write applications accessing heterogeneous DB with the same client code (fat clients were common at the time). Also data access was fast, as Delphi was and still is (for Win32 applications). Over the time additional data access technologies surfaced but many legacy applications were kept accessing data over BDE native drivers. Incompatibilities can start to appear with new OS. Also, BDE is a Black Box. Documentation is scarce and it is no longer supported (so if you are using newer databases, chances are that you cannot access some of its new features or that somethings that worked before on previous DB engines do not work with the new versions. So when you or a customer decides to upgrade a DB, careful analysis and testing has to be performed.
After a long period of analysing stability problems of custom apps at a customer I have found the reason for some random errors "$210D: Shared Memory Conflict" occurring on Windows Server 2008 (that did not occur on another deployment server Windows 2003). The reason was traced to the address space layout randomization (ASLR) mechanism. For Windows, ASLR appeared first on Vista and aimed to introduce some randomness into the load address of some specially marked EXEs and DLLs (with the ASLR bit on) into the 32-bit address space of a Win32 process. For these operating systems some of OS DLLs are already marked with those flags. I am talking of DLLs like NTDLL.DLL, KERNEL32.DLL, etc.
To make a very long story short:
- BDE by default is configured to allocate the shared memory buffer it uses at 6BDE (0x6BDE0000, for Windows NT and above). This is inside the region used by the ASLR mechanism (above 0x50000000). This address is controlled by the SHAREDMEMADDRESS changeable in the BDE Administrator Control Panel applet or in the registry ([HKEY_LOCAL_MACHINE\SOFTWARE\Borland\Database Engine\Settings\SYSTEM\INIT] key).
- Every time a reboot is performed on the server a new randomization occurs and DLLs can from then on start to load on a different zone than the preferred load address. If a DLL is loaded into the 6BDE zone (or whatever address is set in SHAREDMEMADDRESS above 5000) then BDE tries to allocate the SHAREDMEMSIZE buffer into another region and typically succeeds. I haven't reached to the point of fully understanding the algorithm used for this rellocation since I was not given enough effort to debug this BDE behaviour (assembly).
- When in the same BDE client (i.e. same Windows Session on a PC with BDE installed locally) you open a second BDE app it will never be able to locate successfully the shared memory block in the rellocated address and will fail miserably with the "$210D: Shared memory conflict". Again I did not fully understand why this failure occurs (i.e. what kind of search is done and why it fails to locate a block of memory previously allocated by the same BDE code). A little more time spent debugging this should allow a full comprehension of this issue. But the customer needed a quick fix, so I had to move on.
The solution:
First list all BDE applications that a specific user will use. Using some memory mapping tool like VMMap, analyse all your BDE applications for a specific user. Find a region out of the ASLR region (below 0x50000000 minus the shared memory size configured in the BDE Admin) that is not being used consistently for every application. Notice that Delphi apps load at a preferred address (AFAIR 0x40000000) by default and this can be changed in Delphi compiler options. Also notice that old DLLs like BDE ones (IDAPI32.DLL) are not marked with the ASLR bit and as such they load at the preferred address stated in the file (PFE), unless another DLL is already loaded there.
After that analysis is done choose a valid address for SHAREDMEMADDRESS like 3BDE. But let me explain which addresses are valid addresses: Valid values for Windows NT and above are from 1000 to 7F00 but, as you have seen, if you are using Vista, Windows Server or any other OS that has the ASLR mechanism working, do NOT leave this setting at its default setting 6BDE. It could be a matter of time before you start having these errors reported from the users. The worst thing is that you will not be able to reproduce the issue easily on other test machines.
To locate the BDE shared memory location in VMMap, look for a block of memory with the indicated SHAREDMEMSIZE (if needed, close all BDE apps and change SHAREDMEMSIZE to a unique value so that you are able to spot it from other blocks).
I was able to reproduce this error in XP (SP2) by doing the reverse procedure and this was important to conclude that the reason for the error had been found. To reproduce the error you can follow this steps: Analyse the memory map for a BDE app, locate a DLL with the ASLR bit off (like IDAPI32.DLL) and take note of its load address. If it is in the valid range for SHAREDMEMADDRESS values (described above) configure this parameter to the same value. If not choose another DLL in the same conditions. Close all BDE applications. Open the first one and notice that the shared memory block is not being allocated at the configured address because it collides with that DLL (I have described how above). Open the same BDE application again and the $210D error will surface even in XP.
Note: ProcMon will allow you to detect if a process is ASLR activated or not (add the right column to the DLLs list for instance).
SHAREDMEMSIZE
Oh and BTW, if the error "$2501: Insufficient memory for this operation" is appearing to some of other users, increase the SHAREDMEMSIZE to 8192 or even a greater value (the maximum is 60000K; the minimum and default is 2048). Each BDE app consumes a fixed part of this shared memory buffer and a bigger buffer will allow for more applications to be open at the same time. This will increase each BDE EXE footprint in the OS after being loaded into memory but this should not be a problem if you have still enough virtual memory available in the OS. Another interesting thing i have discovered in the process was that by using the maximum value for SHAREDMEMSIZE I managed to open the maximum number of simultaneous BDE clients in a Windows session: 48. This was something I have also learned during this time. The limit to the number of BDE apps that can be opened at the same time is described in the "BDE Limits" help topic of BDEADMIN.HLP.
I leave you with a tip: Migrate this BDE apps to newer technologies ASAP.
You'll be doing yourself and your customer a big favor. Problems are around the corner and if you have to spot them by yourself you are alone in the dark (no support, no technical documentation, no source code, etc).
For details on these BDE parameters and another ones you can look at the BDEADMIN.HLP help file.
What I have learned in 6 weeks at Romania
For professional reasons I had to spend some time at Romania. Before the cache clears out I wrote some notes for posterity.
What I have learned in 6 weeks in Romania:
- Romanian is similar to Portuguese. Both are Latin languages (this I knew before). Even like that you have a hard time understanding what they are saying. Maybe with some more time and some investigation on sounds and common connecting words things are easier. The written form it is said to be easier to understand but I haven't tested this yet.
- There is no google news for Romania as we have for PT.
- The Romanian guys I knew are nice people but in their own words most Romanian are rude and poorly educated.
- Family violence seems to be even more common than in PT. And guess who wins the stats for aggression: Men.
- There are more women than men. Men have emigrated.
- Travelling in the subway is safe and nice to the sight :) women take care of themselves even for the most casual occasions.
- Food is nice, similar to Portuguese when compared. Not so healthy though.
- Fish is rare and expensive. They have a river fish and several strange species (to me).
- Plastic money are not credit cards. Paper money is made from plastic and has always a transparent part.
- Food is cheap (when compared to portugal - average meal for 7€).
- Beer is abailable at 0.5l portions or greater. No "minis" (20cl).
- S i l v a is a Romanian brand of beer.
- Caru cu bere is one of the finest places to dinner.
- Papanaçi is a nice dessert.
- Bucharest is huge, grey and its streets are not very well preserved.
- No highways out of Bucharest, as in Portugsl 20 years ago.
- Buildings from the communist period are not preserved at all and are ugly, grey and falling apart. In Portugal owners would be notified for making recuperation in a timely fashion and If they wouldn't abide they would lose ownership to the city hall or be demolished.
- Streets do have holes. Sometimes there are craters on them.
- The house of Ceausescu is the second largest building in the world after the Pentagon.
- There is an underground tunnel from one face to another.
- There are several underground levels some of them not yet finished.
- The parliament operates on part of it.
- Buildings around belonged to some of the secret police people and are now dedicated to national institutes.
- Most of the cars are old, very old. Lots of Dacia (similar to old Renaults).
- Bucharest is a busy city (lots of traffic).
- Air polution is a real problem - I was not used to it at the start.
- There are lots of Dacia cars which now still belongs to the Renault group.
- There is no public connection by subway from the airport to the city centre.
- The Otopeni airport departures zone is small: one corridor only.
- At summer it is hot and dry. At winter it is really cold! Portugal rarely goes below zero.
- As a consequence, houses are very well isolated. Finishing details are not very well crafted for what i've seen (but for what I've seen at Macau, not worse).
- It is said that there are lots of corruption.
- August is a bad time to visit because all the bad Romanians come back to their homes to visit families and the bad guys at prison (to be confirmed).
- If you are investing or buying everyone will try to sell you something (to get a comission?).
- Cars are cheap: They are not heavily taxed by the government like in PT where they put VAT over a government tax (also illegal in the UE as it is said).
- The main church is the Christian Orthodox church.
- It is common that when crossing a church door people make the cross sign on themselves for 3 times. Even younger people do this.
- An high percentage of the population is gipsy. Lots of them are still nomads (unlike in Portugal where some of them are
- Generally speaking: Romanian girls are skinny, at least to say. And they do take care of their appearence. I've seen some fat ones but obesity is definitely not a national problem there... yet (as it starts to be in Portugal). McDonalds and other plastic junk food starts to reign there.
- I found everyone still marked by the communist period. It was only in 1989 that freedom came and as such, younger people than me are marked by those events which for me is strange. I don't remember living in the dictatorship period in Portugal because... I was not in Portugal at that time.
- During the communist period everything was produced internally at Romania: cars, equipments, etc. After the end of this period some industries were abandoned.
- During the communist period electricity was sometimes cut at night.
- In Bucharest, enormous amounts of land were kept reserved to city parks with lakes, trees, bike trails, etc.
If I remember some more things I'll post them here.
If you feel anything is offensive or not true please let me know. I might be wrong or have had a wrong perception of the things there. Also, my English could be better.
What I have learned in 6 weeks in Romania:
- Romanian is similar to Portuguese. Both are Latin languages (this I knew before). Even like that you have a hard time understanding what they are saying. Maybe with some more time and some investigation on sounds and common connecting words things are easier. The written form it is said to be easier to understand but I haven't tested this yet.
- There is no google news for Romania as we have for PT.
- The Romanian guys I knew are nice people but in their own words most Romanian are rude and poorly educated.
- Family violence seems to be even more common than in PT. And guess who wins the stats for aggression: Men.
- There are more women than men. Men have emigrated.
- Travelling in the subway is safe and nice to the sight :) women take care of themselves even for the most casual occasions.
- Food is nice, similar to Portuguese when compared. Not so healthy though.
- Fish is rare and expensive. They have a river fish and several strange species (to me).
- Plastic money are not credit cards. Paper money is made from plastic and has always a transparent part.
- Food is cheap (when compared to portugal - average meal for 7€).
- Beer is abailable at 0.5l portions or greater. No "minis" (20cl).
- S i l v a is a Romanian brand of beer.
- Caru cu bere is one of the finest places to dinner.
- Papanaçi is a nice dessert.
- Bucharest is huge, grey and its streets are not very well preserved.
- No highways out of Bucharest, as in Portugsl 20 years ago.
- Buildings from the communist period are not preserved at all and are ugly, grey and falling apart. In Portugal owners would be notified for making recuperation in a timely fashion and If they wouldn't abide they would lose ownership to the city hall or be demolished.
- Streets do have holes. Sometimes there are craters on them.
- The house of Ceausescu is the second largest building in the world after the Pentagon.
- There is an underground tunnel from one face to another.
- There are several underground levels some of them not yet finished.
- The parliament operates on part of it.
- Buildings around belonged to some of the secret police people and are now dedicated to national institutes.
- Most of the cars are old, very old. Lots of Dacia (similar to old Renaults).
- Bucharest is a busy city (lots of traffic).
- Air polution is a real problem - I was not used to it at the start.
- There are lots of Dacia cars which now still belongs to the Renault group.
- There is no public connection by subway from the airport to the city centre.
- The Otopeni airport departures zone is small: one corridor only.
- At summer it is hot and dry. At winter it is really cold! Portugal rarely goes below zero.
- As a consequence, houses are very well isolated. Finishing details are not very well crafted for what i've seen (but for what I've seen at Macau, not worse).
- It is said that there are lots of corruption.
- August is a bad time to visit because all the bad Romanians come back to their homes to visit families and the bad guys at prison (to be confirmed).
- If you are investing or buying everyone will try to sell you something (to get a comission?).
- Cars are cheap: They are not heavily taxed by the government like in PT where they put VAT over a government tax (also illegal in the UE as it is said).
- The main church is the Christian Orthodox church.
- It is common that when crossing a church door people make the cross sign on themselves for 3 times. Even younger people do this.
- An high percentage of the population is gipsy. Lots of them are still nomads (unlike in Portugal where some of them are
- Generally speaking: Romanian girls are skinny, at least to say. And they do take care of their appearence. I've seen some fat ones but obesity is definitely not a national problem there... yet (as it starts to be in Portugal). McDonalds and other plastic junk food starts to reign there.
- I found everyone still marked by the communist period. It was only in 1989 that freedom came and as such, younger people than me are marked by those events which for me is strange. I don't remember living in the dictatorship period in Portugal because... I was not in Portugal at that time.
- During the communist period everything was produced internally at Romania: cars, equipments, etc. After the end of this period some industries were abandoned.
- During the communist period electricity was sometimes cut at night.
- In Bucharest, enormous amounts of land were kept reserved to city parks with lakes, trees, bike trails, etc.
If I remember some more things I'll post them here.
If you feel anything is offensive or not true please let me know. I might be wrong or have had a wrong perception of the things there. Also, my English could be better.
Subscrever:
Mensagens (Atom)