Daily Archives

Articles indexed Monday April 5 2010

Page 6/106 | < Previous Page | 2 3 4 5 6 7 8 9 10 11 12 13  | Next Page >

  • Creating Tables and Retrieving Query results with Dynamics AX 2009 business connector

    - by namenlos
    I'm writing a C# command line tool to fetch data from AX and to add data (create new tables) to AX. Fetching data from an AX table is easy and documented here: http://msdn.microsoft.com/en-us/library/cc197126.aspx Adding data to an existing table is also easy: http://msdn.microsoft.com/en-us/library/aa868997.aspx But I cannot figure out how to do two things: Create a new AX Table Retrieve data from an AX Query Can someone please share some sample code or give some pointers on where to start looking. My searches on Google and MSDN have not revealed much. NOTE: I am not an experienced AX or ERP developer.

    Read the article

  • UIView transparency shows how the sausages are made!

    - by quixoto
    I have a UIView container that has two UIImageViews inside it, one partially obscuring the other (they're being composed like this to allow for occasional animation of one "layer" or another. Sometimes I want to make this container 50% alpha, so what the users sees fades. Here's the problem: setting my container view to 50% alpha makes all my subviews inherit this as well, and now you can see through the first subview into the second, which in my application has a weird X-Ray effect that I'm not looking for. What I'm after, of course, is for what the user currently sees to become 50% transparent-- the equivalent of flattening the visible view into one bitmap, and then making that 50% alpha. What are my best bets for accomplishing this? Ideally would like to avoid actually, dynamically flattening the views if I can help it, but best practices on that welcome as well. Am I missing something obvious? Since most views have subviews and would run into this issue, I feel like there's some obvious solution here. Thanks!

    Read the article

  • (partial apply str) and apply-str in clojure's ->

    - by Jason Baker
    If I do the following: user=> (-> ["1" "2"] (partial apply str)) #<core$partial__5034$fn__5040 clojure.core$partial__5034$fn__5040@d4dd758> ...I get a partial function back. However, if I bind it to a variable: user=> (def apply-str (partial apply str)) #'user/apply-str user=> (-> ["1" "2" "3"] apply-str) "123" ...the code works as I intended it. I would assume that they are the same thing, but apparently that isn't the case. Can someone explain why this is to me?

    Read the article

  • pthread with unique struct as parameter C

    - by sergiobuj
    Hi, i have this piece of code that is giving me trouble. I know all the threads are reading the same struct. But i have no idea how to fix this. #include <pthread.h> #include <stdio.h> #include <stdlib.h> typedef struct { int a,b; } s_param; void * threadfunc(void *parm) { s_param *param2 = parm; printf("ID:%d and v:%d\n",param2->a,param2->b); pthread_exit(NULL); } int main(int argc, char **argv) { pthread_t thread[3]; int rc=0,i; void * status; for(i=0; i<3 ; ++i){ s_param param; param.b=10; param.a=i; rc = pthread_create(&thread[i], NULL, threadfunc, &param ); // !!!! if(rc){ exit(1); } } for(i=0; i<3 ; ++i){ pthread_join(thread[i],&status); } return 0; } output: ID:2 and v:10 ID:2 and v:10 ID:2 and v:10 and what i need: ID:0 and v:10 ID:1 and v:10 ID:2 and v:10 Thank you.

    Read the article

  • Friction in Box2d

    - by Rosarch
    I am using Box2d for a topdown game. The "ground" is a series of tiles, where each tile is a static body with a sensor shape. Can I make friction take effect for this, even though the objects aren't really "colliding" with the ground? If Box2d won't let me do this, I considered trying to implement my own by detecting what force is currently moving the object, and applying a force opposite to it, but I'm not quite sure how to detect that force.

    Read the article

  • Trouble parsing quotes with SAX parser (javax.xml.parsers.SAXParser) on Android API 1.5

    - by johnrock
    When using a SAX parser, parsing fails when there is a " in the node content. How can I resolve this? Do I need to convert all " characters? In other words, anytime I have a quote in a node: <node>characters in node containing "quotes"</node> That node gets butchered into multiple character arrays when the Handler is parsing it. Is this normal behaviour? Why should quotes cause such a problem? Here is the code I am using: import javax.xml.parsers.SAXParser; import javax.xml.parsers.SAXParserFactory; import org.apache.http.HttpEntity; import org.apache.http.HttpResponse; import org.apache.http.client.methods.HttpGet; import org.xml.sax.InputSource; import org.xml.sax.XMLReader; ... HttpGet httpget = new HttpGet(GATEWAY_URL + "/"+ question.getId()); httpget.setHeader("User-Agent", PayloadService.userAgent); httpget.setHeader("Content-Type", "application/xml"); HttpResponse response = PayloadService.getHttpclient().execute(httpget); HttpEntity entity = response.getEntity(); if(entity != null) { SAXParserFactory spf = SAXParserFactory.newInstance(); SAXParser sp = spf.newSAXParser(); XMLReader xr = sp.getXMLReader(); ConvoHandler convoHandler = new ConvoHandler(); xr.setContentHandler(convoHandler); xr.parse(new InputSource(entity.getContent())); entity.consumeContent(); messageList = convoHandler.getMessageList(); }

    Read the article

  • Software to Monitor the Stability of Internet Connection

    - by Ngu Soon Hui
    Thanks to the excellent internet connection service offered by one of the best ISP in the world, the internet connection in my area is very, very unstable. I can connect some of the time, but MOST of the time the connection will just drop off ( with the error message unable to resolve host) and after a few minutes, it will resume back. If I ping the domain name directly (i.e., ping www.google.com -t in cmd command), I will get a cannot ping message. Because of the flickery nature of the connection, it's pretty hard to prove to the support staff that internet connection is unstable. So I am thinking about using one software to record down the connection situation, so that I can present to the technical staff and make sure that they have no excuse not to fix my problem. Any such software available? Edit: Of course, such software should not record my browsing habit, and must be able to monitor and record the internet connection condition even when I am not online.

    Read the article

  • my first PCIe desktop

    - by agreenberg19
    I want to step up from the slow AGP graphics world to the latest PCI Express one. I understand that the PCIe x16 is the fastest, so which desktop would you suggest I buy? My interests are mainly gaming, so what PCIe x16 video card is worth buying to play today's and tomorrow's games? Thanks, Alan

    Read the article

  • c#, asp.net, dynamicdata Validation Exception Message Caught in JavaScript, not DynamicValidator (Dy

    - by Perplexed
    I have a page here with a few list views on it that are all bound to Linq data sources and they seem to be working just fine. I want to add validation such that when a checkbox (IsVoid on the object) is checked, comments must be entered (VoidedComments on the object). Here's the bound object's OnValidate method: partial void OnValidate(ChangeAction action) { if (action == ChangeAction.Update) { if (_IsVoid) { string comments = this.VoidedComments; if (string.IsNullOrEmpty(this._VoidedComments)) { throw new ValidationException("Voided Comments are Required to Void an Error"); } } } } Despite there being a dynamic validator on the page referencing the same ValidationGroup as the dynaimc control, when the exception fires, it's caught in JavaScript and the debugger wants to break in. The message is never delivered to the UI as expected. Any thoughts as to What's going on?

    Read the article

  • What good software or scripts are available for managing users and subscriptions on our website?

    - by undefined
    hi all, Ok so it's not exactly a programing question but does anyone know or have experience with looking for a system for managing users on a website we are building? what is the shortlist of good feature rich secure solutions. we need Php and mysql integration and payment support for main credit cards. We will also want to be able to track users and generate reports about usage, subscription etc, create and send batch emails etc. It would also be great to have the ability to integrate customer support with this so we can view support tickets raised by users. cheers we are running PHP, mysql on an IIS server

    Read the article

  • Problem with FedEx Address validation web service

    - by DJ Matthews
    Hi, I'm trying to get started with Fedex'es Address validation service and I'm running into a road block with FedEx's own demo application. This is the code in there app: Sub Main() ''# Build a AddressValidationRequest object Dim request As AddressValidationRequest = New AddressValidationRequest() Console.WriteLine("--- Setting Credentials ---") request.WebAuthenticationDetail = New WebAuthenticationDetail() request.WebAuthenticationDetail.UserCredential = New WebAuthenticationCredential() request.WebAuthenticationDetail.UserCredential.Key = "###" ''# Replace "XXX" with the Key request.WebAuthenticationDetail.UserCredential.Password = "###" ''# Replace "XXX" with the Password Console.WriteLine("--- Setting Account Information ---") request.ClientDetail = New ClientDetail() request.ClientDetail.AccountNumber = "###" ''# Replace "XXX" with clients account number request.ClientDetail.MeterNumber = "###" ''# Replace "XXX" with clients meter number request.TransactionDetail = New TransactionDetail() request.TransactionDetail.CustomerTransactionId = "Address Validation v2 Request using VB.NET Sample Code" ''# This is just an echo back request.Version = New VersionId() request.RequestTimestamp = DateTime.Now Console.WriteLine("--- Setting Validation Options ---") request.Options = New AddressValidationOptions() request.Options.CheckResidentialStatus = True request.Options.MaximumNumberOfMatches = 5 request.Options.StreetAccuracy = AddressValidationAccuracyType.LOOSE request.Options.DirectionalAccuracy = AddressValidationAccuracyType.LOOSE request.Options.CompanyNameAccuracy = AddressValidationAccuracyType.LOOSE request.Options.ConvertToUpperCase = True request.Options.RecognizeAlternateCityNames = True request.Options.ReturnParsedElements = True Console.WriteLine("--- Address 1 ---") request.AddressesToValidate = New AddressToValidate(1) {New AddressToValidate(), New AddressToValidate()} request.AddressesToValidate(0).AddressId = "WTC" request.AddressesToValidate(0).Address = New Address() request.AddressesToValidate(0).Address.StreetLines = New String(0) {"10 FedEx Parkway"} request.AddressesToValidate(0).Address.PostalCode = "38017" request.AddressesToValidate(0).CompanyName = "FedEx Services" Console.WriteLine("--- Address 2 ---") request.AddressesToValidate(1).AddressId = "Kinkos" request.AddressesToValidate(1).Address = New Address() request.AddressesToValidate(1).Address.StreetLines = New String(0) {"50 N Front St"} request.AddressesToValidate(1).Address.PostalCode = "38103" request.AddressesToValidate(1).CompanyName = "FedEx Kinkos" Dim addressValidationService As AddressValidationService.AddressValidationService = New AddressValidationService.AddressValidationService ''# Try ''# This is the call to the web service passing in a AddressValidationRequest and returning a AddressValidationReply Console.WriteLine("--- Sending Request..... ---") Dim reply As New AddressValidationReply() reply = addressValidationService.addressValidation(request) Console.WriteLine("--- Processing request.... ---") ''#This is where I get the error If (Not reply.HighestSeverity = NotificationSeverityType.ERROR) And (Not reply.HighestSeverity = NotificationSeverityType.FAILURE) Then If (Not reply.AddressResults Is Nothing) Then For Each result As AddressValidationResult In reply.AddressResults Console.WriteLine("Address Id - " + result.AddressId) Console.WriteLine("--- Proposed Details ---") If (Not result.ProposedAddressDetails Is Nothing) Then For Each detail As ProposedAddressDetail In result.ProposedAddressDetails Console.WriteLine("Score - " + detail.Score) Console.WriteLine("Address - " + detail.Address.StreetLines(0)) Console.WriteLine(" " + detail.Address.StateOrProvinceCode + " " + detail.Address.PostalCode + " " + detail.Address.CountryCode) Console.WriteLine("Changes -") For Each change As AddressValidationChangeType In detail.Changes Console.WriteLine(change.ToString()) Next Console.WriteLine("") Next End If Console.WriteLine("") Next End If Else For Each notification As Notification In reply.Notifications Console.WriteLine(notification.Message) Next End If Catch e As SoapException Console.WriteLine(e.Detail.InnerText) Catch e As Exception Console.WriteLine(e.Message) End Try Console.WriteLine("Press any key to quit !") Console.ReadKey() End Sub It seems to send the request object to the web service, but the"reply" object is returned with "Nothing". I could understand if I wrote the code, but good god... they can't even get their own code to work? Has anyone else seen/fixed this problem?

    Read the article

  • nHibernate one-to-many inserts but doesnt update

    - by user210713
    Instead of getting into code, I have a simple question. Default behavior for a simple one-to-many is that it inserts the child record then updates the foreign key column with the parent key. Has anyone ever had a one-to-many where the child object gets inserted but not updated resulting in a row in my table with a null in the foreign key column? I want the default behaviour for a standard one-to-many. I don't want to have to add the parent as a property to the child. Thanks.

    Read the article

  • How to use WeirdX applet instead of X11 for remote connections in Mac OS X?

    - by penyuan
    When I am away, I've got an Apple PowerBook set up to use X11 forwarding with SSH to connect to a remote iMac client in my room for server administration. Whenever I start X client programs on the client iMac, X11 would start on my PowerBook, which is OK, but... Question: Is it possible to change my settings so I can use the WeirdX (a web-based java X server) applet to take care of the X client programs instead of Mac OS X's default X11? Is there a config file I can edit to chance the $DISPLAY variable, and what should I set it to? Is this even the issue? Thank you very much.

    Read the article

  • If-Modified-Since vs If-None-Match

    - by Roger
    This question is based on this article response header HTTP/1.1 200 OK Last-Modified: Tue, 12 Dec 2006 03:03:59 GMT ETag: "10c24bc-4ab-457e1c1f" Content-Length: 12195 request header GET /i/yahoo.gif HTTP/1.1 Host: us.yimg.com If-Modified-Since: Tue, 12 Dec 2006 03:03:59 GMT If-None-Match: "10c24bc-4ab-457e1c1f" HTTP/1.1 304 Not Modified In this case browser is sending both If-None-Match and If-Modified-Since. My question is on the server side do I need to match BOTH etag and If-Modified-Since before I send 304. Or Should I just look at etag and send 304 if etag is a match. In this case I am ignoring If-Modified-Since .

    Read the article

  • PHP FastCGI SAPI: Reloading PHP Configuration

    - by Emre
    I am using PHP FastCGI SAPI on my web hosting environment to run PHP applications. To spawn FCGI processes I use spawn-fcgi helper program. My problem is whenever I make a change to php.ini file, I have to kill and respawn each FastCGI server for the new configuration to take effect. Is there a way to reload PHP configuration(ie. php.ini directives) without respawning each FastCGI server? I try sending hangup signal (ie. kill -HUP PHPCGIPID) to the servers but this will result in termination of the servers.

    Read the article

  • Mount "locked" SD card as read-write in GNU/Linux

    - by Vi
    My Canon PowerShot A470 + CHDK can write to SD-cards that are "locked" (the lock switch is used to make the card bootable), but GNU/Linux `/dev/mmcblk1': Read-only file system (I'm using "Texas Instrument 5-in-1 Multimedia Card Reader") So I have to switch that switch on and off again and again. ("unlocked" to write to the card in Linux, "locked" to boot the camera from it). How to force locked card to be writable in GNU/Linux?

    Read the article

  • Resizing pages in Adobe Acrobat Pro

    - by KP
    I am using Acrobat Professional 8 to assemble a document from two imported page images (JPGs). Acrobat seems to interpret the images at screen resolution, and creates a document that's about 35" by 46" instead of 8.5" x 11". How can I scale down the page size within Acrobat?

    Read the article

  • Const unsigned char* to char8

    - by BSchlinker
    So, I have two types at the moment: const unsigned char* unencrypted_data_char; string unencrypted_data; I'm attempting to perform a simple conversion of data from one to the other (string - const unsigned char*) As a result, I have the following: strcpy((unencrypted_data_char),(unencrypted_data.c_str())); However, I'm receiving the error: error C2664: 'strcpy' : cannot convert parameter 1 from 'const unsigned char *' to 'char *' Any advise? I thought using reinterpret_cast would help, but it doesn't seem to make a difference.

    Read the article

  • c incompatible types in assignment, problem with pointers?

    - by Fantastic Fourier
    Hi I'm working with C and I have a question about assigning pointers. struct foo { int _bar; char * _car[MAXINT]; // this is meant to be an array of char * so that it can hold pointers to names of cars } int foofunc (void * arg) { int bar; char * car[MAXINT]; struct foo thing = (struct foo *) arg; bar = arg->_bar; // this works fine car = arg->_car; // this gives compiler errors of incompatible types in assignment } car and _car have same declaration so why am I getting an error about incompatible types? My guess is that it has something to do with them being pointers (because they are pointers to arrays of char *, right?) but I don't see why that is a problem. when i declared char * car; instead of char * car[MAXINT]; it compiles fine. but I don't see how that would be useful to me later when I need to access certain info using index, it would be very annoying to access that info later. in fact, I'm not even sure if I am going about the right way, maybe there is a better way to store a bunch of strings instead of using array of char *?

    Read the article

< Previous Page | 2 3 4 5 6 7 8 9 10 11 12 13  | Next Page >