Hannes

1

votes
0

answer
99

views

Mapping Unicode character to key code in Rust using Core Foundation

I have a Unicode representation of a key, e.g. 'a', '!', 'ä' or '€', and I want to find out what key code (sequence) is used to produce that character. The resulting virtual key code will be given to CGEventCreateKeyboardEvent to simulate keyboard events. The solution must be keyboard layout inde...
Hannes Karppila
2

votes
1

answer
229

views

Numerical approximation of planetary orbit

I want to simulate the Moons orbit around the earth(fixed position) by using Eulers approximation. How do i programm this correctly so that im getting an ellpise-like orbit? I've already tried Eulers approximation by calculating Moons current acceleration when he's at the Periapsis(shortest distance...
Hannes Hauser
1

votes
0

answer
2k

views

WKWebview scale html content to fit in width and height

I have an formatted HTML string and want to load it in a wkwebview and scale it so that it fits in height and width of the wkwebviews frame. I have already tried playing around with adding a viewport to the HTML but I just managed it to scale in widht but not to the height. var test = '* {margin:0;p...
Hannes Gant
1

votes
1

answer
156

views

Minimum Spanning Tree of weighted graph

I need to write a predicate that creates a minimum spanning tree of a weighted undirected graph, using Prim's Algorithm. This is what I have so far: % call the recursive predicate with the list of all nodes and % one element (in this case the last one). mst(T) :- nodes(N), last(N,E), mst(T,N,E)....
1

votes
1

answer
82

views

Does GCS list objects in lexicographical order?

The S3 documentation explicitly states GET Bucket (List Objects) returns keys in lexicographical order. https://docs.aws.amazon.com/AmazonS3/latest/API/v2-RESTBucketGET.html (search for 'lexicographical') For GCS I found anecdotal evidence of alphabetical ordering here on SO but I cannot find anythi...
Hannes
1

votes
1

answer
36

views

PHP Prepared Statements; Weired Result

I try to implement a newsletter function in PHP. When a user subscribes on our website, a verification e-mail gets send to them. If they have already subscribed, they get a message displayed like: 'you have already subscribed' or 'E-Mail already registered, but not verified. The e-mail was resent. f...
Hannes Keks
1

votes
0

answer
19

views

DateTime deserialization

I am having some troubles deserialzing a json string. I am getting following string from my db {'myobject':{'Make':null,'Model':null,'StartVin':null,'KerbWeight':null,'Engine':null,'TrimLevel':null,'SafetyPack':null,'BodyType':null,'FullDescription':null,'ReleaseDate':'0001-01-01T00:00:00','HandOfDr...
Hannes
1

votes
1

answer
82

views

Scheduler for materialized views Postgresql + Redshift

What I want is to update a table every night and cache it so it doesn't have to run each time we run a query based on it. So I figure I need a materialised view (not a view). Top answer to below question is spot on what I need. How can I ensure that a materialized view is always up to date? So, I se...
Hannes
1

votes
1

answer
149

views

google appmaker filter dropdown

I just started with Google AppMaker and I'm having some trouble understanding how the query builder works. Here is my scenario: I have three data sources: Customer: Name Project Name Customer Milestone Name Customer Project Now, I have set up relationships between these models, so that: One Project...
Hannes Siefert
1

votes
1

answer
156

views

Bogus.Faker: How to pick a random enum value

I'm using c# Bogus.Faker library to create random test data for my unit tests. I want to know how to easily pick a random enum value ? Any suggestions?
hannes neukermans
1

votes
1

answer
82

views

Connect to two Bluetooth Devices with same UUID simultaniusly

i try to create an Android App that connects to two Bluetooth HC-05 Modules (which are connected to an Arduino). I am able to connect to both of them and if i only send Data to one of them everything works fine, if im sending Data to both however it might work for some Time but than it stops sendin...
Hannes
1

votes
0

answer
94

views

Run react app in electron but not on localhost

Is there any way to prevent accessing the app through localhost? It should only be seen inside the electron app so if you navigate to localhost:3000 it should display 'Can't reach website'. At the moment npm start calls 'start': 'concurrently \'cross-env BROWSER=none yarn react-scripts start\' \...
Hannes G
1

votes
0

answer
26

views

Message queuing per tenant

I have an API where clients submits jobs asynchronously which can easily be divided into many smaller tasks. Sometimes we receive more jobs than we can process real time and therefor I want to have a job queue for each client so that I can round robin process jobs between clients. This is so that if...
Hannes Kindströmmer
1

votes
0

answer
101

views

Building a JavaFX application

In Java 8 times I created a JavaFX application which I now wanted to port and build with Java 11. First thing I did was creating a module-info.java and adding the required libraries. Than I added OpenJFX dependencies to gradle.build: sourceCompatibility = JavaVersion.VERSION_11 targetCompatibility =...
Hannes
1

votes
1

answer
132

views

uiautomatorviewer location of file “Error obtaining UI hierachy”

I played around in uiautomatorviewer with the most left and most right button, if I can save something here It seams I was able to specify a file here, but now it disclaims about a missing file in stacktrace I see $ uiautomatorviewer java[31120:588009] dataFromGeneratingCandidatesForSelectedRange...
hannes ach
1

votes
0

answer
43

views

Jigsaw: Bundling JRE with Automatic Modules

Is there a way to bundle the JRE with jlink if not all or even none of the application's dependencies are yet modularized? I do understand that this does not lead to trimmed runtimes but still, I want to bundle a JRE with my application, even untrimmed.
Hannes
1

votes
2

answer
459

views

Catching exception when using Response object in Flask does not work

I am trying to catch an exception when using a Response object. My use case is that I want to stream data like described in the official documentation and that there is the possibility of an exception when I get the data that I want to stream: # test.py from flask import Flask, Response, jsonify im...
Hannes
1

votes
1

answer
49

views

Using Webfeed in Flutter

I am developing an app in flutter where I want to show an RSS feed with the webfeed plugin. I am following the example exactly, but the only thing that is printed is: Instance of 'RssFeed' Shouldn't it print the whole RSS feed? Or have I understood something wrong? The code: import 'package:flutter/...
1

votes
2

answer
2k

views

How do I use a 32 Bit COM object from a 64 bit process?

I Use Jacob (JAVA COM Bridge) on a 64 Bit Machine and want to load COM Objects from a 32 bit DLL. How can I do that?
Hannes de Jager
1

votes
1

answer
1.2k

views

How to make Linq extension methods available on ObservableCollection<T>

I've written a class that inherits from ObservableCollection. I would like to be able to use the LINQ extensions methods like FirstOrDefault, like what you may get if you inherit from an implementation of IEnumerable, or List. How would I accomplish this?
Hannes Nel
1

votes
1

answer
2.1k

views

How to determine if a machine is running Active Directory

I would like to know from Java code if the machine that I'm on is running active directory or that it has active directory installed (e.g. service may be stopped). Is there a reliable registry key to inspect? This is specifically for Windows 2008. I found info on the web that mentions HKLM\SOFTWARE\...
Hannes de Jager
1

votes
1

answer
223

views

Can I access an ESE database that is already in use?

The windows ESE engine API call JetAttachDatabase have a readonly option. Can I use this to mount a database that is already mounted by another process?
Hannes de Jager
0

votes
0

answer
3

views

OpenAPI 3 - Reuse of properties

Following the example of an OpenAPI 3 definition: components: schemas: Foo: properties: string: type: string enumField: type: string enum: ['VALUE_1', 'VALUE_2'] Bar: properties: enumField: type: string enum: ['VALUE_1', 'VALUE_2'] Is there a way to reuse enumField or do I have to specify it every t...
Hannes
1

votes
1

answer
666

views

HTML Converter abandoned in Java 7?

It's not longer there in the bin folder of Java 7. Do I go with the tag again? What about messages if Java is not installed? It is strange that this is omitted now, have to change the build process then.
Hannes Licht
1

votes
2

answer
1.4k

views

Custom web.config for asp.net web part in sharepoint 2010

Base: I have created a ASP.NET web part to be deployed to a Sharepoint 2010 site. This web part is using a external web service, a WCF service that is hosted else where, not on the same machine as the Sharepoint site. The web parts are installed on the sharepoint server using a CAB-file that is crea...
hannes larsson
1

votes
1

answer
62

views

CusotomSwitch draw as Button

I'm writing a CustomSwitch. It is extended from Switch. Under some circumstances in the onDraw() method, I want to draw the CustomSwitch as a Button. I tried several approaches, but neither did work. I can't call ((Button)this).draw(canvas); in the onDraw() cause thats going to result in a stack ove...
Angelo.Hannes
1

votes
2

answer
2.1k

views

Rename namespace prefixes with XQuery (Update)

The following problem can easily be solved with text processing tools and languages, but this is not how it should be done I guess.. What’s the cleanest and cheapest approach to rename namespace prefixes in a large XML document with XQuery (Update)? Source: The result I’d like to get: Any ideas...
Hannes Bauer
1

votes
3

answer
4.3k

views

Magento: Moved Multistore - new store always redirect to old domain, although new base_url

I have moved a Multistore to another webserver with the following structrue: mystore.com --> Magento Multistore installation flowers.website.com --> symlinks to mystore.com folder cars.website.com --> symlinks to mystore.com folder The new setup is completely the same (only different domains and fol...
Hannes P
1

votes
1

answer
3.4k

views

iOS URL scheme twitter://user?screen_name=SCREEN_NAME not working anyomre

I want to redirect the user of our iOS App to our Twitter profile page with the URL scheme: twitter://user?screen_name=SCREEN_NAME I recently noticed that this opens the Twitter app as expected but it shows a screen as if I used it for the first time: The app is also completely frozen, I can't touch...
Hannes
1

votes
1

answer
1.3k

views

Bootstrapping an Swing application

I know to some of you it might sound ancient but I am currently developing an fat client using Swing for the user interface and Spring as a framework behind the scenes. Is there any good tutorial explaining how to launch, initialize and shot-down a Swing application? I saw there is a JSR 296 but it...
Hannes
1

votes
1

answer
352

views

Make ViewModel property available for binding to IsChecked

I'm using Caliburn.Micro in my app. What I want to do is: Create one RadioButton per available licence in the View Check the one whose licence is currently active So far I have two properties on my ViewModel (I'm leaving out INotify...Changed and its implementations here because that works): Bindabl...
Hannes
1

votes
1

answer
100

views

import User Profile SQL Database to Windows Azure

Im a beginner that is thrying to setup my first website in Windows Azure. I have published it and made a Sql database inside Windows Azure. In my local virtual machine I have SQL management studio that contain a User profile database. Is there a way to export that one and import to Azure?
Hannes
1

votes
2

answer
43

views

Trying to remove duplicate entries in MySQL database with a twist

First off, I'm a nooob. I've got a Database Table with lots of duplicate rows. I created a new clean database table (ufx_multicity) and tried the following command in MySQL to copy all the rows from the old database table (ufx_multicity2) and to ignore the duplicate entries. INSERT INTO ufx_multicit...
Hannes Jordaan
1

votes
2

answer
29

views

How do I model different informations into an object?

I want to let a user choose different Payment Methods. So I have a class that describes a payment method. public class PaymentMethod { private int id; private String name; private String description; //Constructors, Accessors... } Now I have a bean holding the choice of the user public class OrderBe...
Angelo.Hannes
1

votes
1

answer
57

views

Swappable CSS theme with jQuery event handler

I'm trying to create a simple swappale CSS theme with a jQuery event handler. As you can see, I was able to modify .outer but I don't know how to style the spans. The default theme doesn't need further customization, but I would like to change the color/size of the spans and apply a hover effect, et...
Hannes
1

votes
1

answer
390

views

What is the reason for specifying Django URL-Namespaces in the sites url.py?

I'm starting with Django and what puzzles me is the specification of the URL-namespaces. As far as I understand, you specify them in the site projects urls.py, like this: urlpatterns = patterns('', url(r'^polls/', include('polls.urls', namespace='polls')), url(r'^admin/', include(admin.site.urls)),...
Hannes Niederhausen
1

votes
1

answer
540

views

Why is this happening? (SharpFont / Monogame Error)

I'm trying to get a MonoGame texture from a FreeType (SharpFont) bitmap. If I use Bitmap.ToGdipBitmap, it works fine, but that seems very inefficient and hacky. When I try to convert it myself I get a System.ArgumentException (Source array was not long enough). The code for Bitmap.ToGdipBitmap looks...
Hannes Mann
1

votes
5

answer
2.9k

views

Some Font Awesome icons are not shown in Firefox, how to debug?

Edit: solved, see answer below. I am using several JavaScript-libraries (some of them come with CSS and web fonts) along with Font Awesome. FA is installed locally via Bower, so there are no attempts to cross-site requests made. Everything works fine in Chrome and IE, but on Firefox there are some i...
Hannes Ebner
1

votes
1

answer
132

views

Howto avoid MSIE scrolling a table with overflow: hidden;

The last column of a table is intentionally clipped without scrollbars, by using overflow: hidden; on the Tables container. If I enter the columns input field by pressing Tab, on MSIE it scrolls the focused column into the viewport. I would like to turn this feature off and make it similar to FF wh...
Hannes
1

votes
1

answer
1.3k

views

Upload video with TwitterKit on iOS

I'm trying to upload a video via the iOS TwitterKit (latest version). Uploading an image works fine, initializing the video upload as well (receiving a media_id), but I'm getting an Auth error Error Domain=TwitterAPIErrorDomain Code=32 'Request failed: unauthorized (401)' when trying to upload my fi...
Hannes

View additional