How do you check if a username contains invalid characters?
I want to restrict each users username with PHP to having numbers, letters, and underscores.
Hi,
Is there an easy way of adding copy-paste for a listview, or should I just switch to DataGridView instead?
My application is kinda like an address book, it contains emails, numbers etc where copy paste would be useful.
Any recommendation of a Fax server to use in Windows? Looking for good API support for incoming faxes. (Lots of them are good for outgoing). I want to route incoming faxes to email programmatically after the server gets the fax and set Whitelist of phone numbers to filter spam - all in code.
Greetings P4 folks,
I am trying to understand the P4 describe -ds output. I am assuming that this is the same as the p4 diff -ds output.
Here is an example of the "Differences ..." block:
==== //depot/Groups/mygroup/trunk/main/FooBar.java#5 (text) ====
add 7 chunks 13 lines
deleted 1 chunks 1 lines
changed 16 chunks 92 / 118 lines
~
Now I understand that add and deleted lines are clear but why are there two numbers for the changed lines (92 / 118).
Thanks!
- JsD
In WPF it is easy to use a ValueConverter to format values etc, (in our case convert some numbers into a different unit, e.g km to miles)
I know it can be done in Winforms, but all my Googleing just brings up results for WPF and Silverlight.
Hi there!
Does anyone know a 100% clone of the C/C++ printf for Delphi?
Yes, I know the System.Format function, but it handles things a little different.
For example if you want to format 3 to "003" you need "%03d" in C, but "%.3d" in Delphi.
I have an application written in Delphi which has to be able to format numbers using C format strings, so do you know a snippet/library for that?
Thanks in advance!
Hey guys,
I got 2 tables in my database: user and call. User exists of 3 fields: id, name, number and call : id, 'source', 'destination', 'referred', date.
I need to monitor calls in my app. The 3 ' ' fields above are actually userid numbers.
now i'm wondering, can i make those 3 field foreign key elements of the id-field in table user?
Thanks in advance...
I'm looking for a regex to only match words, possibly including numbers, and possibly with an apostrophe at the beginning, middle, or end; and ignore everything else.
So these would be matched verbatim:
'bout
it's
persons'
But these would be ignored:
'
''
However, for words like 'open', open should be matched.
Related question: http://stackoverflow.com/questions/199333/best-way-to-detect-integer-overflow-in-c-c
In C code, should integer overflow be addressed whenever integers are added? It seems like pointers and array indexes should be checked at all. When should integer overflow be checked for?
When numbers are added in C without type explicitly mentioned, or printed with printf, when will overflow occur?
Is there a way to automatically detect when an integer arithmetic overflow?
Does anyone know of an Objective-C framework that takes care of registering an app? I'm interested in the GUI/30-day trial side more than the actual verifying of serial numbers.
Hello everyone,
I have implemented FIFO semaphores but now I need a way to test/prove that they are working properly. A simple test would be to create some threads that try to wait on a semaphore and then print a message with a number and if the numbers are in order it should be FIFO, but this is not good enough to prove it because that order could have occurred by chance. Thus, I need a better way of testing it.
If necessary locks or condition variables can be used too.
Thanks
I have a file that contain list of numbers that looks like this:
10^-92
2 10^-14
10^-105
3 10^-20
To explain a bit further 10^-92 is essentially 1E-92 and 2 10^-14 is 2E^-14.
Is there a compact way to convert the number in above file into Perl number? At the end I want to sort these number numerically.
Is there an equivalent to an identity Seed in SimpleDB?
If the answer is no, how do you handle creating something like a customer number or order number that will prevent the creation duplicate numbers?
My experience is mainly from SQL Server in which I would either create a primary key with an identity seed or use transactions in a stored procedure to increment the number.
Thanks for your help!
I currently have this line of code which has been working for the past 6 months:
If IsNumeric(txtProductID.Text) Then
...do stuff
Else
Dim msg As String = "Error!"
End If
All of the sudden, no matter what kind of entry is put in txtProductID (including plain numbers), it fails! Is there reason for me to be going crazy over this?
Hello, everyone)
I'm new in Java world and I'm tottaly confused with numbers of java server-side technology.
I need to build application with Java on server side and Flex-AIR on client one. All communication between them must be on sockets and in AMF format.
Can you please help me to choose right to technology to learn?
hello,
i have this crazy label for each time i create a migration that use the time instead of a integer. it makes things very hard to switch between the version of the database that you want to use.
i also have this crazy ID for each object that i create :
How can set up rails to have easy version and id numbers.
thank you
hi there,
i am working on an application that uses the Google Analytics Export API and i am trying to get the "Trend" result that Google shows against each of your site accounts as a percentage
ie UP 35.04% or DOWN 16.02%
How/where do they get this figure and is it available in the API somewhere.
i have tried comparing averages of last month to this month/first week of the period vs last week of the period etc, but i cannot seem to get the same numbers that Google provides.
any ideas?
thanks in advance
Doug
I've noticed that on some websites (including SO) the link to the CSS will look like:
<link rel="stylesheet" href="http://sstatic.net/so/all.css?v=6638">
I would say its safe to assume that ?v=6638 tells the browser to load version 6638 of the css file. But can I do this on my websites and can I include different versions of my CSS file just by changing the numbers?
For example, these are valid math expressions:
a * b + c
-a * (b / 1.50)
(apple + (-0.5)) * (boy - 1)
And these are invalid math expressions:
--a *+ b @ 1.5.0 // two consecutive signs, two consecutive operators, invalid operator, invalid number
-a * b + 1) // unmatched parentheses
a) * (b + c) / (d // unmatched parentheses
I have no problem with matching float numbers, but have difficulty with parentheses matching. Any idea? If there is better solution than regular expression, I'll accept as well. But regex is preferred.
Does merge sort work by;
taking a list of values
splitting it in to two
take the first element of each list, the lowest value one goes in to a new list(and i guess removed from the original). comare the next two numbers - do this until one list is empty, then place the rest of the other list at the end ofthe nw list?
Also, what are the ramifications of doing this on a linked list?
Thanks
I am looking for a regex to validate a string. I want to allow numbers, alpha characters, spaces and any of the following characters in any order:
+ - ( ) ,
Thanks.
Using Big Oh notation, which sorting algorithm takes minimum amount of time to sort the following numbers:
9834,
343,
902,
23922,
7233,
82,
299,
23,
4454,
2342,
992,
389.
hello.
my Perl scripts gets a udp response that is built out of 2 integers + float numbers.
the problem is that the udp streams is one long stream of bytes.
how do i cast the stream into parameters using Perl ?
Does Actionscript have a built-in function that accepts a number and can return a Boolean if this number is between 2 numbers.
For example
3 is between 2 and 6 //returns true
5 is between 10 and 20 //returns false
Hello , i was just wondering, is there any way in MIPS to store a summation of numbers as a string and later read them byte by byte, for example:
the sum 657 - sw into a .ascii directive - later lb on the first index to get 6 (in ascii code) same with 5 and so on
Is this possible ?
//Thx in advance