Click here to Skip to main content
14,923,376 members

Comments by Peter_in_2780 (Top 200 by date)

Peter_in_2780 4-Jun-21 1:48am View
Oops! You should have replied to my comment, rather than added another comment to your question. Just by luck that I saw this.
I'm not sure what your criteria are for matching. Can you express it in words? Obviously the string 'fehler' is involved, but what distinguishes 1 and 2 from 3 and 4?
Peter_in_2780 2-Jun-21 18:58pm View
Look at CSS properties min-width, max-width, min-height, max-height.
But beware, they can do some very peculiar things to a responsive layout.
Peter_in_2780 1-Jun-21 8:12am View
[^ ] will match any character except a space, if that is part of what you're looking for.
Peter_in_2780 30-May-21 22:48pm View
So you have found some code on the internet, and you don't understand it.
One of your problems is that you haven't bothered to search for "Greatest Common Divisor" and read the description of the algorithm.
Then, when you do understand how it works, you could find the bug(s) in the code you grabbed.
Peter_in_2780 30-May-21 4:11am View
Loops in PHP can easily do what you want. Work your way down a list of images or whatever, emit the boilerplate code to display each one. As you do so, figure out a way of linking the buttons to the right modals (such as indexing them...)
It's not difficult.
Peter_in_2780 17-May-21 2:36am View
Provided the account has appropriate permissions, it can do anything...
cp -a * /home/victim/
will quite happily clone all my files into his space.
Variants of this have been used in various places as an el-cheapo backup
Peter_in_2780 28-Mar-21 3:06am View
"I want code for ..."
That's not what this site does. We'll try to help you with problems in your code, but we're not here to provide packages of code.
Peter_in_2780 27-Mar-21 3:09am View
Use the console to see what files are fetched during page load. Those few lines are quite likely in another file you forgot about.
Peter_in_2780 20-Mar-21 1:22am View
And what line of what file produces the error? Update the question.
Peter_in_2780 16-Mar-21 20:48pm View
"Unexpected end of file" is almost always a missing delimiter, usually }
You do use a syntax highlighting editor, right?
Check that every { has a matching } IN A PHP CONTEXT
and that every <?php has a ?>
Peter_in_2780 4-Mar-21 1:21am View
The largest integer type commonly supported is "long long", usually 64 or 128 bits. Nowhere near big enough for you!
Search for "c++ bigint" to find arbitrary precision packages.
Peter_in_2780 18-Feb-21 22:06pm View
My guess is that all the spaces after B_ shouldn't be there. Try removing them.
Peter_in_2780 17-Feb-21 2:22am View
Also, whitespace in HTML is not significant in the final layout. Put as many spaces, tabs, newlines as you like, it'll only render one space.
Peter_in_2780 17-Feb-21 2:20am View
I'm not sure exactly what you are after, but in that situation I'd use a 2-column table. Browsers are very smart at laying out tables. You can control text alignment per-column.
Peter_in_2780 9-Feb-21 22:25pm View
That's wandering into croc-infested territory. Disappearing an item when you hover over it....
Peter_in_2780 4-Feb-21 19:09pm View
You can use the same page to initiate the upload (the "form" stuff) and process the upload (handling $_POST and $_FILES) but it is much easier to see what is going on if you separate them. For example you can (for testing) put
at the start of the processing page to see exactly what you are getting. In the whole process you need to understand what is happening where and when, on the client and host.
Peter_in_2780 4-Feb-21 0:24am View
Just a suggestion. Separate the numbers and units into two adjacent textboxes.
Peter_in_2780 30-Jan-21 21:23pm View
First thought from the land of the bleeding obvious... Integers are not what you want for this kind of arithmetic. Doubles would be far more useful.
Peter_in_2780 26-Jan-21 23:48pm View
Read the message: Exited with status 137 (out of memory)
Look for memory leaks, ridiculous memory allocations, ...
Peter_in_2780 25-Jan-21 20:25pm View
I don't know how your Ribbon Workbench expects to wire up event handlers. I work with HTML and Javascript at the lowest level, so I'd write

<button id="mybutton" ... ... onclick="myJSfunc(args)" ... >

and I'd manipulate the button's disabled property directly

