Search Results

Search found 1619 results on 65 pages for 'peter lacomb jr'.

Page 9/65 | < Previous Page | 5 6 7 8 9 10 11 12 13 14 15 16  | Next Page >

  • Sybase SQLAnywhere jConnect routines?

    - by jr
    I have a database which is part of a closed system and the end-user of the system would like me to write some reports using the data contains in a Sybase SQL Anywhere Database. The system doesn't provide the reports that they are looking for, but access to the data is available by connecting to this ASA database. The vendor of the software would likely prefer I not update the database and I am basically read-only as I am just doing some reporting. All is good, seal is not broken, warranty still intact, etc,etc.. My main problem is that I am using jConnect in order to read from the database, and jConnect requires some "jConnect Routines" to be installed into the database. I've found that I can make this happen by just doing an "Alter Database Upgrade JConnect On", but I just don't fully understand what this does and if there is any risks associated with it. So, my question is does anyone know exactly what jConnect routines are and how are they used? Is there any risk adding these to a database? Should I be worried about this?

    Read the article

  • Rails validation error messages: Displaying only one per field

    - by Sergio Oliveira Jr.
    Rails has an annoying "feature" which displays ALL validation error messages associated with a given field. So for example if I have 3 validates_XXXXX_of :email, and I leave the field blank I get 3 messages in the error list. This is non-sense. It is better to display one messages at a time. If I have 10 validation messages for a field does it mean I will get 10 validation error messages if I leave it blank? Is there an easy way to correct this problem? It looks straightforward to have a condition like: If you found an error for :email, stop validating :email and skip to the other field. Ex: validates_presence_of :name validates_presence_of :email validates_presence_of :text validates_length_of :name, :in = 6..30 validates_length_of :email, :in = 4..40 validates_length_of :text, :in = 4..200 validates_format_of :email, :with = /^([^@\s]+)@((?:[-a-z0-9]+.)+[a-z]{2,})$/i <%= error_messages_for :comment % gives me: 7 errors prohibited this comment from being saved There were problems with the following fields: Name can't be blank Name is too short (minimum is 6 characters) Email can't be blank Email is too short (minimum is 4 characters) Email is invalid Text can't be blank Text is too short (minimum is 4 characters)

    Read the article

  • Exclude string from wildcard in bash

    - by Peter O'Doherty
    Hi, I'm trying to adapt a bash script from "Sams' Teach Yourself Linux in 24 Hours" which is a safe delete command called rmv. The files are removed by calling rmv -d file1 file2 etc. In the original script a max of 4 files can by removed using the variables $1 $2 $3 $4. I want to extend this to an unlimited number of files by using a wildcard. So I do: for i in $* do mv $i $HOME/.trash done The files are deleted okay but the option -d of the command rmv -d is also treated as an argument and bash objects that it cannot be found. Is there a better way to do this? Thanks, Peter #!/bin/bash # rmv - a safe delete program # uses a trash directory under your home directory mkdir $HOME/.trash 2>/dev/null # four internal script variables are defined cmdlnopts=false delete=false empty=false list=false # uses getopts command to look at command line for any options while getopts "dehl" cmdlnopts; do case "$cmdlnopts" in d ) /bin/echo "deleting: \c" $2 $3 $4 $5 ; delete=true ;; e ) /bin/echo "emptying the trash..." ; empty=true ;; h ) /bin/echo "safe file delete v1.0" /bin/echo "rmv -d[elete] -e[mpty] -h[elp] -l[ist] file1-4" ;; l ) /bin/echo "your .trash directory contains:" ; list=true ;; esac done if [ $delete = true ] then for i in $* do mv $i $HOME/.trash done /bin/echo "rmv finished." fi if [ $empty = true ] then /bin/echo "empty the trash? \c" read answer case "$answer" in y) rm -i $HOME/.trash/* ;; n) /bin/echo "trashcan delete aborted." ;; esac fi if [ $list = true ] then ls -l $HOME/.trash fi

    Read the article

  • Problem with NSUserDefaults and deallocated Instance

    - by Peter A
    Hi, I'm having a problem with NSUserDefaults. I've followed the steps in the books as closely as I can for my app, but still get the same problem. I am getting a *** -[NSUserDefaults integerForKey:]: message sent to deallocated instance 0x3b375a0 error when I try and load in the settings. Here is the code that I have, it is in the App Delegate class. - (void)applicationDidFinishLaunching:(UIApplication *)application { recordingController = [[RecordingTableViewController alloc] initWithStyle:UITableViewStylePlain]; [recordingController retain]; // Add the tab bar controller's current view as a subview of the window [window addSubview:tabBarController.view]; [self loadSettings]; } -(void)loadSettings { NSUserDefaults *defaults = [NSUserDefaults standardUserDefaults]; NSNumber loop = [defaults objectForKey:@"loop_preference"]; NSNumber play = [defaults objectForKey:@"play_me_preference"]; NSNumber volume = [defaults objectForKey:@"volume_preference"]; } As you can see I am not trying to do anything with the values yet, but I get the error on the line reading in the loop preference. I also get it if I try and read an NSString. Any suggestions would be greatly appreciated. Thanks Peter

    Read the article

  • Dynamic Google Maps API InfoWindow HTML Content

    - by Peter Hanneman
    I am working in Flash Builder 4 with Google Map's ActionScript API. I have created a map, loaded some custom markers onto it and added some MouseEvent listeners to each marker. The trouble comes when I load an InfoWindow panel. I want to dynamically set the htmlContent based off of information stored in a database. The trouble is that this information can change every couple of seconds and each marker has a unique data set so I can not statically set it at the time I actually create the markers. I have a method that will every minute or so load all of the records from my database into an Object variable. Everything I need to display in the htmlContent is contained in this object under a unique identifier. The basic crux of the problem is that there is no way for me to uniquely identify an info window, so I can not determine what information to pull into the panel. marker.addEventListener(MapMouseEvent.ROLL_OVER, function(e:MapMouseEvent):void { showInfoWindow(e.latLng) }, false, 0, false); That is my mouse event listener. The function I call, "showInfowindow" looks like this: private function showInfoWindow(latlng:LatLng):void { var options:InfoWindowOptions = new InfoWindowOptions({title: appData[*I NEED A UNIQUE ID HERE!!!*].type + " Summary", contentHTML: appData[*I NEED A UNIQUE ID HERE!!!*].info}); this.map.openInfoWindow(latlng, options); } I thought I was onto something by being able to pass a variable in my event listener declaration, but it simply hates having a dynamic variable passed through, it only returns the last value use. Example: marker.addEventListener(MapMouseEvent.ROLL_OVER, function(e:MapMouseEvent):void { showInfoWindow(e.latLng, record.unit_id) }, false, 0, false); That solution is painfully close to working. I iterate through a loop to create my markers when I try the above solution and roll over a marker I get information, but every marker's information reflects whatever information the last marker created had. I apologize for the long explaination but I just wanted to make my question as clear as possible. Does anyone have any ideas about how to patch up my almost-there-solution that I posted at the bottom or any from the ground up solutions? Thanks in advance, Peter Hanneman

    Read the article

  • php scandir --> search for files/directories

    - by Peter
    Hi! I searched before I ask, without lucky.. I looking for a simple script for myself, which I can search for files/folders. Found this code snippet in the php manual (I think I need this), but it is not work for me. "Was looking for a simple way to search for a file/directory using a mask. Here is such a function. By default, this function will keep in memory the scandir() result, to avoid scaning multiple time for the same directory." <?php function sdir( $path='.', $mask='*', $nocache=0 ){ static $dir = array(); // cache result in memory if ( !isset($dir[$path]) || $nocache) { $dir[$path] = scandir($path); } foreach ($dir[$path] as $i=>$entry) { if ($entry!='.' && $entry!='..' && fnmatch($mask, $entry) ) { $sdir[] = $entry; } } return ($sdir); } ?> Thank you for any help, Peter

    Read the article

  • Looking for merge tool with very good in-line-comparison support

    - by peter p
    I have seen this topic discussed several times, but emphasis is on "very good in-line-comparison" here, which was not really covered by those threads. E.g. I would like the tool to recognize and highlight that the resource "colorpicker_newstring" has been added when comparing the following two blocks. WinMerge and Kdiff both fail... Does anyone know a software that does not? I am using Windows. Ah, and I'd prefer free/OS software, of course. Thanks a lot in advance, Peter File A: <resource name="colorpicker_title">Color picker</resource> <resource name="colorpicker_apply">Apply</resource> <resource name="colorpicker_transparent">Transparent</resource> <resource name="colorpicker_htmlcolor">HTML color</resource> <resource name="colorpicker_red">Red</resource> <resource name="colorpicker_newstring">New String</resource> <resource name="colorpicker_green">Green</resource> <resource name="colorpicker_blue">Blue</resource> <resource name="colorpicker_alpha">Alpha</resource> <resource name="colorpicker_recentcolors">Recently used colors</resource> File B: <resource name="colorpicker_title">Sélecteur de couleur</resource> <resource name="colorpicker_apply">Appliquer</resource> <resource name="colorpicker_transparent">Transparent</resource> <resource name="colorpicker_htmlcolor">Couleur HTML</resource> <resource name="colorpicker_red">Rouge</resource> <resource name="colorpicker_green">Vert</resource> <resource name="colorpicker_blue">Bleu</resource> <resource name="colorpicker_alpha">Alpha</resource> <resource name="colorpicker_recentcolors">Couleurs récentes</resource>

    Read the article

  • Standard way to hash an RSA key?

    - by Adam J.R. Erickson
    What's the algorithm for creating hash (sha-1 or MD5) of an RSA public key? Is there a standard way to do this? Hash just the modulus, string addition of both and then take a hash? Is SHA-1 or MD5 usually used? I want to use it to ensure that I got the right key (have the sender send a hash, and I calculate it myself), and log said hash so I always know which exact key I used when I encrypt the payload.

    Read the article

  • Problems saving a photo to a file

    - by Peter vdL
    Man, I am still not able to save a picture when I send an intent asking for a photo to be taken. Here's what I am doing: Make a URI representing the pathname android.content.Context c = getApplicationContext(); String fname = c.getFilesDir().getAbsolutePath()+"/parked.jpg"; java.io.File file = new java.io.File( fname ); Uri fileUri = Uri.fromFile(file); Create the Intent (don't forget the pkg name!) and start the activity private static int TAKE_PICTURE = 22; Intent intent = new Intent(android.provider.MediaStore.ACTION_IMAGE_CAPTURE ); intent.putExtra("com.droidstogo.boom1." + MediaStore.EXTRA_OUTPUT, fileUri); startActivityForResult( intent, TAKE_PICTURE ); The camera activity starts, and I can take a picture, and approve it. My onActivityResult() then gets called. But my file doesn't get written. The URI is: file:///data/data/com.droidstogo.boom1/files/parked.jpg I can create thumbnail OK (by not putting the extra into the Intent), and can write that file OK, and later read it back). Can anyone see what simple mistake I am making? Nothing obvious shows up in the logcat - the camera is clearly taking the picture. Thanks, Peter

    Read the article

  • Drupal Forms - Setting a Default Value

    - by JR
    I am using the webform module for Drupal 6 and would like to set a default value for the confirmation message of the webform whenever it is created. Would I have to create my own module to set this form value whenever a user creates a new webform? Or would I have to implement a special hook to look for when a webform is created?

    Read the article

  • Why is Collection<String>.class Illegal?

    - by Peter
    I am puzzled by generics. You can declare a field like: Class<Collection<String>> clazz = ... It seems logical that you could assign this field with: Class<Collection<String>> clazz = Collection<String>.class; However, this generates an error: Syntax error on token ">", void expected after this token So it looks like the .class operator does not work with generics. So I tried: class A<S> {} class B extends A<String> {} Class<A<String>> c = B.class; Also does not work, generates: Type mismatch: cannot convert from Class<Test.StringCollection> to Class<Collection<String>> Now, I really fail to see why this should not work. I know generic types are not reified but in both cases it seems to be fully type safe without having access to runtime generic types. Anybody an idea? Peter Kriens

    Read the article

  • saving iPhone program state with a deep UINavigationController

    - by jr
    Can someone a good way to save the program state (UINavigationController stack, etc) of an iPhone application. My application obtains a bunch of information from the network and I want to return the person back to the last screen they were on, even if it was 3 or 4 screens deep. I assume that I will need to reload the data from the network along the way as I recreate the UINavigation controllers. I don't necessarily have a problem with this. I'm thinking about maybe having my UINavigationController objects implement some type of protocol which allow me to save/set their state? I'm looking to hear from others who may have needed to implement a similar scenario and how they accomplished it. My application has a UITabbarController at the root and UINavigationController items for each tab bar item. thanks!

    Read the article

  • How to configure outgoing connections from an SQL stored procedure?

    - by Peter Vestberg
    I am working on a .NET project which uses Microsoft SQL server. In this project, I need a CLR stored procedure (written in C#) that uses a remote web service. So, when the stored procedure is executed on the SQL server, it makes web service calls and thus sends packets to a remote location. The problem is that when executing the SP I get: "System.Net.WebException: The request failed with HTTP status 403: Forbidden." The database user has full permission, the deployed CLR assembly and SP are even marked "unsafe", I tried signing it etc., so any of that is not causing the problem. When I am executing the very same C# code, but from a simple console application instead of as a SP, it all works fine. So I started to suspect a network related problem and had a packet sniffer running when executing both the SP and the console app version. What I realized was that the packets sent out had different destination IP addresses: the console app sent the packets directly to the web service IP while the SP sent the packets to a proxy server we use in our company. Due to network policies the latter is not allowed and that explains the "403 Forbidden" exception. So my question boils down to this: How can I configure the SP/MS SQL server to NOT use that proxy? I want it to send the packets directly to the web service IP, just like the test console app. (again, the C# code is the same , so it's not a programming matter). I've disabled all proxy settings in Internet Explorer in case the SQL server inherits these settings or something. However, no luck. Any help would be greatly appreciated! Best regards, Peter

    Read the article

  • Jersey w/ Spring 3.0?

    - by jr
    I see some are using Jersey w/ Spring. With Spring 3.0 there are now annotations available to make RESTful APIs directly in a controller. Why should I consider using Jersey w/ Spring?

    Read the article

  • jquery ajax error cannot find url outside of debug mode

    - by John Orlandella Jr.
    I inherited some code two weeks ago that is using the jquery.ajax method to connect to a .NET web service. Here is the piece of code give me the trouble... if (MSCTour.AppSettings.OFFLINE !== 'TRUE') { $.ajax({ url: url, data: json, type: "POST", contentType: "application/json", timeout: 10000, dataType: "json", // not "json" we'll parse success: function(res){ if (!callback) { return; } /* // *** Use json library so we can fix up MS AJAX dates */ var result = ""; if (res !== "") { try { result = $.evalJSON(res); } catch (e) { result = {}; bare = true; } } /* // *** Bare message IS result */ if (bare) { callback(result); return; } /* // *** Wrapped message contains top level object node // *** strip it off */ for (var property in result) { callback(result[property]); break; } }, error: function(xhr,status,error){ if (status === 'parsererror') {} else {return error;} }, complete: function(res, status){ if (callback) { if ((status != 'success' && status != 'error') || status === 'parsererror' || (status === 'timeout' && res !== '')) { try { result = $.secureEvalJSON(res); } catch (e) { result = {}; bare = true; } callback(res); } } return; } }); } The url variable at this point equals /testsite/service.svc/GetItems Now here is where my problem lies... When running this site out of debug mode through visual studio I am not having any problem connecting to the database through the web service and seeing all my data, for both viewing and updating. When I go through the normal web server for the same site, on the same page, no data is showing up. When I put a break on the error portion of the code above in firebug this is information I am getting in the image linked below. link text I am getting what appears to be a 404 error, but when I look on the server all of the files are in the right place... coupled with the fact that it works when in debug mode, I think I am slowly going crazy staring at these same lines of code trying to find the needle in the haystack. Any help or just a direction to look in would be greatly appreciated.

    Read the article

  • Website Sitemaps and <priority>, is it working?

    - by Mike Gleason jr Couturier
    Hi, My "Privacy Policy" page is seen more important by Google than other really more important pages on my website. I'm currently creating a script to generate a sitemap, should I bother with the priority? How do you effectively assign priorities to pages? I consider one of my page important but the page have less content than another one less important to my eyes... but maybe Google bot will see it the other way around. If my degree of "importantness" differs from the one of Google, will I get penalized on the ranking for a particular page? Thank you for sharing your black art with us :P

    Read the article

  • UndeclaredThrowableException due to SQLException in Spring + iBatis?

    - by jr
    Hello, I am getting the following exception when I typo the SQL driver name or the database server is offline, basically any SQLException. I can't determine where the UndeclaredThrowableException is coming from. Line 194 in SqlMapClientTemplate is this: logger.debug("Obtained JDBC Connection [" + springCon + "] for iBATIS operation"); Here is the trace: java.lang.reflect.UndeclaredThrowableException $Proxy59.toString(Unknown Source) java.lang.String.valueOf(Unknown Source) java.lang.StringBuffer.append(Unknown Source) org.springframework.orm.ibatis.SqlMapClientTemplate.execute(SqlMapClientTemplate.java:194) org.springframework.orm.ibatis.SqlMapClientTemplate.executeWithListResult(SqlMapClientTemplate.java:249) org.springframework.orm.ibatis.SqlMapClientTemplate.queryForList(SqlMapClientTemplate.java:296) org.springframework.orm.ibatis.SqlMapClientTemplate.queryForList(SqlMapClientTemplate.java:290) some of my reading points to some type of class loading problem? I can't figure out where the $Proxy is getting introduced?

    Read the article

  • Music meta missing from Facebook /home

    - by Peter Watts
    When somebody shares a Spotify playlist, the attachment is missing from the Graph API. What is shown in Facebook: What is returned by the Graph API: { "id": "********_******", "from": { "name": "*****", "id": "*****" }, "message": "Refused's setlist from last night's secret show in Sweden...", "icon": "http://photos-c.ak.fbcdn.net/photos-ak-snc1/v85005/74/174829003346/app_2_174829003346_5511.gif", "actions": [ { "name": "Comment", "link": "http://www.facebook.com/*****/posts/*****" }, { "name": "Like", "link": "http://www.facebook.com/*****/posts/*****" }, { "name": "Get Spotify", "link": "http://www.spotify.com/redirect/download-social" } ], "type": "link", "application": { "name": "Spotify", "canvas_name": "get-spotify", "namespace": "get-spotify", "id": "174829003346" }, "created_time": "2012-03-01T22:24:28+0000", "updated_time": "2012-03-01T22:24:28+0000", "likes": { "data": [ { "name": "***** *****", "id": "*****" } ], "count": 1 }, "comments": { "count": 0 }, "is_published": true } There's absolutely no reference to an attachment, other than the fact the type is 'link' and the application is Spotify. If you want to test, Spotify's page (http://graph.facebook.com/spotify/feed) usually has a playlist or two embedded (and missing from Graph API). Also if you filter your home feed to just Spotify stories (http://graph.facebook.com/me/home?filter=app_174829003346), you'll get a bunch of useless stories without attachments (assuming your friends shared music recently) Anyone have any ideas how to access the playlist details, or is it unavailable to third party developers (if so, this is a very a bad user experience, because the story makes no sense without the attachment). I am able to fetch scrobbles without any trouble using the user_actions.listens. Also, if there is a recent activity story, e.g. "Peter listened to The Shins", I am able to get information about the band. The problem only happens on attachments.

    Read the article

  • Project euler problem 45

    - by Peter
    Hi, I'm not yet a skilled programmer but I thought this was an interesting problem and I thought I'd give it a go. Triangle, pentagonal, and hexagonal numbers are generated by the following formulae: Triangle T_(n)=n(n+1)/2 1, 3, 6, 10, 15, ... Pentagonal P_(n)=n(3n-1)/2 1, 5, 12, 22, 35, ... Hexagonal H_(n)=n(2n-1) 1, 6, 15, 28, 45, ... It can be verified that T_(285) = P_(165) = H_(143) = 40755. Find the next triangle number that is also pentagonal and hexagonal. Is the task description. I know that Hexagonal numbers are a subset of triangle numbers which means that you only have to find a number where Hn=Pn. But I can't seem to get my code to work. I only know java language which is why I'm having trouble finding a solution on the net womewhere. Anyway hope someone can help. Here's my code public class NextNumber { public NextNumber() { next(); } public void next() { int n = 144; int i = 165; int p = i * (3 * i - 1) / 2; int h = n * (2 * n - 1); while(p!=h) { n++; h = n * (2 * n - 1); if (h == p) { System.out.println("the next triangular number is" + h); } else { while (h > p) { i++; p = i * (3 * i - 1) / 2; } if (h == p) { System.out.println("the next triangular number is" + h); break; } else if (p > h) { System.out.println("bummer"); } } } } } I realize it's probably a very slow and ineffecient code but that doesn't concern me much at this point I only care about finding the next number even if it would take my computer years :) . Peter

    Read the article

  • Compile subversion on CentOs

    - by peter
    I have downloaded, compiled and installed so far: apr-1.3.9 apr-util-1.3.9 sqlite-3.6.23 zlib-1.2.4 libtool-2.2.6b Now after downloading subversion-1.6.9, the config works fine but compiling it will end with the following error: cd subversion/svn && /bin/sh /root/subversion-1.6.9/libtool --tag=CC --silent --mode=link gcc -g -O2 -g -O2 -pthread -rpath /usr/local/lib -o svn add-cmd.o blame-cmd.o cat-cmd.o changelist-cmd.o checkout-cmd.o cleanup-cmd.o commit-cmd.o conflict-callbacks.o copy-cmd.o delete-cmd.o diff-cmd.o export-cmd.o help-cmd.o import-cmd.o info-cmd.o list-cmd.o lock-cmd.o log-cmd.o main.o merge-cmd.o mergeinfo-cmd.o mkdir-cmd.o move-cmd.o notify.o propdel-cmd.o propedit-cmd.o propget-cmd.o proplist-cmd.o props.o propset-cmd.o resolve-cmd.o resolved-cmd.o revert-cmd.o status-cmd.o status.o switch-cmd.o tree-conflicts.o unlock-cmd.o update-cmd.o util.o ../../subversion/libsvn_client/libsvn_client-1.la ../../subversion/libsvn_wc/libsvn_wc-1.la ../../subversion/libsvn_ra/libsvn_ra-1.la ../../subversion/libsvn_delta/libsvn_delta-1.la ../../subversion/libsvn_diff/libsvn_diff-1.la ../../subversion/libsvn_subr/libsvn_subr-1.la /usr/local/apr/lib/libaprutil-1.la -lexpat /usr/local/apr/lib/libapr-1.la -lrt -lcrypt -lpthread -ldl /usr/bin/ld: cannot find -lexpat collect2: ld returned 1 exit status make: * [subversion/svn/svn] Error 1 The file at /usr/local/apr/lib/libapr-1.la exists and seems to be OK (from permission perspective What could be the problem here? Thanks Peter

    Read the article

< Previous Page | 5 6 7 8 9 10 11 12 13 14 15 16  | Next Page >