check

SystemEvents::PowerModeChanged Problem

Whats in my project(C++/CLI): - dllimport some un managed dlls - wndproc is override in the form - Treads are there - Times used - I used notify icon so used myForm->Hide() and myForm->Show() I used the following line but MyMainForm::onPowerModeChanged method never fires... SystemEvents::PowerModeChanged += gcnew PowerModeChangedEv...

Link checker - mail for invalid links

Hey! I got this link checker script and i would like it to give me a mail when a link doesnt work. I need it to remember that it send me an email about a link so i dont get multiple emails about the same link. I would appeciate if anyone help me with this since it was too hard for me. <? function checklink($links) { $working = 0; ...

Install Shield 2009 Premier: Abort installation if not admin user

Install Shield 2009 Premier: Basic MSI Project. I need to check if its admin user and if not showing a message box the installation will abort. How to do it ? ...

How to check whether a user is in Administrator group in Install Shield 2009 Basic MSI Project

Install Shield 2009, Premier, Basic MSI Projcet:[I want to allow only administrator users to run setup] In the Releases->MyProductConfiguration->MyRelease->Setup.exe tab i chose "Required Execution Level" = "Invoker" and in General Information->Product Properties I put a Install condition as Condition = "AdminUser" Message = "Require ...

How can I check the size of a file in a Windows batch script?

I want to have a batch file which checks what the filesize is of a file. If it is bigger than %somany% kbytes, it should redirect with GOTO to somewhere else. Example: [check for filesize] IF %file% [filesize thing Bigger than] GOTO No echo Great! Your filesize is smaller than %somany% kbytes. pause exit :no echo Um... You have a big ...

If textBox1 Contains Integer

I just have a simple question... How do I check to see if a textbox or a string contains an Integer? please no code just maybe a hint or two :D thanks all :) ...

How to create a bash script to check the SSH connection?

I am in the process of creating a bash script that would log into the remote machines and create private and public keys. My problem is that the remote machines are not very reliable, and they are not always up. I need a bash script that would check if the SSH connection is up. Before actually creating the keys for future use. ...

How to catch check/uncheck event of <input type="checkbox" /> with jQuery?

The title should be clear ...

PHP if statement issue when checking for variable value

I'm trying to just write a simple PHP if statement that checks if a custom field has anything entered into or if it has been left blank. when it is blank it is meant to not print anything to the page, if something is set in the custom field then it should create a li element with an a tag inside of it. here is my code so far: <ul clas...

Checking whether clearInterval has been called?

Given this code: bob = setInterval(function, 1000); clearInterval(bob); Is there now a way to know if that interval has been cleared? Currently, I keep track of this myself, by unsetting 'bob', but I'm curious if my extra line of code is unnecessary: clearInterval(bob); bob = null; if (!bob) itIsCleared(); Thanks! ...

Faster means of checking for an empty buffer in C?

By 'empty buffer,' I mean a buffer full of zeroes. I am searching for a faster method of accomplishing this: int is_empty(char * buf, int size) { int i; for(i = 0; i < size; i++) { if(buf[i] != 0) return 0; } return 1; } I realize I am searching micro optimization unnecessary except in extreme cases, but I know a faster method ...

Proper way to check QOject derived class type in Qt

Lets say I have a two classes: class A : public QObject {}; class B : public QObject {}; then I go QObject *a = new A(); QObject *b = new B(); now, how do I make sure that "a" is an instance of class A, and "b" is an instance of class B? currently I do something like this: if (a->inherits(A::staticMetaObject.className())) { ... ...

Check date of a file in unix

In my unix shell script, I have a for loop and looping thru the files in a directory, I want to check the modified date of a file is greater than some number of days, say 10 days and do some processing. Any help in this regards is highly appreciated. ...

PHP How to know if a variable is a reference ?

Hello, I want to call a function with call_user_func_array but i noticed that if an argument is a reference in the function definition and is a simple value in call_user_func_array, the following warning appears: Warning: Parameter 1 to test() expected to be a reference, value given Here is a simple example of what i am trying to do: ...

Multiple values for an input in a form?

Alright, let me start with an example. I have a bunch of items and they can fall into series of categories. An item can be in multiple categories. Basically what I have is a listing of items with checkboxes grouped by category. Again an item can appear more than once. So it could look something like: Blue Items: Item 1 Item 2 Item 3 Re...

In Asp.Net, check for existence of aspx page before redirecting to it?

How can I check for the existence of an aspx page before attempting to redirect to it, so I can handle that case in my C# code? Response.Redict("~/SomePage.aspx") But I want to make sure that page really does exist before I call it. It works off of a string after all, so maybe I have a type or something, or maybe I have not created th...

Batch/Windows: Random Numbers.

Hello, I am developing a card game for batch. [will give a link when done] Basiclly what i want to do is 'set' '%random%' to '%numbs%. set %numbs%=%random% And then i want the user to type one value from the %random% numbers displayed echo %numbs% Set nuchoo= set /p nuchoo=Number: What my question now is about how to check if the...

Debugging unit test in C using check

I'm trying to use check unit testing framework for my C application. But I can't use the debugger (gdb) with it because of two points: first, check use some complex macros (START_TEST et END_TEST) and the debugger has trouble to put a breakpoint in my code between these two macros (in fact, I can put a software breakpoint but It is ne...

JS: Check if var has "cheese" OR "cake" in it?

How can i check if a variable has something in it? I tried checking if a .match() returned null but that wasn't useful for checking with an OR? All ideas would be gratefully appreciated! ...

ipone app streaming video bandwidth check

Hi, I have an iphone app, which plays live streaming videos. I want to check the bandwidth of the users connection, depending on which i will assign low, medium or high streaming to Any idea on how to check the users bandwidth / internet connection speed? ...