w3hello.com logo
Home PHP C# C++ Android Java Javascript Python IOS SQL HTML Categories
Facebook SDK .NET - (#200) The user hasn't authorized the application to perform this action
This may seem a silly question, but aren't you missing the Request code from your access token request? Shouldn't it be like this? dynamic result = facebookClient.Get("oauth/access_token", new { client_id = appId, client_secret = appSecret, grant_type = "authorization_code" redirect_uri = Request.Url.AbsoluteUri, code = Request["code"] }); Edit Just realized, you have to use a different grant_type when using the request code :)

Categories : C#

C# Facebook API - The user hasn't authorized the application to perform this action
As mentioned by Igy, you are using a login flow to request an application access token when you should be using a user access login flow. To post to fan pages you need the page access token. For offline deprecation guidelines see scenario 5 here https://developers.facebook.com/roadmap/offline-access-removal/

Categories : C#

Facebook response give User hasn't authorized the application when posting a wall
Just ask for permissions. String[] permissions = { "offline_access", "publish_stream", "user_photos", "publish_checkins","photo_upload" }; mFacebook.authorize(MainActivity.this, permissions, new LoginDialogListener());

Categories : Android

Prompt user to enter path when application starts very first time. Run or stop application depending upon user's action (OK or Cancel)
Application.Exit() will exits the message loop only which is the loop after you call Application.Run .. If you want to exit from whole application- try Environment.Exit(0) It would just kill the process.

Categories : C#

Joomla 2.5 - Phocagallery - Error: You are not authorized to do this action
Try these steps: Go to Extensions Manager->Database->Fix. Then clear joomla/browser cache. If it does not solve your problem re-install Phocagallery (but select fresh install option on prompt) Also you may find instructions for migrating from 1.5/1.6 to 2.x http://www.phoca.cz/documents/50-phoca/566-how-to-migrate-extensions-from-joomla-15-to-joomla-25

Categories : Joomla

how to perform an action only for a specified time
Refer posts about online test preparation http://www.codeproject.com/Articles/2786/Online-Quiz http://forums.asp.net/t/1821162.aspx/1 http://social.msdn.microsoft.com/Forums/en-US/0ebe28db-4fd1-4f78-8c23-15927eed2a75/quiz-application-using-aspnet-and-c

Categories : Ruby On Rails

Perform Action At DatePicker Time
well i would use a local notification... something like this UILocalNotification *notification = [[UILocalNotification alloc] init]; notification.fireDate = theDate //The date that your picker has selected notification.alertBody = @"Hey, the time just expired!" notification.applicationIconBadgeNumber = 1; [[UIApplication sharedApplication] scheduleLocalNotification:notif]; Then in your AppDelegate - (void)application:(UIApplication *)application didReceiveLocalNotification:(UILocalNotification *)notification { //Code to manage the notification logic } Hope this helps, the user will get the alert even if on background.. if on background the user must click the alert to let your application know that the local notification triggered, if he does (or he is on your app already, then

Categories : IOS

COMPLETE Line of Business Application - PRISM MEF Entity Framework - Examples?
Having done something similar in the past, I would create a data service whose only job is to facilitate data requests to/from the database and the user. The data service is the only piece that actually knows how to talk to the db and those details should be obfuscated from the consumers (your viewmodels, etc.). Once the data service is created, the service would hold onto the editable collection of tuples, handle modifications to any and all of them, and expose them directly for binding to the View, ideally through the ICollectionView interface. Then, it's just a matter of injecting that service into your vm's (ideally through an interface to keep things unit testable). I know these concepts are all high-level, but that's kind of all I can give you at this point. This is a project I w

Categories : C#

How manage "No application can perform this action" (AKA ActivityNotFoundException)
Try getting rid of createChooser(). After all, that's not needed for ACTION_VIEW anyway -- if the user chose a default for this MIME type, please allow them to use it. And, the chooser is preventing you from getting ActivityNotFoundException, because the chooser is the activity, and it always exists.

Categories : Android

Perform an action BEFORE application enters background
Your delegate’s applicationDidEnterBackground: method has approximately 5 seconds to finish any tasks and return. In practice, this method should return as quickly as possible. If the method does not return before time runs out, your application is killed and purged from memory. If you still need more time to perform tasks, call the beginBackgroundTaskWithExpirationHandler: method to request background execution time and then start any long-running tasks in a secondary thread. Regardless of whether you start any background tasks, the applicationDidEnterBackground: method must still exit within 5 seconds. Basically, viewDidAppear gets called after your UIViewController's view was added to the application's UIWindow heirarchy. Backgrounding then restoring the app doesn't change your view

