key

DefaultButton in ASP.NET forms

What is the best solution of defaultButton and "Enter key pressed" for ASP.NET 2.0-3.5 forms? ...

Cryptography algorithm

I'm making a simple licensing system for my apps. I don't know about cryptography, but I know that I need a algorithm that consists of 2 keys: private and public. I need to encrypt some data (expiration date and customer email) using my private key, and then my app will decrypt the data using the public key to compare expiration date. ...

How to check for key being held down on startup in Java

I'm trying to write a resolution selection dialog that pops up when a program first starts up. To prevent boring the user, I want to implement the fairly standard feature that you can turn off that dialog with a checkbox, but get it back by holding down the alt key at startup. Unfortunately, there is no obvious way to ask java whether a...

What dotnet collection class's items can be enumerated in "addition order" and retrieved via a key?

I'm lead to believe that I cannot count on the order of items added to a dictionary for enumeration purposes. Is there a class (generic if possible) to which items may be added with a key and which can be enumerated in addition order or which can be retrieved by key? Clarification: I do not want to enumerate in Key Order. I want to enu...

Display the meta/control key in a JLabel

We want to show a hint for a JList that the user can select multiple items with the platform dependent key for multiselect. However I have not found any way to show the OS X COMMAND symbol in a JLabel, which means the symbol that's printed on the apple keyboard on the command key, also called apple key. Here's a picture of the symbol ...

Jerky movement in WPF

Hey guys/gals, I've got a canvas that's 800x600 inside a window that's 300x300. When I press a certain key, I want it the canvas to move in that direction. I've done this inside the window's code behind: protected override void OnKeyDown(KeyEventArgs e) { base.OnKeyDown(e); Key keyPressed = e.Key; ...

making a programme run indefinitely in python

Is there any way to make a function (the ones I'm thinking of are in the style of the simple ones I've made which generate the fibonnacci sequence from 0 to a point, and all the primes between two points) run indefinitely. E.g. until I press a certain key or until a time has passed, rather than until a number reaches a certain point? ...

Does RSA Private key always contain the Public key, or is it just .NET?

Hi everyone. I'm using RSACryptoServiceProvider in .NET 2 and it seems that the Private part of a Public/Private key pair always contains the Public part as well. I need to encrypt some info using my Public key, and allow the other party to ONLY DECRYPT what I encrypted. I don't want them to be able to know how I encrypted my message. ...

How to prevent a Winforms control from listening to the keyboard ...

For a certain inputform, I'd like to make it possible to do input with the keyboard. I know how to read the keys through KeyPressed and KeyUp, but the problem is that when a control has got the focus and the user presses the Enter key, that control receives the a Click event. Is it possible to prevent that behaviour ? Or is it possibl...

Are Windows DLLs signed by Microsoft? Can I detect if they've been tampered with by a third party?

Hi everyone. I'm implementing a locking and copy protection system for my software. I've shut every hole that would allow someone to break my lock (well, that's a little too optimistic, I know!) but the last thing is this: I hear crackers can change Windows DLLs like Kernel32.dll in a way that the API I use returns a value which is spe...

Sorting an array of an array of objects in PHP by key value

Basically I have a setup like the following: Array ( [0] => Array ( [0] => stdClass Object ( [nid] => 1 [title] => title1 [uid] => 1 [parent] => 0 [weight] => -15 [name] => name1 [value] => 0 ) [1] => stdClass Object ( [nid] => 2 [title] => title2 [uid] => 1 [parent] => 0 [weight] => -7 [name] => name2 [value] => 100 ) ...

MakeCert - Is it possible to change the key size?

When i generate a Certificate using MakeCert.exe I want to change the key size from 1024 to 2048. Is this possible? Or do i need to setup a Certificate Authority? Cheers Rohan ...

Signing XML with Public Key Example?

I'm working to implement a SAML service. As such, I believe the identity provider is supposed to digitally sign the SAML assertion using the service provider's public key before sending the assertion to the service provider (which the service provider verifies using their private key). However, I'm having a hard time finding any exampl...

Keys in SQL Server are Global - Why?

Indexes and Constraints in MS SQL Server are local to the table they are defined in. So you can create the same index or constraint name in more than one table with no trouble. Foreign Key Constraints (which as everyone should know are NOT keys, but constraints) will appear in the Keys subfolder and their names appear to be globally sc...

How do you write in JavaScript a empty key from JSON?

Hello todos! Let's say you have the following JSON object {"":"some text"} How do you retrieve it in JavaScript? json_in_var={"":"some text"} alert(json_in_var.) I'm perplexed on this one, any help welcome! ...

ADO Entity Framework creating unwanted Entity Key

Hi, I need to use tables from a DB which I cannot alter (using linked server). So part of my schema is a view on these table and I cannot create an FK in my DB. When I come to creating the association in ADO.NET Entity Framework I am getting problems because a second column on the table from the external DB has an index on it and the EF...

What is the maximum size of a web browser's cookie's key?

I'm wondering what the maximum size of a web browser's cookie's key is. I know the maximum size of a cookie is 4KB, but does the key have a limitation as well? Thanks! ...

C# How do disable a key

How do I prevent the caret to go to the next line when the 'ENTER' key has being pressed on a text-box? In other words how to disable the 'ENTER' or 'RETURN' key on a text-box? ...

implementation for product keys

Hi there, I'm implementing a small application in C, which I would like to sell as shareware for a reasonable price later on. It will start of with a 30-day trial, which I am already quite certain of how to implement it. The problem I have, though, is that I am not quite sure how to implement the product key verification. What I have i...

where is private key?

Hi guys, Two simple questions about makecert command, Suppose I am using the following command, makecert -n "CN=PowerShell Local Certificate Root" -a sha1 -eku 1.3.6.1.5.5.7.3.3 -r -sv root.pvk root.cer -ss Root -sr localMachine my confusion is, will private key automatically registered somewhere in cerficate manager or the private...