Search Results

Search found 44 results on 2 pages for 'emanuel schwarz'.

Page 1/2 | 1 2  | Next Page >

  • multiple columns per day with fullcalendar

    - by Emanuel Schwarz
    I want to show a scheduling plan for a couple of seminar-rooms, each of them in a seperate column, within a fullcalendar day view. So it schould look like a current fullcalendar week view but for every single day. Is there an obvious solution for this? And if not, where in the source should i start, what to go for, what to avoid? Some suggestions would be nice. Thanks Emanuel

    Read the article

  • lock screen before hibernating [12.04]

    - by Emanuel Ey
    So when i hibernate my laptop the screen doesn't lock automatically. To solve this if changed /etc/acpi/powerbtn.sh to contain: su - myUsername -c "gnome-screensaver-command -l" sudo pm-hibernate exit 0 When running this file from a command line it works as intended (ie, lock the screen and then hibernate). Unfortunately, when pressing the power button, it still just hibernates without locking the screen -what am I missing? EDIT: I've added the line whoami>>~/Desktop/test.txt to verify which user is executing the /etc/acpi/powerbtn.shscript. When pressing the power button, the file test.txt is created, but is empty. From this i conclude that the script is in fact being called when pressing the power button. What i do not understand is how the output of whoami can be empty...

    Read the article

  • How to change the date/time in Python for all modules?

    - by Felix Schwarz
    When I write with business logic, my code often depends on the current time. For example the algorithm which looks at each unfinished order and checks if an invoice should be sent (which depends on the no of days since the job was ended). In these cases creating an invoice is not triggered by an explicit user action but by a background job. Now this creates a problem for me when it comes to testing: I can test invoice creation itself easily However it is hard to create an order in a test and check that the background job identifies the correct orders at the correct time. So far I found two solutions: In the test setup, calculate the job dates relative to the current date. Downside: The code becomes quite complicated as there are no explicit dates written anymore. Sometimes the business logic is pretty complex for edge cases so it becomes hard to debug due to all these relative dates. I have my own date/time accessor functions which I use throughout my code. In the test I just set a current date and all modules get this date. So I can simulate an order creation in February and check that the invoice is created in April easily. Downside: 3rd party modules do not use this mechanism so it's really hard to integrate+test these. The second approach was way more successful to me after all. Therefore I'm looking for a way to set the time Python's datetime+time modules return. Setting the date is usually enough, I don't need to set the current hour or second (even though this would be nice). Is there such a utility? Is there an (internal) Python API that I can use?

    Read the article

  • Run mplayer from bash in background without extra bash

    - by Emanuel Berg
    I would like to watch a movie with mplayer from bash in the background, like I do with all programs and there has never been any problems: mplayer Kick* & if you'd like to see Kickboxer, for example. But, this doesn't bring up the window, instead it says the process is stopped. I can bring the movie window up with fg mplayer, but then the CLI is unavailable. (This is -- as far as I can see anyway -- equivalent to mplayer Kick*). I'm able to work around the problem like this: $(mplayer Kick*) & But then I get two extra bashes (I see this with ps). It is not really a problem as those closes down when I Alt-F4 the movie, but it is still undesirable. I guess I'm most annoyed with having to type that extra stuff, so if you come up with an alias or function, that would be OK, to. Although, it wouldn't hurt me to learn what's going on. Edit: Hm, it doesn't even seem to work the way I said. The "work"around is not reliable. Forget about it.

    Read the article

  • HTML tabindex: Put some links last without complete enumeration

    - by Emanuel Berg
    I know I can use the HTML anchor attribute tabindex to set the tabindex of links, i.e., in what order they get focused when the user hits Tab (or Shift-Tab). But, I have a home page with tons of links, and to enumerate all those is a lot of work. The actual case is, I have four image links that by default gets index 1, 2, 3, and 4 (well, the behavior is equivalent, at least). But, I'd much rather have the first non-image link as number 1. Check it out here and you'll understand immediately. I tried to give the first non-image link (the link I desire to have tabindex 1) - I tried to give it tabindex 1 explicitly, hoping that it would cascade from there, but it didn't (i.e., the first image link got implicit tabindex 2). I also tried to give the image links ridiculously high tabindexes, but that didn't work: as the other links didn't have tabindexes at all, those highs were still "first". As a last resort (the solution currently employed) I gave the image links all tabindex -1. That makes for logical tabbing, but, it is suboptimal, as those image links are excluded from the tab loop - a user tabbing away will probably never realize that the images are clickable. I'd like them to be reachable with tabbing, but last, after all the ordinary links. If you wonder why I'm so determined to achieve this, it has to do with my own finger habits: I almost exclusively search for links, tab back, tab forth, etc., and very seldom using the mouse. Note: I'll accept a script to change the actual HTML for a complete enumeration, if you convince me there is no "set" way to solve this problem.

    Read the article

  • How to lock screen in linux before hibernating?

    - by Emanuel Ey
    So when i hibernate my laptop the screen doesn't lock automatically. To solve this i've changed /etc/acpi/powerbtn.sh to contain: su - myUsername -c "gnome-screensaver-command -l" sudo pm-hibernate exit 0 When running this file from a command line it works as intended (ie, lock the screen and then hibernate). Unfortunately, when pressing the power button, it still just hibernates without locking the screen -what am I missing? EDIT: I've added the line whoami>>~/Desktop/test.txt to verify which user is executing the /etc/acpi/powerbtn.shscript. When pressing the power button, the file test.txt is created, but is empty. From this i conclude that the script is in fact being called when pressing the power button. What i do not understand is how the output of whoami can be empty...

    Read the article

  • Eclipse complains android:scrollbars and android:fadingEdge do not allow Strings - includes code.

    - by emanuel
    Having a problem in Eclipse with regards to an XML file. Eclipse complains that android:scrollbars and android:fadingEdge do not allow Strings. I checked the Android developer site and they do in fact accept strings in the xml file. A related question posed had the problem where there was a missing :android after xmlns. As you can see from the code the line beginning with xmlns is correct I believe. Here is the complete file contents: <?xml version="1.0" encoding="UTF-8"?> <com.example.todolist.TodoListItemView xmlns:android="http://schemas.android.com/apk/res/android" android:layout_width="fill_parent" android:layout_height="fill_parent" android:padding="10dp" android:scrollbars="verticle" android:textColor="@color/notepad_text" android:fadingEdge="verticle" />

    Read the article

  • C# HMAC Implementation Problem

    - by Emanuel
    I want my application to encrypt a user password, and at one time password will be decrypted to be sent to the server for authentication. A friend advise me to use HMAC. I wrote the following code in C#: System.Text.ASCIIEncoding encoding = new System.Text.ASCIIEncoding(); byte[] key = encoding.GetBytes("secret"); HMACSHA256 myhmacsha256 = new HMACSHA256(key); byte[] hashValue = myhmacsha256.ComputeHash(encoding.GetBytes("text")); string resultSTR = Convert.ToBase64String(hashValue); myhmacsha256.Clear(); How to decode the password (resultSTR, in this case)? Thanks.

    Read the article

  • How to disable "buy now" button in Google book preview popup window

    - by Emanuel
    I use Google Book API to display a book preview in my web page. This works fine, but I don't want to show "Buy now" button. For loading preview I use the following code: var viewer = new google.books.DefaultViewer(viewerCanvas, {showLinkChrome: false}); viewer.load(isbn); On the server this code does not work. I tried to save the page locally and when I opened it to my surprise the "Buy now" button disappeared. Why this not work on my server still I could not figure out. Any help is welcome. Thanks.

    Read the article

  • getting "implicit declaration of function 'fcloseall' is invalid in C99" when compiling to gnu99

    - by Emanuel Ey
    Consider the following C code: #include <stdio.h> #include <stdlib.h> void fatal(const char* message){ /* Prints a message and terminates the program. Closes all open i/o streams before exiting. */ printf("%s\n", message); fcloseall(); exit(EXIT_FAILURE); } I'm using clang 2.8 to compile: clang -Wall -std=gnu99 -o <executable> <source.c> And get: implicit declaration of function 'fcloseall' is invalid in C99 Which is true, but i'm explicitly compiling to gnu99 [which should support fcloseall()], and not to c99. Although the code runs, I don like the have unresolved warnings when compiling. How can i solve this?

    Read the article

  • How to determine the UID of a message in IMAP

    - by Emanuel
    I'm working in a mail client project using C#. I'm using both the POP and IMAP protocol to communicate with the server. The problem is than I can not figure out why when I want to get the UID for a message the result from the POP server and the IMAP server are different. POP C: UIDL 1 S: +OK 1 UID2-1269789826 and IMAP C: $ FETCH 1 (UID) S: * 1 FETCH (UID 2) S: $ OK Fetch completed. Why the result for obtaining the UID is so different? In IMAP is another function for this? Any help is welcome. Thanks.

    Read the article

  • Finisar SQLite Problem with ParameterDirection

    - by Emanuel
    private int GetNextId() { SQLiteConnector conn = new SQLiteConnector(false); conn.OpenConnection(); cmd = new SQLiteCommand("SELECT @id_account = MAX(id_account) FROM account"); SQLiteParameter param = new SQLiteParameter("@id_account", DbType.Int32); param.Direction = ParameterDirection.Output; cmd.Parameters.Add(param); cmd = conn.ExecuteReadeOutput(cmd); conn.Close(); return int.Parse(cmd.Parameters["id_account"].Value.ToString()) + 1; } ... public SQLiteCommand ExecuteReadeOutput(SQLiteCommand cmd) { conn.Open(); cmd.Connection = conn; reader = cmd.ExecuteReader(); reader.Close(); return cmd; } When I call the method GetNextId() occur the following error: Specified argument was out of the range of valid values. at line: param.Direction = ParameterDirection.Output; Any idea? Thanks.

    Read the article

  • C# Finisar SQLite DateTime Comparison Problem

    - by Emanuel
    My "task" database table look like this: [title] [content] [start_date] [end_date] [...] [...] [01.06.2010 20:10:36] [06.06.2010 20:10:36] [...] [...] [05.06.2010 20:10:36] [06.06.2010 20:10:36] And I want to find only those records that meet the condition that a given day is between start_date and end_date. I've tried the following SQL expression: SELECT * FROM task WHERE strftime ('%d', start_date) <= @day AND @day <= strftime ('%d', end_date) Where @day is an SQLiteParameter (eq 5). But no result is returned. How can I solve this problem? Thanks.

    Read the article

  • Start a short video when an incoming call is detected, first case using the emulator.

    - by Emanuel
    I want to be able to start a short video on an incoming phone call. The video will loop until the call is answered. I've loaded the video onto the emulator sdcard then created the appropriate level avd with a path to the sdcard.iso file on disk. Since I'm running on a Mac OS x snow leopard I am able to confirm the contents of the sdcard. All testing has be done on the Android emulator. In a separate project TestVideo I created an activity that just launches the video from the sdcard. That works as expected. Then I created another project TestIncoming that creates an activity that creates a PhoneStateListener that overrides the onCallStateChanged(int state, String incomingNumber) method. In the onCallStateChanged() method I check if state == TelephonyManager.CALL_STATE_RINGING. If true I create an Intent that starts the video. I'm actually using the code from the TestVideo project above. Here is the code snippet. PhoneStateListener callStateListener = new PhoneStateListener() { @Override public void onCallStateChanged(int state, String incomingNumber) { if(state == TelelphonyManager.CALL_STATE_RINGING) { Intent launchVideo = new Intent(MyActivity.this, LaunchVideo.class); startActivity(launchVideo); } } }; The PhoneStateListener is added to the TelephonyManager.listen() method like so, telephonyManager.listen(callStateListener, PhoneStateListener.LISTEN_CALL_STATE); Here is the part I'm unclear on, the manifest. What I've tried is the following: <?xml version="1.0" encoding="utf-8"?> <manifest xmlns:android="http://schemas.android.com/apk/res/android" package="com.example.incomingdemo" android:versionCode="1" android:versionName="1.0"> <application android:icon="@drawable/icon" android:label="@string/app_name"> <activity android:name=".IncomingVideoDemo" android:label="@string/app_name"> <intent-filter> <action android:name="android.intent.action.ANSWER" /> <category android:name="android.intent.category.DEFAULT" /> </intent-filter> </activity> <activity android:name=".LaunchVideo" android:label="LaunchVideo"> </activity> </application> <uses-sdk android:minSdkVersion="2" /> <uses-permission android:name="android.permission.READ_PHONE_STATE"/> </manifest> I've run the debugger after setting breakpoints in the IncomingVideoDemo activity where the PhoneStateListener is created and none of the breakpoints are hit. Any insights into solving this problem is greatly appreciated. Thanks.

    Read the article

  • Eclipse complains android:scrollbars and android:fadingEdge do not allow Strings.

    - by emanuel
    Having a problem in Eclipse with regards to an XML file. Eclipse complains that android:scrollbars and android:fadingEdge do not allow Strings. I checked the Android developer site and they do in fact accept strings in the xml file. A related question posed had the problem where there was a missing :android after xmlns. As you can see from the code the line beginning with xmlns is correct I believe. Here is the complete file contents:

    Read the article

  • Why Internet Explorer can not display an image on the site?

    - by Emanuel
    I have a site that is managed with Joomla. I want to display an image in one of my articles but that image can not be viewed in Internet Explorer but other browsers can display it, although the path is ok. I miss something? Link: http://ascorbrasov.ro/images/stories/necula_ctin2.jpg Html: <img src="/images/stories/constantin_necula2.jpg" border="0" title="Constantin Necula - Conferinta" /> Thanks

    Read the article

  • How to hide first item from an Html Select Tag

    - by Emanuel
    I have the following code: <select> <option value="0">Option 0</option>. <option value="1">Option 1</option> <option value="2">Option 2</option> </select> When you click on select I wish the first item to be no longer listed. Also it must work on all browsers. How can this be done? Thanks.

    Read the article

  • How to display data uri scheme into a C# WebBrowser Controler

    - by Emanuel
    How can I show an image base64 encoded using WebBrowser control in C#? I used the following code: <img src="data:image/gif;base64,/9j/4AAQSkZJRgABAgAAZABkAA7AAR R894ADkFkb2JlAGTAAAAAAfbAIQABAMDAwMDBAMDBAYEAwQGBwUEBAUHCAYGBw ... uhWkvoJfQO2z/rf4VpL6CX0Dts/63+FaS+gl9A7bP+tthWkvoJfQODCde4qfcg RiNWK3UyUeX9CXpHU43diOK915X5fG/reux5hUAUBftZ" /> but no image is displayed. One solution would be to save images locally and using absolute path, but this is not desirable. Any idea? Thanks.

    Read the article

1 2  | Next Page >