call

problem starting with zend framework

Hi guys, I downloaded the zend framework 1.10 full. Unzipped, rename this folder to zf. I am going to use zend framework as independent, will only call loader and include libraries when needed. I put the unzipped zend framework into http://localhost/r/zf Then from r/test2.php I put these code to do test call, but it fail. Anything I ...

"Iterating" through methods

Hi. Let's say I've got a Java object that's got among others the following methods: public String getField1(); public String getField2(); public String getField3(); public String getField4(); public String getField5(); Is there a way to iterate through these methods and call 'em like the following code? String fields = ""; for(int i...

PHP: Calling a function within a return string

Hello, I'm trying to call a function within a string return statement. Both are in the same class. However, I'm obviously not calling it right because it doesn't work :) private static function doSomething(){ $d['dt'] = //unix time stamp here; return '<div class="date" title="Commented on '.date('H:i \o\n d M Y',$d['dt']).'">'.ti...

Silverlight WCF service calling exception

Hi; A Silverlight 3.0 application tries to call WCF service but the application can not even establish connection to the endpoint. I had checked URLs etc. and every thing seems ok. Accessing the service from other tools like browser works. When I debug application in Visual Studio when the first call to the service is made below output i...

Accessing the Java call stack

I would like to know if it's possible to access the call stack from within a method to see which method in which package called the one we are in now? Or perhaps there is another way of doing this? Thanks, ExtremeCoder P.S. This is all in Java ...

transfer incoming call to voicemail in android

Kindly help me to transfer incoming call to voice mail in android. Thanks ...

Dynamically naming and implementing the body of a javascript function

For simplicity's sake, I've included a script that dynamically calls a function by its name: var foo = "hello"; var bar = "world"; var function_name = "say_" + foo + bar; // Since its name is being dynamically generated, always ensure your function actually exists if (typeof(window[function_name]) === "function") { window[function_...

How can I call a javascript constructor using call or apply?

Hi, how could I generalise the function below to take N arguments? (Using call or apply?) Is there a programmatic way to apply arguments to 'new'? I don't want the constructor to be treated like a plain function. All the best, Chris. /** * This higher level function takes a constructor and arguments * and returns a function, whic...

C++ - basic function question

Hello! Is there any way to make a function call only once? Suppose I have some class struct A { void MainRoutine(Params) { // Want to call other routine only once } void OtherRoutine(Params) { // Do something that should be done only once and // what depends on the params } }; I want to call Other...

make a call in iphone from my application.

how can i make call from my application to particular no. Give me some logic or code for performing this task... ...

after call end, relaunch the previous app in iphone

I can make a call from my app by use this APIs. [[UIApplication sharedApplication] openURL:[NSURL URLWithString:@"tel:XXXXXX"]]; I would like to return to my app where I left after the users ends the call. Is that possible? ...

iPhone - Accessing superviews methods?

So essentially I'm inserting "startViewController" into "mainViewController" now of course I can access startViewControllers methods from mainViewController but I was wondering how to do the opposite? Occasionally startViewController will need to call something in mainViewController and I was just wondering how I do this? Thanks in adva...

how to record phone calls in iphone using proramming?

i need to know can we record phone calls in iphone. if possible then how can we do it using coding. ...

How to pass parameters to a proc when calling it by a method? (ruby)

proc = Proc.new do |name| puts "Thank you #{name}!" end def thank yield end proc.call # output nothing, just fine proc.call('God') # => Thank you God! thank &proc # output nothing, too. Fine; thank &proc('God') # Error! thank &proc.call('God') # Error! thank proc.call('God') # Error! # So, what should I do if I have to pass the ...

iPhone mobile number using Core telephony

As far as my understanding, there is no public API available in iPhone SDK to find the users mobile number. Can we find the mobile number of iPhone user using the Core telephony framework added in 4.0 SDK? ...

what is better Doing AJAX call or use UpdatePanel for updating a panel?

In my application i need to update a panels content after the button click which do some server side processing. I don't want to do full page postback. I can achieve this in two ways : By doing a AJAX call or by using a update panel. But I am confused to choose one. Which is a better option in this case? Thanks in advance. ...

Calling 3 web services async, and waiting for them to complete

In my silverlight page, when the user clicks on a button; the app, calls 3 web services async. It has to either wait for these 3 async calls to be completed or has to be notified when these calls are completed. After these 3 calls are completed, the results will be written to a text file (It is a out-of-browser app with elevated trust). ...

Getting return value of a function called with assembly

I am using Microsoft Visual C++ 2010. If I have a function like this: const char* blah(void); and I want to call it like this: __asm { call blah; ... } How do I get the return value of the function in the assembly? ...

How to get the result of a jQuery AJAX call then call another function

Hello Basically I am trying to call a function (function 1), that get the results from another function (function 2). And this function 2 is making an ajax call. So the code would be like this: function f1 () { var results = f2(); } function f2() { $.ajax({ type: 'POST', url: '/test.php', success: func...

How to define a method some how like the 'yield' ( I mean, automatically catch the block)?

If I need to define a method called 'yields' which will call yiled 3 times: def yields 3.times do yield end end And then I will use it in an other method: def call_me_3_times yields end In the console or irb: >> call_me_3_times { puts 'me'} # => Cause error => LocalJumpError: no block given (yield) from (ir...