document.getElementById("mybutton").disabled = true;
Peter_in_2780 12-Jan-21 21:41pm View
I know nothing about the Cortex chips, but systems I worked on half a lifetime ago had special instructions to write "bad" data to memory, so that the factory and service people could test the ECC data paths, hardware error logging and so on.
Peter_in_2780 7-Dec-20 21:12pm View
Have you investigated ALSA? I think it can do what you want, but I haven't tried it myself.
Peter_in_2780 7-Dec-20 19:48pm View
SMS stands for *SHORT* Message Service. An SMS message is limited to 160 characters (if entirely alphanumeric).
Peter_in_2780 1-Nov-20 18:46pm View
For starters, count brackets (or use an editor that matches them).
Take a hard look at the line the causes the error.
Peter_in_2780 27-Oct-20 3:56am View
You still have the "pipe" class name. DOM elements can have multiple class names attached.
Did you take a close look at the solution?
Peter_in_2780 26-Aug-20 7:42am View
if (($dest !~ /^R\d+\.\d/) || ($dest !~ "/^[\w_]+/R\d+\.\d/")){

Just before the second R you have a spurious /
Peter_in_2780 19-Jul-20 1:28am View
Use "paste as ... CODE BLOCK", then we might have a chance to see your code.
Peter_in_2780 18-Jul-20 21:51pm View
If asp:TextBox translates to an html input item, then the content is accessed as .value, not .innerText. Your alert give you the clue - innerText is UNDEFINED, not a null string.
Peter_in_2780 15-Jul-20 0:59am View
At least the first three results from searching "javascript reload page" tell you exactly how.
Peter_in_2780 30-Jun-20 0:42am View
Answering your second question, 3(n/2)^3 is O(n^3), i.e. polynomial in n. The constants (which evaluate to 3/8) don't matter in big-O notation.
Peter_in_2780 6-May-20 2:47am View
Ugly, brute force approach: Get the "11" as you did, then count the delimiters in that much of the input string.
Peter_in_2780 28-Apr-20 1:48am View
You could try replacing "<" and ">" around User_notes with "&lt;" and "&gt;". I don't know what escaping/unescaping is done where; you may need to experiment further.
Peter_in_2780 25-Apr-20 9:34am View
The element you have named darb_result is NOT an <input>, so it doesn't appear in your POST data.
Peter_in_2780 24-Apr-20 21:58pm View
It'll be the line
$darb_result = escape($_POST['darb_result']);
that's failing. Your POST data is missing an input named darb_result.
Peter_in_2780 18-Apr-20 22:18pm View
Have a look at and related pages. You probably need to work in RectangleF's rather than Rectangles, Round'ing or Truncat'ing at the last moment.
Peter_in_2780 13-Apr-20 1:01am View
In form-Add-Session.php, before testing for $_POST['result'],
to see just what is posted.
Peter_in_2780 11-Apr-20 18:24pm View
When you have detected your 'start comment' token, just consume tokens from the input stream until you find a newline token.
Peter_in_2780 26-Dec-19 1:14am View
Use a tool like Wireshark to see what your browser sends to the weighbridge that your program doesn't.
Peter_in_2780 29-Nov-19 0:29am View
That will replace only the first occurrence.
Peter_in_2780 4-Nov-19 4:53am View
Oops, I did. Fixed now.
Peter_in_2780 3-Nov-19 23:25pm View
Reposting your question is not going to get you a better or quicker answer.
In fact, it's more likely to annoy people who otherwise might volunteer their time to help you.
Peter_in_2780 2-Nov-19 0:09am View
Think about how you would do it with pencil and paper.
Note down those steps.
Translate them into code.
Compile and test.
Peter_in_2780 19-Aug-19 19:12pm View
Probably "Bugs'n'Sugs" is the best place to start.
Peter_in_2780 24-Jul-19 8:03am View
Sorry, I can't help with that. You might do better in a forum related to your hardware and linux.
Peter_in_2780 24-Jul-19 2:33am View
Have you tried "mplayer -loop 0 /path/to/video" ?
According to the docs, -loop 0 will loop that video forever.
Stopping it is a different issue.
Peter_in_2780 17-Jul-19 7:25am View
Your Win10 example seems to be missing quotes around the requestData {...} (outside the 3rd innermost pair of braces).
Peter_in_2780 19-Apr-19 3:54am View
You may be a victim of browser caching. Close the browser (not just the tab) and try again. Once you have entered Basic Auth credentials, the browser will present them every time until you close it.
Peter_in_2780 21-Mar-19 21:19pm View
If you're just after the first request(s) that CURL sends, why not fire up Wireshark? Run it at home. Sure it'll fail, but you'll see what it's trying to do.
Peter_in_2780 17-Mar-19 3:20am View
Please don't cross-post. Ask your question in one place and stay with that.
Peter_in_2780 3-Mar-19 19:42pm View
Suggestion: Work it out with a labelled diagram, pencil and paper. Figure out what you did, and translate that to code.
As an aside, your "S" calculation looks suspicious to me.
Peter_in_2780 2-Jan-19 21:05pm View
Have you considered that the values might be floats, stored little-endian? Take a look through that lens, see if it makes any sense.
Peter_in_2780 12-Nov-18 16:26pm View
Two terms to search:
two-factor authentication
Peter_in_2780 8-Nov-18 0:09am View
It's perfectly valid, just meaningless. Worthy of a compiler warning, but not an error.
*OOPS* missed the space in the middle. That does make it an error, even though it would be optimised to nothing,
Peter_in_2780 31-Oct-18 5:45am View
[blush] Didn't notice it until you pointed it out.
Peter_in_2780 31-Oct-18 3:20am View
Don't cross-post. You've already asked this question in the C# forum.
Peter_in_2780 25-Sep-18 23:47pm View
That smells fraudulent, which is something we do not condone.
Peter_in_2780 13-Sep-18 22:26pm View
Peter_in_2780 16-Jul-18 7:23am View
What number?
What calculator?
You have given us no idea of what your problem is, so there is no way anyone can provide an answer.
Peter_in_2780 1-Jul-18 18:52pm View
Post it as the solution.
Peter_in_2780 24-Jun-18 22:47pm View
A stab in the dark. DefaultRowHeight may apply to subsequently created sheets, rather than altering existing ones.
Peter_in_2780 23-Jun-18 4:01am View
Thank you! I knew about failbit, but I didn't know about returning zero since C++11. Want to make it a solution? (then I can upvote it :p )
Peter_in_2780 13-Jun-18 4:32am View
Why are you rounding PnCalc2[.] before calculating FinalCalc from them? That's throwing away accuracy.
Peter_in_2780 5-Jun-18 22:54pm View
To reach the author of that article, it is best to ask your question in the forum at the bottom of the article. That way, the author will be notified. Here, you are just taking your chances that they will see it.
Peter_in_2780 24-May-18 22:34pm View
Use your browser's debug tools to see if the import is actually happening, and what URL it is trying to fetch.
Peter_in_2780 22-May-18 21:46pm View
If (and it's a huge if!) I was taking this on, I would look to first convert the images to HLS space then do some sort of clustering. The reason for working in HLS rather than, say, RGB or YUV is that "closeness" (euclidean distance) in that space correlates better with human perception of colour (and also is less sensitive to illumination changes in the images)
Peter_in_2780 20-May-18 6:17am View
So you want to copy an existing file onto itself, and you have set FailIfExists to true....
Peter_in_2780 15-May-18 19:10pm View
It's almost certainly OS not hardware. Even though *you* have no more threads than cores, there is other background activity that pops up and invokes the OS thread scheduler. What you should look at is Processor Affinity (start with Google), where you can pin threads to cores and save the OS having to think about it. (I spent years tuning multiprocessor systems in the dim distant past.)
Peter_in_2780 8-May-18 3:50am View
Please delete your incomplete version of this question.
Peter_in_2780 27-Apr-18 4:32am View
It looks like line endings (cr? crlf? lf?) are getting stripped out of the XML somewhere along the way. Check exactly what you are sending.
Peter_in_2780 25-Apr-18 22:36pm View
You already asked this in the Web Dev forum. Cross-posting is considered rude.
Peter_in_2780 25-Apr-18 3:27am View
What's wrong with the 20,000+ links returned by ?
Peter_in_2780 24-Apr-18 18:31pm View
Damn! Beat me to it.
Peter_in_2780 20-Apr-18 21:14pm View
The array has 4 elements, yes. They are numbered 0, 1, ... Now you figure it out.
Peter_in_2780 3-Apr-18 23:52pm View
Great! I'll turn my comment into an answer. Then the question will show as answered, for others to reference.
Peter_in_2780 3-Apr-18 3:04am View
I'm pretty sure you can't move a file to a directory like that. You have to specify the destination file name. Something like you have in the commented-out line $uploadfile.$file_name .
Peter_in_2780 3-Apr-18 0:12am View
Can you try encoding the # as &#35; ? Something is probably treating it as an HTML tag reference or as a (broken) URL encoding.
(grrr took me 3 goes to get this encoded right!)
Peter_in_2780 1-Apr-18 18:00pm View
What you are looking for is called "breadcrumbs". Google that.
Peter_in_2780 25-Mar-18 16:35pm View
As far as I know, ATD.... is used to establish a data call. I suggest you have a look at for more hints about how to set up voice calls.
Peter_in_2780 21-Mar-18 18:12pm View
Show us the exact rules you are using in .htaccess (and where the .htaccess file is). Use the "improve question" widget.
Peter_in_2780 18-Mar-18 22:01pm View
The irony.... ;)
Peter_in_2780 15-Mar-18 1:26am View
Guess you should talk to your teacher, then. We're not going to write your homework to order.
Peter_in_2780 15-Mar-18 0:50am View
Mixing gets() and "cin >> ..." can lead to some weird results, depending on buffering and so on. I suggest you stick to one means of input.
Peter_in_2780 12-Mar-18 23:56pm View
By all means, edit your question with more information, or comment on the solutions, but repeating the whole question is a bad move.
Peter_in_2780 12-Mar-18 23:23pm View
Repeating yesterday's question (which has been answered) is *NOT* going to inspire people to help you. Quite the opposite, in fact.
Peter_in_2780 12-Mar-18 5:52am View
No you are not passing it by reference until you specify it in the definition of findandReplace. Read the manual I referenced.
Peter_in_2780 3-Mar-18 16:50pm View
While I appreciate mathematical elegance as much as anyone, my engineering mindset takes over when there is a specific problem to be attacked.
Peter_in_2780 11-Feb-18 1:49am View
And you seriously think someone is going to wade through that unformatted dump?
Peter_in_2780 17-Jan-18 16:05pm View
No! $_GET is not a method, it's an array. CusID is not a variable name, it's an index into the $_GET array.
Peter_in_2780 17-Jan-18 1:38am View
The error message is quite clear. You do not have an entry CusID in the $_GET array. In other words, the query string does not include .... CusID=somevalue
Peter_in_2780 13-Jan-18 2:28am View
In this case, it seems his @ is legit. It's a common idiom to try to open a file then treat the failure case as "non-existent file".
Peter_in_2780 13-Jan-18 2:26am View
It's hard to tell with your code unformatted, but the usual cause of this error is that there is something unterminated. It could be a simple as a quoted string, or a {...} block. The interpreter is looking for the end of a "something" to pick up the next "something", but it fell off the end of your file before it found it.
Please edit your question, put your code in a "code block", selecting PHP as the language.
Peter_in_2780 11-Jan-18 18:18pm View
So. You've given us a code dump, no clues as to what you expect to happen or what actually did happen. If you want an answer, the first requirement is a question. the better the question, the better the answer is likely to be.
Peter_in_2780 9-Jan-18 23:26pm View
No! /sasa{2}/ matches "sasaa" not "sasasasa". See my comment to OP.
Peter_in_2780 9-Jan-18 22:56pm View
I haven't got my regex tools to hand, but off the top of my head, your regex is set up to match "sasaa". In other words, the quantifier refers to the last matchable item, which is a single character. Try '/(sasa){2}/'

Even then, you'll need to account for the whitepace.
Peter_in_2780 9-Jan-18 0:59am View
Are you looking for navigator.userAgent ? That is what the browser will send to a host to identify itself.
Peter_in_2780 3-Jan-18 6:57am View
You might still get 0! The expression for b will evaluate to something like 1.0 - (one lsb)
Peter_in_2780 1-Jan-18 0:12am View
Did a bit of poking round and found Looks like you can let the system provide the icons from its set.
Peter_in_2780 27-Dec-17 16:10pm View
".. suggest a better way.." It's called the DEBUGGER. Step through your code, watch the variables and control flow.
Peter_in_2780 26-Dec-17 2:54am View
The C language (unlike many of its derivatives) doesn't do default parameters. You'll need to find another way to express what you want to achieve.
Peter_in_2780 14-Dec-17 17:59pm View
505 HTTP Version Not Supported The server does not support the HTTP protocol version used in the request
Peter_in_2780 5-Dec-17 5:02am View
You're welcome! cron jobs don't get to run all your nice startup scripts :p Bitten me a few times.
Peter_in_2780 1-Dec-17 1:51am View
Did you look at the link suggested? That's always a good place to start.
Peter_in_2780 29-Nov-17 5:08am View
Oops! My fossilised brain. Thanks for the correction, Carlo.
Peter_in_2780 24-Nov-17 23:53pm View
Yes, it *IS* difficult. Definitely not a newbie project.
Peter_in_2780 20-Nov-17 17:20pm View
"What I have tried" is not what you tried, it's your homework question. We'll help if you run into a specific issue, but we're NOT going to do your homework for you.
Peter_in_2780 14-Nov-17 0:28am View
Isn't your 20x10 check a LANDSCAPE orientation, not PORTRAIT?
Peter_in_2780 8-Nov-17 5:26am View
I'd guess that your local machine is running on local time, and the server is (very sensibly) running on UTC.
Peter_in_2780 7-Nov-17 18:35pm View
start with
int counter = 10;
then throw out the "if"
Peter_in_2780 7-Nov-17 18:03pm View
I've updated my solution with pseudocode. Give that a try.
Peter_in_2780 5-Nov-17 16:46pm View
Peter_in_2780 4-Nov-17 1:15am View
First thing I'd look at is why you have both js min 1.4.1 and 1.4.2. There's almost certainly some conflict between them.
Peter_in_2780 3-Nov-17 2:27am View
If you have marked the question "solved", then please provide your solution.
Peter_in_2780 2-Nov-17 21:04pm View
One word. DEBUGGER
Peter_in_2780 30-Oct-17 2:09am View
You have already accepted an answer to this question.
Peter_in_2780 20-Oct-17 18:07pm View
I'd be willing to bet that you have a typo somewhere in that humungous query string.
Peter_in_2780 19-Oct-17 23:37pm View
Leave your page as is, except for these two points:
1. Any parts you don't want to appear in print, surround with ...
2. Put the line of CSS somewhere in your existing CSS or in a style block in the head area.
Peter_in_2780 19-Oct-17 23:37pm View
Leave your page as is, except for these two points:
1. Any parts you don't want to appear in print, surround with <div class="noprint"> ... </div>
2. Put the line of CSS somewhere in your existing CSS or in a style block in the head area.

If you need to apply this to inline elements, use "span" instead of "div"
Peter_in_2780 18-Oct-17 8:00am View
Your problem is calling Console.ReadLine twice. You need to call it once, and use that result to test then convert.
Peter_in_2780 10-Oct-17 7:31am View
Why not adapt your current technology slightly? Use HTTP POST to get around length limits and funny character restrictions. On the server, append the POST data to a text file you can dump out from time to time.
You could add stuff at the server, like a time stamp, IP source address, etc.
Peter_in_2780 9-Oct-17 23:43pm View
Hint: Each call to strtok() returns one token (and remembers where it is up to). Read the documentation. Slowly.
Peter_in_2780 2-Oct-17 20:31pm View
Did you create a list for your search to operate on? I don't see that.
Peter_in_2780 5-Sep-17 22:32pm View
You could help yourself by reading the documentation on file_put_contents()
Peter_in_2780 2-Sep-17 2:05am View
Don't repost your question. It only annoys people. If you want to update your original question with more information, that's fine.
Peter_in_2780 30-Aug-17 2:22am View
Look in the Apache logs. They will show the URL you were trying to access that returned the 404 status.
Peter_in_2780 22-Aug-17 1:46am View
That regex doesn't go anywhere near your stated requirements. Get a copy of Expresso and try it.
Peter_in_2780 15-Aug-17 3:39am View
To me, the big clue is "used for maintaining state". I don't know MVC, but anywhere else I met the term that's what I understand.
Peter_in_2780 14-Aug-17 21:53pm View
You're welcome. Given the way Javascript just "disappears" on syntax errors, I find a syntax-colouring editor essential.
Peter_in_2780 1-Aug-17 20:32pm View
1. Don't post the same question in multiple places. That only serves to annoy people.
2. There is no one-size-fits-all "best" way. I personally use the W3Schools responsive CSS package.
Peter_in_2780 31-Jul-17 3:23am View
For one thing, your keyframes "from" and "to" are the same, so there is no transition.
Peter_in_2780 30-Jul-17 1:17am View
No you didn't! Have a careful look at your code and my updated solution.
Peter_in_2780 10-Jul-17 10:35am View
I think the question is to repeatedly append 'abc' without blowing the limit.
Peter_in_2780 27-Jun-17 23:37pm View
We don't do your homework. From the "few simple rules for asking a question" ... 5. If you have a school or university assignment, assume that your teacher or lecturer is also reading these forums.
Peter_in_2780 23-Jun-17 0:58am View
According to my reading of the standard, it should produce something like "count = 11" (11 characters in what it printed for h(g) ). Maybe it is a bug in your compiler/runtime library. What are you using?
Peter_in_2780 23-Jun-17 0:46am View
Hmmm. I missed that. Maybe OP has a non-conforming implementation, but I think that rather unlikely.
Peter_in_2780 21-Jun-17 11:32am View
old DOS style file with EOF mark (0x1a, ^Z) and padding?
Peter_in_2780 7-Jun-17 17:47pm View
You're not checking the return value from move_uploaded_file(). There are things that can go wrong there - see the documentation.
Peter_in_2780 29-May-17 3:26am View
Does the path C:\Users\AT%20systems\Desktop\TinyERP-master\TinyERP-master\api\Application.Api\bin exist?
Peter_in_2780 28-May-17 23:21pm View
Messing with system memory allocation like that can only ever end in tears.
Peter_in_2780 23-May-17 22:55pm View
Big hint. You only need one loop.
Peter_in_2780 22-May-17 3:53am View
We don't do your homework.
Peter_in_2780 10-May-17 18:18pm View
No, we are not going to do your homework for you. We'll answer specific questions if you get stuck on a particular point.
Peter_in_2780 3-May-17 3:58am View
We don't do your homework here. If you've tried something and get stuck, then ask a specific question.
Peter_in_2780 28-Apr-17 20:56pm View
So that's where our SBS ("multicultural" broadcaster) got "Letters and Numbers" from.
Peter_in_2780 27-Apr-17 4:15am View
Get two bits from your RNG. Put them side by side. 00, 01, 10 or 11. Simples.
Peter_in_2780 21-Apr-17 0:36am View
Please don't post the same question (or what is essentially the same) multiple times. If you need to, you can edit your original question.
Another hint: look up "deprecated" in your dictionary.
Peter_in_2780 20-Apr-17 2:36am View
"please send me this program..............!" Sorry, but CodeProject doesn't work like that.
Peter_in_2780 14-Apr-17 4:15am View
Check out NATTY. There are online sites to play with it, and a github repo.
Peter_in_2780 12-Apr-17 2:49am View
The string you show as "after encoding" is *NOT* base64 encoded. It simply has all non-alphanumerics %-hex encoded, sort of like URLencoded, but not even that.
Peter_in_2780 10-Apr-17 2:26am View
Why bother, when "%*d" format does it naturally?
Peter_in_2780 10-Apr-17 2:24am View
RTFM! Then try printf("%0*d", 5, 7);
Peter_in_2780 5-Apr-17 0:29am View
Think about it. PHP runs on the server, while the page is being built for transmission to the client.
Peter_in_2780 2-Apr-17 18:45pm View
"Reply-to" is an optional header, so you shouldn't expect it in every message.
Peter_in_2780 30-Mar-17 17:32pm View
What error(s) do you get? Compile time? Run time? We can't help solve your problem if you don't tell us what it is.
Peter_in_2780 28-Mar-17 1:13am View
The answer is the same as for your previous question. You can't. End of story.
Peter_in_2780 24-Mar-17 21:12pm View
Without looking through your code in detail, it would be worth checking which "length" you are using at each step. Encrypting with block ciphers like AES and DES will pad the input up to the next multiple of the blocksize, and the decryption will expect a whole number of blocks.
So your ciphertext can (and generally will) be larger than your input string.
Peter_in_2780 23-Mar-17 7:01am View
I have no idea. I was simple interpreting your error message for you.
Peter_in_2780 23-Mar-17 1:16am View
That's got nothing to do with the error message OP posted.
Peter_in_2780 13-Mar-17 3:19am View
/dev/initctl is a pipe, recreated every time you reboot. So your chmod doesn't persist.
To reboot my Ubuntu 16.04LTS server remotely, I ssh in and "sudo reboot". Incidentally I use strong authentication. No userid/password login is allowed.
Peter_in_2780 9-Mar-17 20:39pm View
Did you read the last line of the error messages? Seems pretty clear to me:
"To replace this default dialog please handle the DataError event."
Peter_in_2780 8-Mar-17 16:11pm View
If you take logarithms, it will turn your variable window into a constant width window.
Peter_in_2780 6-Mar-17 21:57pm View
You probably have some configuration files lurking. Look in your user directory for file and directory names starting with "."
Peter_in_2780 2-Mar-17 17:07pm View
I haven't really thought this right through, but how about just implementing the flavours of Match you want in each of the derived classes. In other words, don't inherit Match. So you'd wind up with this sort of list of functions:
X.Match(base) [or X.Match(X) and X.Match(Y)]
but NOT Y.Match(Y)
Peter_in_2780 26-Feb-17 23:38pm View
If you want the update time for each row, the easiest way is to add a timestamp column. Set it to "now" whenever you do an add or update.
Peter_in_2780 26-Feb-17 21:49pm View
One problem with your current approach: If you insert or delete a try block somewhere in your code, every message after it will be "renumbered". This will make revision control a total nightmare. I'm NEVER going there again!
Peter_in_2780 21-Feb-17 2:42am View
From Wikipedia, "conio.h is a C header file used mostly by MS-DOS compilers to provide console input/output. It is not part of the C standard library or ISO C, nor is it defined by POSIX."
You need to avoid Microsoft proprietary code. Find alternatives to the bits that conio provides.
Peter_in_2780 4-Feb-17 17:30pm View
Further to my previous comment, you will want to do everything you can to optimise the test. To check 3 x 10^6 items pairwise takes 4.5 x 10^12 operations, so each NANOsecond you can shave off the test loop will save you an hour and a quarter run time.
Peter_in_2780 4-Feb-17 16:41pm View
So an array could be re-expressed as a 180-bit bitmap with at most 4 ones. If you do that conversion once for each of your 3 million arrays, then the disjoint test is a simple AND operation. I suggest 3 long ints would be a suitable structure to hold the bitmaps.
Peter_in_2780 16-Jan-17 1:11am View
OP already said he'd used modf
Peter_in_2780 15-Jan-17 23:32pm View
Really crude, but effective:
sprintf(tempstring, "%f", inputfloatnumber);
sscanf(tempstring, "%d.%d" &integerpart, &fractionpart);
You can do all sorts of fancy things by decorating the %f format specifier
Peter_in_2780 12-Jan-17 23:29pm View
Do a pencil-and-paper exercise. Start with a simple one, say 4 teams, write out the steps as you progress. Then translate your steps into code.
Peter_in_2780 15-Dec-16 19:04pm View
Your kindness and patience far exceeds mine...
Peter_in_2780 15-Dec-16 2:02am View
... and when you get it working, you will have an excellent example of how NOT to manage passwords.
Peter_in_2780 9-Dec-16 1:44am View
So, find the line the error message references, and add a semicolon in an appropriate place. That may not be the real error, but it should get your program to compile.
Peter_in_2780 9-Dec-16 1:39am View
Do you know the length of the barcode you are expecting?
Peter_in_2780 30-Nov-16 23:39pm View
You need to understand what json_encode() does. See for starters.
Peter_in_2780 30-Nov-16 0:16am View
Don't cross-post. It annoys people who might otherwise be inclined to help you.
Peter_in_2780 29-Nov-16 18:43pm View
Have you tried the obvious, encoding as %2B ?
Peter_in_2780 25-Nov-16 19:59pm View
and 01:30 would be even better
Peter_in_2780 21-Nov-16 2:01am View
Depends on the PRNG. A mixed congruential, for example, can be run "backwards". But OPs use of %128 is not only bad practice but would make this more difficult.
Peter_in_2780 21-Nov-16 0:38am View
You don't want to insert the string "CRLF", but rather the characters representing return ( \r, 0x0d, char(13) ) and linefeed ( \n, 0x0a, char(10) ). There may be predefined literal constants you can use.
Peter_in_2780 13-Nov-16 1:53am View
You need to work smarter, not harder. Think about why two readings would occur at the same time. If it helps, try some examples with pencil and paper.
Peter_in_2780 6-Nov-16 20:03pm View
The end of your code seems mangled, so I can't read what's going on. I would be tempted to restructure it like this:
no_line ++;

In other words, decouple your processing of the line from the get-and-count-a-line loop. That will make it a lot easier to see what's going on.
Peter_in_2780 11-Oct-16 3:33am View
Your 'fwrite' that should output the results is commented out...
Also, you have opened the same file for input and output. I suspect that is not what you intended to do.
Peter_in_2780 4-Oct-16 7:00am View
Short answer: Integer is an object, and objects can be compared with null.
Peter_in_2780 20-Sep-16 2:08am View
Looks very much like a case for a subroutine.
Peter_in_2780 7-Sep-16 1:43am View
That doesn't make sense. If you only have one URL, how do you know which page to serve?
Peter_in_2780 28-Aug-16 23:32pm View
There is a discussion forum at the bottom of the Tip. If you ask your question there, the author will be notified. It is unlikely he will see your question here.
Peter_in_2780 28-Aug-16 3:22am View
An HTML validator doesn't care what is between the <script> ... </script> tags (as long as it's not more HTML tags). You need to look for a javascript validator - something like JSLint - to check your script.
Peter_in_2780 17-Aug-16 0:43am View
On my Android devices, I can enable Wifi Hotspot and switch off Mobile Data. Does that combination do what you want?
Peter_in_2780 16-Aug-16 2:30am View
Are you trying to allow some devices (yours) to use your hotspot, and stop other devices using it?
Peter_in_2780 9-Aug-16 20:59pm View
and just exactly what does this have to do with C++ ?
Peter_in_2780 21-Jul-16 22:37pm View
Which tutorial? If it is an article here on Code Project, there is a discussion forum at the bottom where you can ask the author. If it is somewhere else, then ask there.
Peter_in_2780 19-Jul-16 0:48am View
Googling "android format text" produces over 26 million hits. On the first page, shows how to play around with colours. Exactly the same techniques work for font weight and so on.
Peter_in_2780 14-Jul-16 1:27am View
It might be urgent to you and your client, but it isn't to us. You are not doing yourself any favours with that headline.
Peter_in_2780 11-Jul-16 22:28pm View
Peter_in_2780 11-Jul-16 22:27pm View
eGoogling "enumchildwindows example" produces almost 10,000 results. I am sure you can find something there.
Peter_in_2780 1-Jul-16 6:51am View
You're missing url(). See
Assuming you fixed "temp" here too, of course.
Peter_in_2780 26-Jun-16 20:39pm View
I suspect the library has an optimisation that will skip a whole row/column loop if it sees the scalar factor is zero.
Peter_in_2780 15-Jun-16 3:15am View
Your highlighted code block tells you your (first) problem. The define() on line 2 does not have enough parameters. I can't tell what you are trying to define, but you need to fix this before you go any further.
Peter_in_2780 15-Jun-16 2:58am View
See OriginalGriff's comments above.