This blog moved
Posted on: July 7, 2014
Blog moved to http://sabbour.me. See you there!
If you are developing using Qt Creator for the MeeGo/Harmattan target, and upon launching the emulator for your application you get a message like this in the compiler window:
chmod: /opt/MeeGoApp/bin/MeeGoApp: No such file or directory
warning: aegisSessionOpen() - failed to open platsec device (ret=-1)
warning: aegisSessionOpen() - failed to open platsec device (ret=-1)
sh:
/opt/MeeGoApp/bin/MeeGoApp: not found
Killing remote process(es)...
Finished running remote process. Exit code was 127.
Make sure your project path has no spaces. For example C:\Qt Projects\MeeGoApp will fail. Notice the space in “Qt Projects”.
I came across some packages compiled for 32-bit, like Adobe Air that I needed to install on my 64-bit ubuntu, the following commands will fix the flags on the .deb package to force install it on a 64-bit system.
Note that it the converted package might install but not work correctly, so you are at luck whether it will work after that or not.
cd ~/Downloads
mkdir tmp
dpkg-deb -x package_i386.deb tmp
dpkg-deb --control package_i386.deb tmp/DEBIAN
sed -i "s/i386/all/" tmp/DEBIAN/
dpkg -b tmp package_64.deb
sudo dpkg -i package_64.deb
- In: Code | Spatial
- Leave a Comment
As I’m just trying out Microsoft SQL Server Azure Spatial, the following things need to be removed from any generated SQL script in order to make it run on SQL Server Azure as they are not supported:
ON [PRIMARY]
PAD_INDEX
ALLOW_ROW_LOCKS
ALLOW_PAGE_LOCKS
SORT_IN_TEMPDB
newsequentialid()
I will keep this post updated as I discover new booby traps!
For a full list, check: http://msdn.microsoft.com/en-us/library/ee336253.aspx
Fixing: Could not load type ‘Microsoft.TeamFoundation.WorkItemTracking.Client.WorkItemTypeDeniedOrNotExistException’ from assembly ‘Microsoft.TeamFoundation.WorkItemTracking.Client, Version=9.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a’.
Posted on: June 28, 2010
Simply, if you get this error:
---------------------------
Microsoft Visual Studio
---------------------------
Could not load type 'Microsoft.TeamFoundation.WorkItemTracking.Client.WorkItemTypeDeniedOrNotExistException' from assembly 'Microsoft.TeamFoundation.WorkItemTracking.Client, Version=9.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a'.
---------------------------
OK
---------------------------

Then you probably installed Visual Studio, Visual Studio service pack, then the Team explorer. Doing it in that matter overwrites parts of Visual Studio SP hence giving you such errors.
The correct way to install would be:
- Visual Studio (Team Edition)
- Team Explorer
- Team Foundation 2008 October Power Tools
- Visual Studio 2008 Service Pack 1
To fix the error now, just re-install Visual Studio 2008 Service Pack 1.
As a reminder to myself, these are the steps to deploy an Qt application on the mobile phone.
- Project settings:
- Mobile deployment:
- Without smart installer (Qt 4.6.0)
- Open command prompt
- Navigate to project path
- Run:
qmake && make release-gcce
- Then run:
make sis
- You now have your .sis file ready. Make sure qt in already installed on the device
- With smart installer (Qt 4.6.2+) steps
- Without smart installer (Qt 4.6.0)
- In: Code
- Leave a Comment
I’ve run across this situation multiple times, where I have for example, an ID that I get in the code behind, and I want to append it to some href in the aspx, and each time I forget how to do it, so as a reminder for myself, here is how to do it and problems I ran into:
Assuming I have a property in the code behind that returns a GUID
protected Guid CustomerId {
get { return new Guid(); }
}
And assuming I have a link in my aspx page that I want to append this property to, here is how to do it
<a href="upgrade.aspx?id=<%= CustomerId .ToString() %>">Upgrade</a>
Note that this will not work if you specify a runat=server to the href for any reason, for example. to show the link or hide it according to specific logic.
If you need to show and hide the link, you can enclose it in a place holder and access that placeholder from the code behind
<asp:PlaceHolder ID="UpdgradeLinkPlaceholder" runat="server"> <a href="upgrade.aspx?id=<%= CustomerId .ToString() %>">Upgrade</a> </asp:PlaceHolder>
Today, I was trying to password protect a directory on a website that operated the cPanel software on Bluehost and I went ahead and used the “Generate Password” function which generated this nice looking password
w7WY/a3HIUx>
Now when I was trying to login with this password, whatever I tried to do it gave me a 401 Authorization required. It just didn’t accept my password. I contacted the support of Bluehost but they weren’t able to help!
After some searching, I found this forum post http://forums.cpanel.net/showthread.php?t=112117 which makes me wonder why hasn’t cPanel fixed that bug so far?
If your password or the generated password contains greater than (<) or less than (>) characters (or maybe other ones that I haven’t discovered yet), they will be filtered out by cPanel before the password is saved, effectivley changing the password you set.
As a work around if you really need to use those characters (I liked the generated password :P) you can set it through the shell
htpasswd -n username New password: w7WY/a3HIUx> Re-type new password: w7WY/a3HIUx> username:hash
Then copy the last line (username:hash) into your .htpasswd file which you can find by editing the .htaccess file in the directory that you were trying to protect. (Does this make sense?)
CakePHP: Edit view mysteriously changing to Add on Save validation failure
Posted on: March 25, 2009
- In: cakephp
- 8 Comments
I have never been more in need of a proper PHP debugger in my whole life. I have been stuck with a very mysterious behavior with CakePHP for the past 4 hours.
I was editing a model, then saving it. For some reason, my form action was changing from
/controller/edit/1 to /controller/add
it was making me go crazy!
After seaching around (finally) I found this: https://trac.cakephp.org/ticket/5871
I came to realize that I have actually omitted the
<?= form->input('id'); ?>
from my edit view because I thought “why the hell do I need to edit the primary key?”
As it turns out, CakePHP needs a field (hidden or not) with the name ID or else it will revert to the ADD form.
Luckily though, it is smart enough to render it as a hidden field.
Google is your friend.
This was my bachelor thesis that I have done as part of my studies for a B.Sc. degree in Computer Science and Engineering from the German University in Cairo.
Download presentation:
Indoor Localization Using Wireless LAN/WiFi Infrastructure
Download thesis:
Indoor Localization using Wireless LAN/WiFi Infrastructure
Abstract:
The rapid advances in wireless technology as well as in the manufacturing of portable devices caused a growing interest in location aware services. A location sensing
system responsible for locating a mobile user, is a crucial factor for the success of such services. With the prevalence of wireless hotspots and wireless area networks, the use of a wireless network infrastructure as basis for an indoor positioning system becomes a viable option. In this work, we propose an indoor guide system that provides information about points of interest and objects within the vicinity of the user. Our system can be deployed on a university campus or inside a museum equipped with a wireless network.
The system uses the fingerprinting technique to associate position dependent information such as the strength of the received signal with a location. A range based matching algorithm for matching the physical signal strength with the fingerprints in the database is used and its performance is compared to an Euclidean distance based matching algorithm. The properties of the wireless signals and their distribution under several controlled experiments are analyzed.



