Search Results

Search found 467 results on 19 pages for 'robin clark'.

Page 11/19 | < Previous Page | 7 8 9 10 11 12 13 14 15 16 17 18  | Next Page >

  • Add code before initialization of units in Delphi

    - by Alan Clark
    Is there a place where I can add code that will be executed before unit initialization? The reason I want to do this is I need to change the DecimalSeparator, this has to be done before the initialization of some units. I have put it in the project source, before Application.Initialize but it is too late by then. As I see it the only choice I have is to put it in the initialization of the unit that needs the DecimalSeparator to be changed, is this the case? Thanks in advance for any advice.

    Read the article

  • Loading dynamic external content into the Div of another on click

    - by Robin I Knight
    Trying to load an external php file into another onClick. Iframes will not work as the size of the content changes with collapsible panels. That leaves AJAX. I was given a piece of code HTML <a href="#" id="getData">Get data</a> <div id="myContainer"></div> JS $('#getData').click(function(){ $.get('data.php', { section: 'mySection' }, function(data){ $('#myContainer').html(data); }); }); PHP: <?php if($_GET['section'] === 'mySection') echo '<span style="font-weigth:bold;">Hello World</span>'; ?> I have tested it here http://www.divethegap.com/scuba-diving-programmes-dive-the-gap/programme-pages/dahab-divemaster/divemaster-trainingA.php and get the most unexpected results. It certainly loads the right amount of items as it says in the lower bar on safari but I see three small calendars and that is it. Can anyone see where I have made a mistake?

    Read the article

  • Interface Builder layout ViewController with its own nib

    - by Sean Clark Hess
    I would like to be able to decide where a sub view is placed, when that view is controlled by its own view controller. This happens frequently on the iPad when you have a semi-complicated view that doesn't fill the entire screen. So, imagine that I want the sub view controller's nib to decide its own width, components, connections, etc, while the parent nib would decide where that view/nib would be placed. I'd really like to lay it out visually instead of programatically. How can I?

    Read the article

  • How do I splice a python string programmatically?

    - by Robin Welch
    Very simple question, hopefully. So, in Python you can split up strings using indices as follows: >>> a="abcdefg" >>> print a[2:4] cd but how do you do this if the indices are based on variables? E.g. >>> j=2 >>> h=4 >>> print a[j,h] Traceback (most recent call last): File "<stdin>", line 1, in ? TypeError: string indices must be integers

    Read the article

  • Determine caller within stored proc or trigger

    - by Mike Clark
    I am working with an insert trigger within a Sybase database. I know I can access the @@nestlevel to determine whether I am being called directly or as a result of another trigger or procedure. Is there any way to determine, when the nesting level is deeper than 1, who performed the action causing the trigger to fire? For example, was the table inserted to directly, was it inserted into by another trigger and if so, which one.

    Read the article

  • changing text periodically in a span from an array with jquery

    - by Peter Clark
    I have a span, eg: <p>Here is a sentence <span id="rotate">this</span> is what changes</p> and I'd like the contents of that span to change every few moments between a list of terms, so the contents might change to be: <span id="rotate">then</span> <span id="rotate">thus</span> and so on. I'd like the text to fade out and then the new text fade in. Whats the best way to do this via jquery?

    Read the article

  • PageableListView Not rendering my data as required

    - by Robin
    i am working on wicket, where i am supposed to show my data's under <tr> <td>Name</td> <td>Single Player Score</td> <td>Double Player Score</td> <td>Total Score</td> </tr> <tr wicket:id="data"> <td wicket:id="name"></td> <td wicket:id="singlePlayerScore"></td> <td wicket:id="doublePlayerScore"></td> <td wicket:id="totalScore"></td> </tr> My Player model class is as: Player class with attributes singlePlayerScore, doublePlayerScore(), name with getter and setter and also a list data obtained from database. Data from SQLQuery is as; name score gamemode A 200 singlePlayerMode A 100 doublePLayerMode B 400 singlePlayerMode B 300 doublePLayerMode dataList == player.getScoreList(); My PageableListView is as: final PageableListView listView = new PageableListView("data",dataList,10){ @Override protected void populateItem(Item item){ player = (Player)item.getModelObject(); item.add(Label("name",player.getName())); item.add(Label("singlePlayerScore",player.getName())); item.add(Label("doublePlayerScore",player.getName())); item.add(Label("totalScore",String.valueOf(player.getSinglePlayerScore()+player.getDoublePlayerScore()))); } } My Problem is as: What view i get is as: Name single Player Score Double Player Score Total Score A 0 100 100 A 200 0 200 B 0 300 300 B 400 0 400 How do i achieve below view on my webpage? Name single Player Score Double Player Score Total Score A 200 100 300 B 400 300 700 Please help me as to why is this happening? I guess my list has size four that's one reason why as to it is rendering the view? So what can i do to get as require rendering view?

    Read the article

  • Migrating away from Clearcase

    - by John Clark
    We are migrating from Clearcase to another VCS (probably either SVN or Mercurial). For companies that have made this transition, what factors did they find important in selecting another VCS tool, and what practices did they find eased the transition?

    Read the article

  • Avoiding configSections in .NET app.config files

    - by Chris Clark
    I'm looking for a way to avoid declaring my configuration section in the configSections inside the App.config file. Basically, I want to specify my configuration information just like I do for built-in .NET systems. For instance, when configuring WCF, I just put stuff in the <system.serviceModel>, I don't have to declare a section in the configSections up top. The same thing applies for <system.diagnostics> and many other namespaces. I know I could just load it up as an XML file and parse through it, but I'd prefer to stick with the pattern if possible. Moreover, looking at the WCF configuration with Reflector, I notice that it uses the same configuration subsystem (defined in System.Configuration). If you're wondering why this is important, it's because it's confusing our IT people. If it were self contained in one place, it would be much easier on them. I also realize I'll lose the ability to have multiple of the same section type, but that's not important in our case.

    Read the article

  • Persistence scheme & state data for low memory situations (iphone)

    - by Robin Jamieson
    What happens to state information held by a class's variable after coming back from a low memory situation? I know that views will get unloaded and then reloaded later but what about some ancillary classes & data held in them that's used by the controller that launched the view? Sample scenario in question: @interface MyCustomController: UIViewController { ServiceAuthenticator *authenticator; } -(id)initWithAuthenticator:(ServiceAuthenticator *)auth; // the user may press a button that will cause the authenticator // to post some data to the service. -(IBAction)doStuffButtonPressed:(id)sender; @end @interface ServiceAuthenticator { BOOL hasValidCredentials; // YES if user's credentials have been validated NSString *username; NSString *password; // password is not stored in plain text } -(id)initWithUserCredentials:(NSString *)username password:(NSString *)aPassword; -(void)postData:(NSString *)data; @end The app delegate creates the ServiceAuthenticator class with some user data (read from plist file) and the class logs the user with the remote service. inside MyAppDelegate's applicationDidFinishLaunching: - (void)applicationDidFinishLaunching:(UIApplication *)application { ServiceAuthenticator *auth = [[ServiceAuthenticator alloc] initWithUserCredentials:username password:userPassword]; MyCustomController *controller = [[MyCustomController alloc] initWithNibName:...]; controller.authenticator = auth; // Configure and show the window [window addSubview:..]; // make everything visible [window makeKeyAndVisible]; } Then whenever the user presses a certain button, 'MyCustomController's doStuffButtonPressed' is invoked. -(IBAction)doStuffButtonPressed:(id)sender { [authenticator postData:someDataFromSender]; } The authenticator in-turn checks to if the user is logged in (BOOL variable indicates login state) and if so, exchanges data with the remote service. The ServiceAuthenticator is the kind of class that validates the user's credentials only once and all subsequent calls to the object will be to postData. Once a low memory scenario occurs and the associated nib & MyCustomController will get unloaded -- when it's reloaded, what's the process for resetting up the 'ServiceAuthenticator' class & its former state? I'm periodically persisting all of the data in my actual model classes. Should I consider also persisting the state data in these utility style classes? Is that the pattern to follow?

    Read the article

  • Using R to open grib files

    - by robin girard
    I am using R to work with meteorological data. I proceed in two steps: 1- convert grib to netcdf using the commande line function ncl_convert2nc from ncar command language 2- use package ncdf in R to import the netcdf data. I have two problems: 1- I would like to do automatic treatment of many files within R. Can I call ncl_convert2nc within R ? 2- For some particular grib files, the convertion with ncar tool does not work. Is there other ways or trick (other than transcription into netcdf) to read grib files in R ?

    Read the article

  • iPhone , core data, whether NSManagedObject use lazy load mechanism when it was create ?

    - by Robin
    Hi, all, I have use core data in app, I have definite a class that most like as follows: @interface Master : NSManagedObject { } @property (nonatomic, retain) NSSet* Details; .... the entity Master contains a property 'Details' that is relate to another table, this is typical Master-Details relationship, I trace the app , but I find a issue that the property 'Details' value was construct even it never be invoked ..... but I consider that the core data 'should' use some lazy mechanism to improve performance, or maybe I miss some configure step ? because the Master entity contains at least five 'Child' table properties , I have to consider this problem before use the core data .... any help ? thanks for your time!

    Read the article

  • What is the code for a number sign in sharepoint?

    - by Robin
    I've created a link in Sharepoint using the Content Editor Web Part. My link uses html to open up an email with the fields to, cc, subject, and body filled out. However, in the cc section I need a number sign (#) for a mailbox. When I use the html code & #35;(minus the space) my entire code crumbles. Everything starting at the "&" disappears. However, just for kicks I tried & pound;(minus the space) and the code works for a european pound sign. Not sure what else to try. Any suggestions?

    Read the article

  • Why can't I extract a C++ type from a Python type using boost::python::extractor?

    - by Robin
    I've wrapped a C++ class using Py++ and everything is working great in Python. I can instantiate the c++ class, call methods, etc. I'm now trying to embed some Python into a C++ application. This is also working fine for the most-part. I can call functions on a Python module, get return values, etc. The python code I'm calling returns one of the classes that I wrapped: import _myextension as myext def run_script(arg): my_cpp_class = myext.MyClass() return my_cpp_class I'm calling this function from C++ like this: // ... excluding error checking, ref counting, etc. for brevity ... PyObject *pModule, *pFunc, *pArgs, *pReturnValue; Py_Initialize(); pModule = PyImport_Import(PyString_FromString("cpp_interface")); pFunc = PyObject_GetAttrString(pModule, "run_script"); pArgs = PyTuple_New(1); PyTuple_SetItem(pArgs, 0, PyString_FromString("an arg")); pReturnValue = PyObject_CallObject(pFunc, pArgs); bp::extract< MyClass& > extractor(pReturnValue); // PROBLEM IS HERE if (extractor.check()) { // This check is always false MyClass& cls = extractor(); } The problem is the extractor never actually extracts/converts the PyObject* to MyClass (i.e. extractor.check() is always false). According to the docs this is the correct way to extract a wrapped C++ class. I've tried returning basic data types (ints/floats/dicts) from the Python function and all of them are extracted properly. Is there something I'm missing? Is there another way to get the data and cast to MyClass?

    Read the article

  • iPhone, how to dyanmic create new entity (table) via core data model?

    - by Robin
    as topic, I just want create new Entity(table) in sqlite , my code as follows: +(BOOL)CreateDataSet:(NSManagedObjectModel *) model attributes:(NSDictionary*)attributes entityName:(NSString*) entityName { NSEntityDescription *entityDef = [[NSEntityDescription alloc] init]; [entityDef setName:entityName]; [entityDef setManagedObjectClassName:entityName]; [model setEntities:[NSArray arrayWithObject:entityDef]]; //@step NSArray *properties = [CoreDataHelper CreateAttributes:attributes]; [entityDef setProperties:properties]; [entityDef release]; return TRUE; } but it throw errors: Terminating app due to uncaught exception 'NSInternalInconsistencyException', reason: 'Can't modify an immutable model.' * Call stack at first throw: ( 0 CoreFoundation 0x01c5abe9 __exceptionPreprocess + 185 1 libobjc.A.dylib 0x01daf5c2 objc_exception_throw + 47 2 CoreData 0x0152634a -[NSManagedObjectModel(_NSInternalMethods) _throwIfNotEditable] + 106 3 CoreData 0x01526904 -[NSManagedObjectModel setEntities:] + 36 .... that seem show the model is read only..... anyone can help on this problem? thanks

    Read the article

  • How to parse a URL in C?

    - by Robin
    Hi, Im wondering how to parse a url into an URL object(of some kind) in C. So that I would be able to extract key/val objects from a querystring. Have looked at: http://stackoverflow.com/questions/726122/best-ways-of-parsing-a-url-using-c And several other resources, even Google Code, but haven't found anything in my taste.. And no, using sscanf, and regex is not an alternative. Saying, unless I have to write my own parser.. Would be greatful for any tips or help on where I could find this!

    Read the article

  • streaming to correct network interface

    - by robin hood
    I have IP cam that supports RTSP streaming. It's connected to router with 2 network cards with IP1 and IP2 addresses. I make 2 connections to IP cam by IP1 and IP2 addresses from the same IP and I need to receive corresponding streams thru correct network card, but both streams (RTP over UDP) go thru IP1. How this can be resolved? I don't know if RTSP server binds UDP sockets to corresponding IP and I don't know what IP stack is in IP cam (weak end system or strong end system). I haven't found anything interesting in router configuration. As I understand, routing table cannot help me cos I'm connected from the same IP, is it right? Also Sorry for incomplete info but it's all I have at the moment. Thanks for your time.

    Read the article

  • Cast object as OleVariant in Delphi

    - by Alan Clark
    Is there a way to pass a wrap and unwrap a TObject descendent in an OleVariant? I am trying to pass a TObject across automation objects. I know it's not a good idea but I don't have a good alternative. Something like this: function GetMyObjAsVariant; var MyObj: TMyObj; begin MyObj := TMyObj.Create; result := OleVariant(MyObj); end; Which would be used by a client as var MyObj: TMyObj; begin MyObj := GetMyObjAsVariant as TMyObj; end; This fails to compile, returning E2015 Operator not applicable to this operand type.

    Read the article

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