Search Results

Search found 10 results on 1 pages for 'm babcock'.

Page 1/1 | 1 

  • Programmatically Insert Page Break in Active Report

    - by Kevin Babcock
    I've been scouring the web for a good example, but cannot figure out how to add a page break to an Active Reports report programmatically. The reports I'm working with usually require 1-2 pages for each record. In order to support dual-sided printing of the reports I want to insert a blank page for each record that uses an odd number of pages, ensuring that each new record is printed on the front of each printed page. I'm very new to Active Reports, so any suggestions, code samples, or links are much appreciated!

    Read the article

  • Add KO "data-bind" attribute on $(document).ready

    - by M.Babcock
    Preface I've rarely ever been a JS developer and this is my first attempt at doing something with Knockout.js. The question to follow likely illustrates both points. Backgound I have a fairly complex MVC3 application that I'm trying to get to work with KO (v2.0.0.0). My MVC app is designed to generically control which fields appear in the view (and how they are added to the view). It makes use of partial views to decide what to draw in the view based on the user's permissions (If the user is in group A then show control A, if the user in group B then show control B or possibly if the user is in group A don't include the control at all). Also, my model is very flat so I'm not sure the built-in ability to apply my ViewModel to a specific portion of the view will help. My solution to this problem is to provide an action in my controller that responds with an object in JSON format with that contains the JQuery selector and the content to assign to the "data-bind" attribute and bind the ViewModel to the View in the $(document).ready event using the values provided. Failed Proof-of-concept My first attempt at proving that this works doesn't actually seem to work, and by "doesn't work" I mean it just doesn't bind the values at all (as can be seen in this jsfiddle). I've tried it with the applyBindings inside of the ready event and not, but it doesn't seem to make any bit of difference. Question What am I doing wrong? Or is this just not something that can work with KO (though I've seen at least one example online doing the same thing and it supposedly works)? Like I said in the preface, I've only ever pretended to be a JS developer (though I've generally gotten it to work in the past) so I'm at a loss where to start trying to figure out what I'm doing wrong. Hopefully this isn't a real noob question.

    Read the article

  • MUL instruction help

    - by Tanner Babcock
    I've read a few tutorials and examples, but I cannot wrap my head around how the MUL instruction works. I've used ADD and SUB without problems. So apparently this instruction multiplies its operand by the value in a register. What register (eax, ebp, esp, etc.) is multiplied by the first operand? And what register is the result stored in, so I can move it to the stack? Sorry, I'm just learning x86 assembly. When I try to compile this line... mull $9 I get, "Error: suffix or operands invalid for 'mul'". Can anyone help me out? Thanks. EDIT: OK Madhur, I replaced "mull" with "mul" and I'm still getting the same error. Here's the whole source. .globl _main _main: pushl %ebp movl %esp, %ebp subl $8, %esp movl $7, %eax mul $9 movl %eax, (%esp) call _putchar xorl %eax, %eax leave ret

    Read the article

  • Possible to Inspect Innards of Core C# Functionality

    - by Nick Babcock
    I was struck today, with the inclination to compare the innards of Buffer.BlockCopy and Array.CopyTo. I am curious to see if Array.CopyTo called Buffer.BlockCopy behind the scenes. There is no practical purpose behind this, I just want to further my understanding of the C# language and how it is implemented. Don't jump the gun and accuse me of micro-optimization, but you can accuse me of being curious! When I ran ILasm on mscorlib.dll I received this for Array.CopyTo .method public hidebysig newslot virtual final instance void CopyTo(class System.Array 'array', int32 index) cil managed { // Code size 0 (0x0) } // end of method Array::CopyTo and this for Buffer.BlockCopy .method public hidebysig static void BlockCopy(class System.Array src, int32 srcOffset, class System.Array dst, int32 dstOffset, int32 count) cil managed internalcall { .custom instance void System.Security.SecuritySafeCriticalAttribute::.ctor() = ( 01 00 00 00 ) } // end of method Buffer::BlockCopy Which, frankly, baffles me. I've never run ILasm on a dll/exe I didn't create. Does this mean that I won't be able to see how these functions are implemented? Searching around only revealed a stackoverflow question, which Marc Gravell said [Buffer.BlockCopy] is basically a wrapper over a raw mem-copy While insightful, it doesn't answer my question if Array.CopyTo calls Buffer.BlockCopy. I'm specifically interested in if I'm able to see how these two functions are implemented, and if I had future questions about the internals of C#, if it is possible for me to investigate it. Or am I out of luck?

    Read the article

  • Problem convert column values from VARCHAR(n) to DECIMAL

    - by Kevin Babcock
    I have a SQL Server 2000 database with a column of type VARCHAR(255). All the data is either NULL, or numeric data with up to two points of precision (e.g. '11.85'). I tried to run the following T-SQL query but received the error 'Error converting data type varchar to numeric' SELECT CAST([MyColumn] AS DECIMAL) FROM [MyTable]; I tried a more specific cast, which also failed. SELECT CAST([MyColumn] AS DECIMAL(6,2)) FROM [MyTable]; I also tried the following to see if any data is non-numeric, and the only values returned were NULL. SELECT ISNUMERIC([MyColumn]), [MyColumn] FROM [MyTable] WHERE ISNUMERIC([MyColumn]) = 0; I tried to convert to other data types, such as FLOAT and MONEY, but only MONEY was successful. So I tried the following: SELECT CAST(CAST([MyColumn] AS MONEY) AS DECIMAL) FROM [MyTable]; ...which worked just fine. Any ideas why the original query failed? Will there be a problem if I first convert to MONEY and then to DECIMAL? Thanks!

    Read the article

1