Categories : IOS

perform an action after textfield selected by user?
Set the delegate of the UITextField and implement this method in the delegate: - (BOOL)textFieldShouldBeginEditing:(UITextField *)textField { // Do whatever you want return NO; }

Categories : IOS

how to perform an action in iphone application on click in webview
Check this call back method -(BOOL)webView:(UIWebView *)webView shouldStartLoadWithRequest:(NSURLRequest *)request navigationType:(UIWebViewNavigationType)navigationType { } You get this call back when you click link in webview.

Categories : Iphone

Empty intent chooser (No application can perform this action)
I got some feedback from an Android guru telling me the chooser should be defined with a working intent, for example the playstore or gmail or something. In theory you could supply the starting intent of your OWN application (you are sure that your own application is installed). Intent chooserIntent = Intent.createChooser(new Intent(Intent.ACTION_VIEW, Uri.parse("market://details?id=gmail")), "example"); And later, that's why the list removes a single item from the list (you probably don't want your own application in the chooser).

Categories : Android

Perform action after receiving push notification without user acknowledging
There is a method to to just what you want in Apple iOS 7 SDK, which unfortunately is under NDA at the moment so it's only allowed to discuss it inside Apple Developer Forums, but you can read more about it here

Categories : Iphone

asp.net 4 form authentication: perform action on user session expiration
Think this may have already been answered. Calling a method on Session Timeout? Apologies if this is different.

Categories : Asp Net

TFS 2012 configuration Access Denied: [User Name] needs the following permission(s) to perform this action: View collection-level information
One of those groups has View Collection-level Info set to deny. Open the Control panel, choose "Manage collection security and group membership", select the user and hover your mouse over the "View collection-level info" item. It should say "deny" and a "Why?" should show up next to it. That will tell you which Group the deny value is being inherited through.

Categories : Tfs

How to perform a task in android application in between when user has made a call?
Android does support handling/intercepting out going call via capturing NEW_OUTGOING_CALL intent as shown here. but not pressed “green”/go/send? No. This is all happening inside Dialer application so far. Unless you wrote the dialer app yourself, you can't modify its internal workings.

Categories : Android

How to handle business logic errors and application exceptions from business logic layer in MVC ASP.NET
I think it is a good idea to look at this sample. When ever an error occurs in Business logic layer you can return false or say -1 for a method of Business class, then show proper error message to user, and in catch part of the business method you can use one of popular error logging libs like Log4NET or elmah. Edited: To redirect user when error occurs you can specify the error controller in custom error section of web config

Categories : Asp Net Mvc

Ajax Post request not authorized
It could be something similar to this issue: Pre-flight OPTIONS request failing over HTTPS Typically when the issue is with SSL and the preflight request though you wouldn't get back a 403, you'd just get the OPTIONS request aborting. How does the service authenticate and authorise? Are you using self-signed certificates? It sounds like you're correct in thinking that SSL is causing the issue and without more info it's hard to say what your specific problem is.

Categories : Ajax

