Search Results

Search found 1676 results on 68 pages for 'andrew philpott'.

Page 52/68 | < Previous Page | 48 49 50 51 52 53 54 55 56 57 58 59  | Next Page >

  • Reporting. MS Word templates population required

    - by Andrew Florko
    Application we developed fills MS Word templates with data from Database. Customers require to have ability edit Word templates via MS Word (change style, font, layout e.t.c) with no additional software to be installed and no training. AFAIK, Sql Reporting Services and Crystal Reports can't populate MS Word templates produced in MS Word. So we implemented our custom solution that maps .net classes onto xml-saved MS Word documents. It looks like we declare class MyTemplate { // maps to [age] field declared in ms document straight in the text int Age { get; set; } // maps to table by attributes applied to property (omitted) List<Person> Persons { get; set; } } We also implemented images insertion. Are there any free libraries for this task or may be you use your own MS-word templators in your projects?

    Read the article

  • Firebug shows error "_11 is undefined"

    - by Andrew
    Actually that's it. What does this error mean? I've googled on it, but found nothing. This error appears in firebug console after the page is loaded, or when i click on tabs. It does not prevent the execution of another JavaScript code, but the nature of it is mysterious for me.

    Read the article

  • Does SQL Server have any kind of magic undo feature?

    - by Andrew G. Johnson
    Long story short is I tried to quickly update a single row in SQL Server using the Management studio and just typed UPDATE table SET column='value' and forgot the WHERE other_column='other_value' portion. Went for lunch, came back and theres 15 unread emails waiting for me. Happened about an hour ago, waiting for the database guy to come back to see when the last backup was. There's no magic UNDO feature though is there?

    Read the article

  • Bash: Continue script if only one instance is running.

    - by Andrew
    Hello, now this is embarrassing. I'm writing quick script and I can't figure out why this statement don't work. if [ $(pidof -x test.sh | wc -w) -eq 1 ]; then echo Passed; fi I also tried using back-ticks instead of $() but it still wouldn't work. Can you see what is wrong with it? pidof -x test.sh | wc -w returns 1 if I run it inside of script, so I don't see any reason why basically if [ 1 -eq 1 ] wouldn't pass. Thanks a lot!

    Read the article

  • Organizing PHP includes in your development environment

    - by Andrew Heath
    I'm auditing my site design based on the excellent Essential PHP Security by Chris Shiflett. One of the recommendations I'd like to adopt is moving all possible files out of webroot, this includes includes. Doing so on my shared host is simple enough, but I'm wondering how people handle this on their development testbeds? Currently I've got an XAMPP installation configured so that localhost/mysite/ matches up with D:\mysite\ in which includes are stored at D:\mysite\includes\ In order to keep include paths accurate, I'm guess I need to replicate the server's path on my local disk? Something like D:\mysite\public_html\ Is there a better way?

    Read the article

  • Extend legacy site with another server-side programming platform best practice

    - by Andrew Florko
    Company I work for have a site developed 6-8 years ago by a team that was enthusiastic enough to use their own private PHP-based CMS. I have to put dynamic data from one intranet company database on this site in one week: 2-3 pages. I contacted company site administrator and she showed me administrative part - CMS allows only to insert html blocks & manage site map (site is deployed on machine that is inside company & fully accessible & upgradeable). I'm not a PHP-guy & I don't want to dive into legacy hardly-who-ever-heard-about CMS engine I also don't want to contact developers team, 'cos I'm not sure they are still present and capable enough to extend this old days site and it'll take too much time anyway. I am about to deploy helper asp.net site on IIS with 2-3 pages required & refer helper site via iframe from present site. New pages will allow to download some dynamic content from present site also. Is it ok and what are the pitfalls with iframe approach?

    Read the article

  • Finding an asp:button and asp:textbox in Javascript

    - by Andrew
    What I'm trying to do is get an asp:button to click. The only problem is that it is within a few tags. Example: <loginview> <asp:login1> <logintemplate> //asp:textbox and asp:button are located here. </loginview> </asp:login> </logintemplate> So how would I get javascript to point to that location so that I can manipulate it. For example, get the button to click.

    Read the article

  • How can I dynamically load and execute all of the Javascript files in a directory?

    - by Andrew
    I'm making a very simple content-management system in Javascript. It uses plugins which are individual .js files which live in a "modules" folder. Currently I'm loading them with JQuery's getScript() function, but I have to manually define the list of available modules. Is there any way to dynamically load the list of Javascript files so that the user can install additional modules by simply dropping them into the "modules" folder?

    Read the article

  • Why is my web page left-aligned on iPad?

    - by Andrew
    I recently built a site and centered it using margin: 0 auto. I also wrapped elements in a .wrapper class with a width set to 960px and then had the parent element extend across the whole browser. When I view the Brands screen on an iPad though, the site is left-aligned and does not extend across the whole window. Any thoughts to why this might be happening, and how to correct it? See below for a screenshot:

    Read the article

  • Common Utility for Exception Searching

    - by Andrew
    I wrote this little helper method to search the exception chain for a particular exception (either equals or super class). However, this seems like a solution to a common problem, so was thinking it must already exist somewhere, possibly in a library I have already imported. So, any ideas on if/where this might exist? boolean exceptionSearch(Exception base, Class<?> search) { Throwable e = base; do { if (search.isAssignableFrom(e.getClass())) { return true; } } while ((e = e.getCause()) != null); return false; }

    Read the article

  • MySQL: Question about SELECT WHERE AND/OR

    - by Andrew
    I'm trying to write a query that returns the same result from three different events, but I think I am doing it wrong. I can run my query against one event ID and it works. How can I select all three? Here's what I have so far: SELECT * FROM `Registrations` WHERE `Role` = "Attendee" AND `RegistrationStatus_ID` = "1" AND `DigSignature` IS NULL AND `Event_ID` = "147" OR `Event_ID` = "155" OR `Event_ID` = "160"

    Read the article

  • Is it okay for multiple objects to retain the same object in Objective-C/Cocoa?

    - by Andrew Arrow
    Say I have a tableview class that lists 100 Foo objects. It has: @property (nonatomic, retain) NSMutableArray* fooList; and I fill it up with Foos like: self.fooList = [NSMutableArray array]; while (something) { Foo* foo = [[Foo alloc] init]; [fooList addObject:foo]; [foo release]; } First question: because the NSMutableArray is marked as retain, that means all the objects inside it are retained too? Am I correctly adding the foo and releasing the local copy after it's been added to the array? Or am I missing a retain call? Then if the user selects one specific row in the table and I want to display a detail Foo view I call: FooView* localView = [[FooView alloc] initWithFoo:[self.fooList objectAtIndex:indexPath.row]]; [self.navigationController pushViewController:localView animated:YES]; [localView release]; Now the FooView class has: @property (nonatomic, retain) Foo* theFoo; so now BOTH the array is holding on to that Foo as well as the FooView. But that seems okay right? When the user hits the back button dealloc will be called on FooView and [theFoo release] will be called. Then another back button is hit and dealloc is called on the tableview class and [fooList release] is called. You might argue that the FooView class should have: @property (nonatomic, assign) Foo* theFoo; vs. retain. But sometimes the FooView class is called with a Foo that's not also in an array. So I wanted to make sure it was okay to have two objects holding on to the same other object.

    Read the article

  • Do I have to call release on an objective-c retain class variable when setting it to a new object?

    - by Andrew Arrow
    Say I have: @property (nonatomic,retain) NSString *foo; in some class. And I call: myclass.foo = [NSString stringWithString:@"string1"]; myclass.foo = [NSString stringWithString:@"string2"]; Should I have called [myclass.foo release] before setting it to "string2" to avoid a memory leak? Or the fact that nothing is pointing to the first "string1" object anymore is good enough? And in the dealloc method [foo release] will be called.

    Read the article

  • Mod rewrite urls with

    - by Andrew
    Hey Guys, I'm at my wits end here , I normally like to work things out on my own but this has me well and truly beaten here.. I'm trying to mod rewrite my urls that contain pluses... /search.php?q=can+be+any+length to /can-be-any-length.html Any help would be really appreciated becaus rewriting the + php is not an option

    Read the article

  • JQuery Load() syntax - Changing data source on mouseenter

    - by Andrew Parisi
    Hey everyone. I've written this simple function that is supposed to load a portion of an XML file on mouseenter. It works fine when I specify the data source explicitly, shown below. I have a number of '.invest-port-thumb' divs, each with a unique link. The following code works fine—but it loads the whole XML file—and I only want a portion: $(document).ready(function() { $('.invest-port-thumb a').mouseenter(function() { $('#slider-name').load(this.href); }); }); This code also works fine—loading only the 'cName' portion that I want it to load...Except that this code refers to one of the files, instead of the value of this.href. $(document).ready(function() { $('.invest-port-thumb a').mouseenter(function() { $('#slider-name').load('port/atd.xml cName'); }); }); I guess what I'm saying, syntax wise—How can I combine this.href and the data matching cName? Thanks for the help!

    Read the article

  • App Engine: how would you... snapshotting entities

    - by Andrew B.
    Let's say you have two kinds, Message and Contact, related by a db.ListProperty of keys on Message. A user creates a message, adds some contacts as recipients, and emails the message. Later, the user deletes one of the contact entities that was a recipient of the message. Our application should delete the appropriate Contact entity, but we want to preserve the original recipient list for the message that was sent for the user's records. In essence, we want a snapshot of the message entity at the time it was sent. If we naively delete the contact entity, though, we lose snapshot integrity; if not, we are left with an invalid key. How would you handle this situation, either in controller logic or model changes? class User(db.Model): email = db.EmailProperty(required=True) class Contact(db.Model): email = db.EmailProperty(required=True) user = db.ReferenceProperty(User, collection_name='contacts') class Message(db.Model): recipients = db.ListProperty(db.Key) # contacts sender = db.ReferenceProperty(User, collection_name='messages') body = db.TextProperty() is_emailed = db.BooleanProperty(default=False)

    Read the article

  • JTable cells not rendering shapes properly

    - by Andrew
    I'm trying to render my JTable cells with a subclassed JPanel and the cells should appear as coloured rectangles with a circle drawn on them. When the table displays initially everything looks OK but then when a dialog or something is displayed over the cells when it is removed the cells that have been covered do not rendered properly and the circles are broken up etc. I then have to move the scroll bar or extend the window to get them to redraw properly. The paintComponent method of the component I'm using to render the cells is below: protected void paintComponent(Graphics g) { setOpaque(true); super.paintComponent(g); Graphics2D g2d = (Graphics2D) g; GradientPaint gradientPaint = new GradientPaint(new Point2D.Double(0, 0), Color.WHITE, new Point2D.Double(0, getHeight()), paintRatingColour); g2d.setPaint(gradientPaint); g2d.fillRect(0, 0, getWidth(), getHeight()); g2d.setRenderingHint(RenderingHints.KEY_ANTIALIASING, RenderingHints.VALUE_ANTIALIAS_ON); g2d.setRenderingHint(RenderingHints.KEY_RENDERING, RenderingHints.VALUE_RENDER_QUALITY); Rectangle clipBounds = g2d.getClipBounds(); int x = new Double(clipBounds.getWidth()).intValue() - 15; int y = (new Double(clipBounds.getHeight()).intValue() / 2) - 6; if (level != null) { g2d.setColor(iconColour); g2d.drawOval(x, y, width, height); g2d.fillOval(x, y, width, height); } }

    Read the article

  • BlackBerry responseXML is null

    - by Andrew
    I'm trying to port a portion of AJAX code I wrote over to the BlackBerry application's embedded browser. Our base build is 4.6.1 and the RIM documentation claims that XMLHttpRequest's responseXML is available starting with this version. And when I request an XML file from my local server, I get back the responseText (so I know the request is working), but the responseXML is always null. I've made sure the HTTP "Content-Type" header is set to "text/xml" and I am getting the correct data loaded in a web browser. It's just nulling out in the BB web environment. Does anyone know what might be happening? A backup of using the responseText and piping it through DOMParser is not possible because that object was not added to the BB browser until 4.7.1. So I'm not sure what fallback I have.

    Read the article

  • Programmatic Text Wrapping in TextView

    - by Andrew
    I'm working on a custom widget for my application to replicate the look of a Preference button for layouts. The issue is the 'summary' text wont wrap when it hits the right wall of the view. One of the goals I'm trying to keep is that this widget is completely made from java with no xml attributes. here's what the widget looks like at the moment: http://dl.dropbox.com/u/56017670/Screenshot_2012-09-05-17-22-45.png notice that the middle two don't wrap the text but the text obviously runs right off the edge of the widget below is the code I'm using to create the text view. public void setSummary(String summary) { if (!TextUtils.isEmpty(summary)) { if (mSummaryView == null) { mSummaryView = new TextView(mContext); mSummaryView.setTextSize(14); mSummaryView.setTextColor(mContext.getResources().getColor( android.R.color.tertiary_text_dark)); addView(mSummaryView); } mSummaryView.setText(summary); mSummaryView.setVisibility(View.VISIBLE); } else { if (mSummaryView != null) { mSummaryView.setVisibility(View.GONE); } } mSummaryText = summary; } and here is the code I'm using to layout mSummaryView mSummaryView.layout( mPreferencePadding + mIconWidth, centerVertical + (mCombinedTextHeight / 2) - mSummaryHeight, width - mPreferencePadding, centerVertical + (mCombinedTextHeight / 2)); I've tried to add mSummaryView.setSingleLine(false); along with quite a few other tricks but they all ended in the same way.

    Read the article

  • Changing printer preferences in Windows programmatically

    - by Andrew Alexander
    I've written a script that installs several printers for a new user. I want to change the settings on some of these so that they can print on both sides of the page. I BELIEVE this involves modifying an attribute with printui, however it might need VB script or possibly another .NET language (I'd either use VB, C# or IronPython). I can add a comment to a given printer, but how do I select preferences and modify them? Pseudocode would look like this: printui.exe /n printername /??? [how to change quality desired] OR calls to the relevant Windows API.

    Read the article

  • Python - removing double quotation marks " so that script runs

    - by andrew k
    I am using Python scripts to edit the table of many shape files. The following script runs fine, but if there are any " marks in the SIT_FULL_S field, the script errors and shuts down. gp.CalculateField_management(fc + "\\Parcels.shp","SIT_FULL_S", "!SIT_FULL_S!.lstrip('0')", "PYTHON") arcgisscripting.ExecuteError: ERROR 000539: Error running expression: "9030 W SR 2 HWY "A"".lstrip('0') <type 'exceptions.SyntaxError'>: invalid syntax (<string>, line 1) Failed to execute (CalculateField). I have two options, create a new script that runs through and deletes all occurances of ", and then run the above script or modify the above script to ignore the " and contiue running. Can anyone help ?

    Read the article

  • How can I theme custom form(drupal 6.x)

    - by Andrew
    DRUPAL 6.X I have this custom form constructor inside my custom module which is invoke through ajax request. I’m attempting to theme this form with the template file reside in my theme directory. For that matter, I’ve registered my theme inside template.php file which reside in my theme folder. Here’s how this file looks – function my_theme() { return array( 'searchdb' => array( 'arguments' => array('form' => NULL), 'template' => 'searchform', ) ); } And the following is the excerpt of module code – function test_menu() { $my_form['searchdb'] = array( 'title' => 'Search db', 'page callback' => 'get_form', 'page arguments' => array(0), 'access arguments' => array('access content'), 'type' => MENU_CALLBACK, ); return $my_form; } function get_form($formtype){ switch($formtype){ case 'searchdb' : echo drupal_get_form('searchdb'); break; } } function searchdb(){ $form['customer_name'] = array( '#type' => 'textfield', '#title' => t('Customer Name'), '#size' => 50, '#attributes' => array('class' => 'name-textbox'), ); return $form; } As you can imagine, this is not working at all. Just to test if my theme is even registered, I’ve also tested with theme function but, it’s not called. I've checked template file name and form-id(through the outputted html source) and everything seems ok. I would be glad if anyone could point me to the right direction.

    Read the article

< Previous Page | 48 49 50 51 52 53 54 55 56 57 58 59  | Next Page >