Setting “task affinity” programmatically

You cannot. taskAffinity is contained by ActivityInfo, which is member of Activity. Source code of Activity public class Activity extends ContextThemeWrapper … … { // set by the thread after the constructor and before // onCreate(Bundle savedInstanceState) is called. @UnsupportedAppUsage /*package*/ ActivityInfo mActivityInfo; } And ActivityInfo has taskAffinity. Source code of ActivityInfo /** * Information … Read more

What is the difference between “asInvoker” and “highestAvailable” execution levels?

This is described on MSDN: Basically, “asInvoker” will use the user’s default security settings. It’s described as “The application runs with the same access token as the parent process.”, which means the same security token is used as the calling process, which is typically the desktop shell (or the process that launches this, if you … Read more

Android action.MAIN and category.LAUNCHER function

From the docs: category — Gives additional information about the action to execute. For example, CATEGORY_LAUNCHER means it should appear in the Launcher as a top-level application, while CATEGORY_ALTERNATIVE means it should be included in a list of alternative actions the user can perform on a piece of data. MAIN means that this activity is … Read more

How can I include package_data without a MANIFEST.in file?

TL;DR: The keys in the package_data dictionaries are packages; the values are lists of globs. ” is not a valid name for any Python package. If you want to have bar.txt be installed next to the __init__.py of package foo, use package_data={‘foo’: [‘bar.txt’]} I have the layout: foo/ __init__.py bar.txt setup.py Now, if foo is … Read more

Runtime error R6034 in embedded Python application

The problem was caused by third-party software that had added itself to the path and installed msvcr90.dll in its program folder. In this case, the problem was caused by Intel’s iCLS Client. Here’s how to find the problem in similar situations: Download Process Explorer here. Start your application and reproduce runtime error R6034. Start Process … Read more

reading an application’s manifest file?

Windows manifest files are Win32 resources. In other words, they’re embedded towards the end of the EXE or DLL. You can use LoadLibraryEx, FindResource, LoadResource and LockResource to load the embedded resource. Here’s a simple example that extracts its own manifest… BOOL CALLBACK EnumResourceNameCallback(HMODULE hModule, LPCTSTR lpType, LPWSTR lpName, LONG_PTR lParam) { HRSRC hResInfo = … Read more

Program Compatibility Assistant thinks my app is an installer

Add this into your manifest. <?xml version=”1.0″ encoding=”UTF-8″ standalone=”yes”?> <assembly xmlns=”urn:schemas-microsoft-com:asm.v1″ manifestVersion=”1.0″> <compatibility xmlns=”urn:schemas-microsoft-com:compatibility.v1″> <application> <!–The ID below indicates application support for Windows Vista –> <supportedOS Id=”{e2011457-1546-43c5-a5fe-008deee3d3f0}”/> <!–The ID below indicates application support for Windows 7 –> <supportedOS Id=”{35138b9a-5d96-4fbd-8e2d-a2440225f93a}”/> <!–The ID below indicates app support for Windows 8 –> <supportedOS Id=”{4a2f28e3-53b9-4441-ba9c-d69d4a4a6e38}”/> <!–The ID below indicates … Read more

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)