Jquery ajax post user-defined object to Strut2 action
Finally, I resolved it :D. Just remove line contentType: "application/json" in the ajax call. The ajax call now is: var u = {'user.username': 'abc', 'user.password' : '123'}; $.ajax({ type : 'POST', url : 'login', data: u, //contentType: "application/json", success : function(result) { //alert("hh"); } }); Thanks everyone :D

Categories : Jquery

How to stream input line by line in UNIX, perform commands on each line, and immediately return output?
You can use echo "${#line}" to know the length of a string. Reading the file with a while read... will do the rest: $ cat file hello my name is fedor qui $ while read line; do echo "${#line}"; done < file 5 7 8 3 0 In a nicer format: while read line do echo "${#line}" done < file

Categories : Shell

MVC4 Action Post Parameters Error 500 Internal Server Error
try like this public register(data: any): bool { var url = this.baseUrl + "Account/Register/"; var xhr: JQueryXHR = $.ajax({ type: "POST", url: url, dataType: "json", contentType: "application/json; charset=utf-8", data: JSON.stringify({ login: ({ UserId : 0, Username: "myUser", Password: "myPass" }), company: ({ CompanyId : 0, Name: "myCompany" }) }), async: false, cache: false, }); return (xhr.status == 200); } UserLogin public class UserLogin { public int UserId {get; set;} public string Username { get; set; } public string Password { get; set; } } Company public class Company { publi

Categories : C#

Setting Permissions for a user who hasn't propagated yet
Take a look at PowerShell: Script failing becuase AD objects have not replicated soon enough. I'm having the same problem too and I'll try to figure it out over the next few days. If I find anything useful, I'll update this answer. This http://ss64.com/ps/set-addomainmode.html may be useful but I'm not sure yet. Edit: I wrote a cmdlet that waits for an AD object to propagate to all the domain controllers. <# .SYNOPSIS Wait for an AD object to propagate to all domain controllers. .DESCRIPTION This cmdlet enumerates the domain controllers in the current domain and polls each one in turn until the specified object exists on each one. If the object doesn't propagate completely inside the timeout time span, the cmdlet will throw a System.TimeoutException. .PARAMETER L

Categories : Powershell

how to perform some action on alert dialogue box with 1 action button
btnAlertTwoBtns.setOnClickListener(new View.OnClickListener() { public void onClick(View arg0) { // Creating alert Dialog with two Buttons AlertDialog.Builder alertDialog = new AlertDialog.Builder(AlertDialogActivity.this); // Setting Dialog Title alertDialog.setTitle("Confirm Delete..."); // Setting Dialog Message alertDialog.setMessage("Are you sure you want delete this?"); // Setting Icon to Dialog alertDialog.setIcon(R.drawable.delete); // Setting Positive "Yes" Button alertDialog.setPositiveButton("YES", new DialogInterface.OnClickListener() { public void onClick(DialogInterface dialog,int which) {

Categories : Android

Skrollr.js: Looping action that will happen all the time while user is scrolling window
Perhaps not the answer I was expecting, but it certainly sets me on the right track! @Prinzhorn, creator of the Skrollr plugin, says: "That's nothing skrollr is designed for. Just listen for scroll and do some simple math on the current scroll position (hint: use the modulo operator)." So that's that. I'm basically just copying his answer. So thanks a bunch for your help, @Prinzhorn!

Categories : Jquery

Form Post Action Error in Eclipse
The path of Register.jsp isn't the same as Register_worker.jsp. So you'll need to change the path. This will work fine: <form id="form_register" name="form_register" method="post" action="../worker/Register_worker.jsp">

Categories : Jsp

How to implement the url authentication in java so that only authorized user can access it
Since you are working with a servlet container, a ServletFilter is probably what you want to use. Here are some pointers to get you started: You need to declare the servlet filter in web.xml to have it apply. (filter and filter-mapping tags) You need (of course) an implementation of Filter to make your choice If a request is not authorized, either redirect it to an error page, or send an http-not-authorized. Here is the javadoc for Filter: http://docs.oracle.com/javaee/5/api/javax/servlet/Filter.html public class ExampleFilter extends SomeBaseClass { public void doFilter(ServletRequest request, ServletResponse response, FilterChain chain) { if (aRequest instanceof HttpServletRequest) { if (!isAuthorizedRequest(aRequest)) { ((HttpServletResponse)aResponse).setS

Categories : Java

Having difficulty enabling an authorized user to view their own resource
Please take a look here Basically, you want to use the load_resource helper method to fetch only current_user's dashboard. Behind the scene it is doing something like this in your controller: current_user.dashboard.find(params[:dashboard_id])

Categories : Ruby On Rails

A application Post on User's walls using Facebook PHP registration API?
Your token is granted only for the permissions you specifically requested when you requested the the application be authorized by the user. To be able to post to a users wall, you need to ask the user to authorize the appropriate permissions. Here is the facebook reference for requesting these permissions: https://developers.facebook.com/docs/facebook-login/permissions/#adding Depending on your app, you'll need to ask for either/both publish_actions or publish_stream when you get initial authentication from the user.

Categories : PHP

Messaging application, Realtime update for message post time?
Check out signalR . It is what you are looking for. And there is also Jabbr built on signalR for chat client. SignalR supports broadcasting, tries to find out server and client capabilites and use best for case. Supports web sockets, long polling and forever frames etc. If you want to use across multiple servers, it also can use Sql server and Redis as backend. wiki page : https://github.com/SignalR/SignalR/wiki By the way, SO uses web sockets for real time updates, http://meta.stackexchange.com/questions/129499/what-technology-framework-is-stackoverflow-using-to-asynchronously-update-client

Categories : Javascript

Hashing and using time as salt to prevent access from un-authorized system and replay attacks
This will stop users from intercepting requests on network and using them with CURL. But both private key and signature algorithm can be extracted for your app and reimplemented, so this solution will not be totally secure. Alas, you can't have complete security here without some custom tamper-resistant hardware issued to users.

Categories : Security

Post data on Kinvey DataStore with Business Logic
I sent an email to Kinvey support and they helped me a lot. Some of my mistakes: The JSON that I was returning back was wrong [*]; I didn't add in the header of my response the Content-Type and status. Now it works perfectly! [*] The JSON that I send back in the body of the response is: { "request": { "method": "<redacted>", "username": "<redacted>", "entityId": "<redacted>", "collectionName": "<redacted>", "headers": { "connection": "<redacted>", "host": "<redacted>", "x-forwarded-for": "<redacted>", "x-forwarded-port": "<redacted>", "x-kinvey-api-version": "<redacted>", "x-real-ip": "<redacted>",

Categories : Google App Engine

How to get the user's system clock time to display in a web application?
PHP doesn't run on the client but on the server, so if you want to do this you can use some JavaScript. function set_time() { var d = new Date(); var c_hour = d.getHours(); var c_min = d.getMinutes(); var c_sec = d.getSeconds(); var t = c_hour + ":" + c_min + ":" + c_sec; return t; }

Categories : PHP

How could I check time that android application takes until the user can use it
You have to use LogCat to measure the time. You can only start to measure time when your app is running but you can search the LogCat associated with the launch(it is better if you click on your app icon and search for it un the logcat entry); Then just override onResume on your main activity and put: Log.d("time_start","time launch"); Then just calculate it! In this case: 960-560 Cheers

Categories : Android

Android - Show help to the user on how to use the application when launched for the first time
You can try this lib and have a look at how it's done: https://github.com/Espiandev/ShowcaseView The ShowcaseView library is designed to highlight and showcase specific parts of apps to the user with a distinctive and attractive overlay. This library is great for pointing out points of interest for users, gestures, or obscure but useful items. The library is based on the "Cling" view found in the Launcher on Ice-Cream Sandwich and Jelly Bean, but extended to be easier to use.

Categories : Android

How to display error / result messages to the user upon an action
If there's an error then, in general, the user should stay in the same view and not be redirected. So they can correct the error and try again. So you'd basically just do this: if(itemID == null) { ViewData["ErrorMessage"] = "The ID provided provoked an error. Please try again. If the problem persist, contact your local administrator."; return View(); // you probably have a model to include as well } else { // perform your action return RedirectToAction("some action"); } After all, just look at the error message you're displaying: The ID provided provoked an error. Please try again. If the problem persist, contact your local administrator. You might also consider using something like TempData which doesn't get flushed until it's used. Perhaps like this: if(item

Categories : C#

Display end-user message in case of an error in custom action in MSI with Wix
I use this to create message boxes to handle errors from within my dll: PMSIHANDLE hRecord = MsiCreateRecord(0); MsiRecordSetString(hRecord, 0, TEXT("Enter the text for the error!")); MsiProcessMessage(hInstall, INSTALLMESSAGE(INSTALLMESSAGE_ERROR + MB_OK), hRecord); return ERROR_INSTALL_USEREXIT;

Categories : Windows

In-App purchase error - consumable you've already purchased this item, but it hasn't been downloaded
This happens when the user is making a purchase on something they have already bought. Given that you are working with a consumable, you need to make sure you send a consumption/provisioning request to the Apple purchase servers when you give the user what they bought.

Categories : Iphone

PHP login with mysql authorized error
In checklogin.php you set the variables as follows $_SESSION['$myusername']; $_SESSION['$mypassword']; and in loggedin.php you checked them as follows if(isset($_SESSION['myusername'],$_SESSION['mypassword'])) The names are different since you use a "$" for the key of the session in checklogin.php and don't use it in loggedin.php and I don't suggest you do this instead I suggest you set $_SESSION['logged_in'] = 1; and then you check that for validity in loggedin.php. Also I noticed that you're missing a "$" in your if clause in the loggedin.php file, so it should become if(!$authorized)

Categories : PHP

Phonegap SQLite Error 23 Not Authorized
Just came into this, i had to uninstall the app and re made it (Also changed the version but i dont think that did it). Followed this so i uninstall the app everytime i debug. This can be annoying if you have to insert items each time, but atleast solved it.

Categories : Javascript



© Copyright 2017 w3hello.com Publishing Limited. All rights reserved.