Search Results

Search found 35201 results on 1409 pages for 'custom build step'.

Page 57/1409 | < Previous Page | 53 54 55 56 57 58 59 60 61 62 63 64  | Next Page >

  • How to get MSBuild Exec to run a java program?

    - by Vaccano
    I am trying to run a command line action in my Team Build (MSBuild). When I run it on the command line of the build machine it works fine. But when run in the build script I get a "exited with code 3". This is command that I am running: C:\Program Files\Wavelink\Avalanche\PackageBuilder.\jresdk\bin\java -classpath "WLUtil.jar;WLPackageBuilder.jar" com.wavelink.buildpkg.AvalanchePackageBuilder /build PackageName This command only works when run from the above directory (I have tried running it from c:\ with the full path at it fails). When I try to run it using ms build this is my statement: <PropertyGroup> <!--Working directory of the Package Builder Call--> <PkgBldWorkingDir>&quot;C:\Program Files\Wavelink\Avalanche\PackageBuilder&quot;</PkgBldWorkingDir> <!--Command line to run to make Package builder "go"--> <PkgBldRun>.\jresdk\bin\java&quot; -classpath &quot;WLUtil.jar;WLPackageBuilder.jar&quot; com.wavelink.buildpkg.AvalanchePackageBuilder</PkgBldRun> </PropertyGroup> <!--Run package builder command line to update the Ava File.--> <Exec ContinueOnError="true" WorkingDirectory="$(PackageBuilderWorkingDir)" Command="$(PkgBldRun) /build PackageName"/> As I said above this "exits with code 3". This is the full output: Task "Exec" Command: .\jresdk\bin\java -classpath "WLUtil.jar;WLPackageBuilder.jar" com.wavelink.buildpkg.AvalanchePackageBuilder /build PackageName The system cannot find the path specified. MSBUILD : warning MSB3073: The command ".\jresdk\bin\java -classpath "WLUtil.jar;WLPackageBuilder.jar" com.wavelink.buildpkg.AvalanchePackageBuilder /build PackageName" exited with code 3. The previous error was converted to a warning because the task was called with ContinueOnError=true. Build continuing because "ContinueOnError" on the task "Exec" is set to "true". Done executing task "Exec" -- FAILED. It says it can't find the file (who knows what file). I have tried it with and without the quotes (") in the working directory and with a full path as the command (gives the same error as when run on the command line). Any ideas on how to make this run a command line action in MS Build?

    Read the article

  • How to compile jsoup through Ant?

    - by JackWM
    I tried to use Ant to compile the jsoup source. I can compile successfully, but cannot pass the test. Here is the process: jsoup version: 1.6.3 ; Ant version: 1.8.2 the source of jsoup is in the directory src/ I made a build file src/build.xml This file contains <project name="jsoup"> <target name="compile"> <mkdir dir="build/classes"/> <javac srcdir="src" destdir="build/classes" includeantruntime="false"/> </target> <target name="jar"> <mkdir dir="build/jar"/> <jar destfile="build/jar/jsoup.jar" basedir="build/classes"> <manifest> <attribute name="Main-Class" value="StateTrace"/> </manifest> </jar> </target> <target name="run"> <!--<java jar="build/jar/jsoup.jar" input="htmls/index.html" fork="true"/>--> <exec executable="java"> <arg value="-jar"/> <arg value="build/jar/jsoup.jar"/> <arg value="htmls/index.html"/> </exec> </target> </project> Note: 1. StateTrace.java is my own test program; 2. htmls/index.html is the input to StateTrace.java. Then I compile and run it with Ant: > ant compile > ant jar > ant run After this, I got err like: run: [exec] Exception in thread "main" java.lang.ExceptionInInitializerError [exec] at org.jsoup.nodes.Entities$EscapeMode.<clinit>(Unknown Source) [exec] at org.jsoup.nodes.Document$OutputSettings.<init>(Unknown Source) [exec] at org.jsoup.nodes.Document.<init>(Unknown Source) [exec] at org.jsoup.parser.TreeBuilder.initialiseParse(Unknown Source) [exec] at org.jsoup.parser.TreeBuilder.parse(Unknown Source) [exec] at org.jsoup.parser.HtmlTreeBuilder.parse(Unknown Source) [exec] at org.jsoup.parser.Parser.parse(Unknown Source) [exec] at org.jsoup.Jsoup.parse(Unknown Source) [exec] at StateTrace.main(Unknown Source) [exec] Caused by: java.lang.NullPointerException [exec] at java.util.Properties$LineReader.readLine(Properties.java:418) [exec] at java.util.Properties.load0(Properties.java:337) [exec] at java.util.Properties.load(Properties.java:325) [exec] at org.jsoup.nodes.Entities.loadEntities(Unknown Source) [exec] at org.jsoup.nodes.Entities.<clinit>(Unknown Source) [exec] ... 9 more [exec] Result: 1 BUILD SUCCESSFUL Total time: 0 seconds However, if I manually compiled all the java source, like javac src/org/jsoup/*.java src/org/jsoup/parser/*.java src/org/jsoup/examples/*.java src/org/jsoup/nodes/*.java src/org/jsoup/safety/*.java src/org/jsoup/select/*.java src/org/jsoup/helper/*.java I could compile successfully and pass my test. Any clue? Thanks!

    Read the article

  • How can a wix custom action dll call be made to use the debug runtime via a merge module?

    - by Benj
    I'm trying to create a debug build with a corresponding debug installer for our product. I'm new to Wix so please forgive any naivety contained herein. The debug Dlls in my project are dependent on both the VS2008 and the VS2008SP1 debug runtimes. I've created a merge module feature in wix to bundle those runtimes with my installer. <Include xmlns="http://schemas.microsoft.com/wix/2006/wi"> <!-- Include our 'variables' file --> <!--<?include variables.wxi ?>--> <!--<Fragment>--> <DirectoryRef Id="TARGETDIR"> <!-- Always install the 32 bit ATL/CRT libraries, but only install the 64 bit ones on a 64 bit build --> <Merge Id="AtlFiles_x86" SourceFile="$(env.CommonProgramFiles)\Merge Modules\Microsoft_VC90_ATL_x86.msm" DiskId="1" Language="1033"/> <Merge Id="AtlPolicy_x86" SourceFile="$(env.CommonProgramFiles)\Merge Modules\policy_9_0_Microsoft_VC90_ATL_x86.msm" DiskId="1" Language="1033"/> <Merge Id="CrtFiles_x86" SourceFile="$(env.CommonProgramFiles)\Merge Modules\Microsoft_VC90_DebugCRT_x86.msm" DiskId="1" Language="1033"/> <Merge Id="CrtPolicy_x86" SourceFile="$(env.CommonProgramFiles)\Merge Modules\policy_9_0_Microsoft_VC90_DebugCRT_x86.msm" DiskId="1" Language="1033"/> <Merge Id="MfcFiles_x86" SourceFile="$(env.CommonProgramFiles)\Merge Modules\Microsoft_VC90_DebugMFC_x86.msm" DiskId="1" Language="1033"/> <Merge Id="MfcPolicy_x86" SourceFile="$(env.CommonProgramFiles)\Merge Modules\policy_9_0_Microsoft_VC90_DebugMFC_x86.msm" DiskId="1" Language="1033"/> <!-- If this is a 64 bit build, install the relevant modules --> <?if $(env.Platform) = "x64" ?> <Merge Id="AtlFiles_x64" SourceFile="$(env.CommonProgramFiles)\Merge Modules\Microsoft_VC90_ATL_x86_x64.msm" DiskId="1" Language="1033"/> <Merge Id="AtlPolicy_x64" SourceFile="$(env.CommonProgramFiles)\Merge Modules\policy_9_0_Microsoft_VC90_ATL_x86_x64.msm" DiskId="1" Language="1033"/> <Merge Id="CrtFiles_x64" SourceFile="$(env.CommonProgramFiles)\Merge Modules\Microsoft_VC90_DebugCRT_x86_x64.msm" DiskId="1" Language="1033"/> <Merge Id="CrtPolicy_x64" SourceFile="$(env.CommonProgramFiles)\Merge Modules\policy_9_0_Microsoft_VC90_DebugCRT_x86_x64.msm" DiskId="1" Language="1033"/> <Merge Id="MfcFiles_x64" SourceFile="$(env.CommonProgramFiles)\Merge Modules\Microsoft_VC90_DebugMFC_x86_x64.msm" DiskId="1" Language="1033"/> <Merge Id="MfcPolicy_x64" SourceFile="$(env.CommonProgramFiles)\Merge Modules\policy_9_0_Microsoft_VC90_DebugMFC_x86_x64.msm" DiskId="1" Language="1033"/> <?endif?> </DirectoryRef> <Feature Id="MS2008_SP1_DbgRuntime" Title="VC2008 Debug Runtimes" AllowAdvertise="no" Display="hidden" Level="1"> <!-- 32 bit libraries --> <MergeRef Id="AtlFiles_x86"/> <MergeRef Id="AtlPolicy_x86"/> <MergeRef Id="CrtFiles_x86"/> <MergeRef Id="CrtPolicy_x86"/> <MergeRef Id="MfcFiles_x86"/> <MergeRef Id="MfcPolicy_x86"/> <!-- 64 bit libraries --> <?if $(env.Platform) = "x64" ?> <MergeRef Id="AtlFiles_x64"/> <MergeRef Id="AtlPolicy_x64"/> <MergeRef Id="CrtFiles_x64"/> <MergeRef Id="CrtPolicy_x64"/> <MergeRef Id="MfcFiles_x64"/> <MergeRef Id="MfcPolicy_x64"/> <?endif?> </Feature> <!--</Fragment>--> </Include> If I'm doing a debug build of the installer, I include that feature like so: <!-- The 'Feature' that contains the debug CRT/ATL libraries --> <?if $(var.Configuration) = "Debug"?> <?include ..\includes\MS2008_SP1_DbgRuntime.wxi?> <?endif?> The only problem is that my installer also includes a custom action which is also dependent on the debug runtime: <!-- Private key installer --> <Binary Id="InstallPrivateKey" SourceFile="..\InstallPrivateKey\win32\$(var.Configuration)\InstallPrivateKey.dll"></Binary> <CustomAction Id='InstallKey' BinaryKey='InstallPrivateKey' DllEntry='InstallPrivateKey'/> So how can I package the debug run time in such a way that the custom action also has access to it?

    Read the article

  • C Problem with Compiler?

    - by Solomon081
    I just started learning C, and wrote my hello world program: #include <stdio.h> main() { printf("Hello World"); return 0; } When I run the code, I get a really long error: Apple Mach-O Linker (id) Error Ld /Users/Solomon/Library/Developer/Xcode/DerivedData/CProj-cwosspupvengheeaapmkrhxbxjvk/Build/Products/Debug/CProj normal x86_64 cd /Users/Solomon/Desktop/C/CProj setenv MACOSX_DEPLOYMENT_TARGET 10.7 /Developer/usr/bin/clang -arch x86_64 -isysroot /Developer/SDKs/MacOSX10.7.sdk -L/Users/Solomon/Library/Developer/Xcode/DerivedData/CProj-cwosspupvengheeaapmkrhxbxjvk/Build/Products/Debug -F/Users/Solomon/Library/Developer/Xcode/DerivedData/CProj-cwosspupvengheeaapmkrhxbxjvk/Build/Products/Debug -filelist /Users/Solomon/Library/Developer/Xcode/DerivedData/CProj-cwosspupvengheeaapmkrhxbxjvk/Build/Intermediates/CProj.build/Debug/CProj.build/Objects-normal/x86_64/CProj.LinkFileList -mmacosx-version-min=10.7 -o /Users/Solomon/Library/Developer/Xcode/DerivedData/CProj-cwosspupvengheeaapmkrhxbxjvk/Build/Products/Debug/CProj ld: duplicate symbol _main in /Users/Solomon/Library/Developer/Xcode/DerivedData/CProj-cwosspupvengheeaapmkrhxbxjvk/Build/Intermediates/CProj.build/Debug/CProj.build/Objects-normal/x86_64/helloworld.o and /Users/Solomon/Library/Developer/Xcode/DerivedData/CProj-cwosspupvengheeaapmkrhxbxjvk/Build/Intermediates/CProj.build/Debug/CProj.build/Objects-normal/x86_64/main.o for architecture x86_64 Command /Developer/usr/bin/clang failed with exit code 1 I am running xCode Should I reinstall DevTools?

    Read the article

  • Synchronizing Mysql Table Schema [on hold]

    - by user1122069
    I have some difficulty keeping track of my SQL changes in a text file in SVN. One solution that I am aware of is to put the SQL queries in files (1.sql, 2.sql...) and to manually load each file at the proper time. Besides missing commas, the process is too cumbersome when builds become more frequent. I have actually taken to asking a co-worker to send me his SQL changes on Skype and we just apply the changes immediately on our local, development, and production servers (using three PhpMyAdmin tabs). I have seen several GUI tools mentioned in similar questions on SO, but these are actually more work and less automated than the aforementioned methods. Is there any standardized process by which this is done in an automated way? I can only guess that large companies build their own mechanisms of keeping track of database schema changes (yet I can't find a word about it - maybe they use files?). This question was closed as off-topic on Stack Overflow, so I am re-posting it here.

    Read the article

  • SQLite Step Failed: attempt to write a readonly database , using wrapper

    - by user271753
    I keep getting an error "SQLite Step Failed: attempt to write a readonly database" when using this code to copy a database: -(void)createEditableCopyOfDatabaseIfNeeded { // Testing for existence BOOL success; NSFileManager *fileManager = [NSFileManager defaultManager]; NSError *error; NSArray *paths = NSSearchPathForDirectoriesInDomains(NSDocumentDirectory, NSUserDomainMask, YES); NSString *documentsDirectory = [paths objectAtIndex:0]; NSString *writableDBPath = [documentsDirectory stringByAppendingPathComponent:@"Money.sqlite"]; success = [fileManager fileExistsAtPath:writableDBPath]; if (success) return; // The writable database does not exist, so copy the default to // the appropriate location. NSString *defaultDBPath = [[[NSBundle mainBundle] resourcePath] stringByAppendingPathComponent:@"Money.sqlite"]; success = [fileManager copyItemAtPath:defaultDBPath toPath:writableDBPath error:&error]; if(!success) { NSAssert1(0,@"Failed to create writable database file with Message : '%@'.", [error localizedDescription]); } } I am using the above code in AppDelegate and this: NSString *writableDBPath = [[NSBundle mainBundle] pathForResource:@"Money" ofType:@"sqlite"]; In ViewController.m I am using http://th30z.netsons.org/2008/11/objective-c-sqlite-wrapper/ what am I doing wrong? This is happening again and again... It was working fine before but again the problem started.

    Read the article

  • 2-step user registration with Django

    - by David S
    I'm creating a website with Django and want a fairly common 2-step user registration. What I mean by this is that the user fills in the some basic user information + some application specific information (sort of like a coupon value). Upon submit, an email is sent to ensure email address is valid. This email should contain a link to click on to "finish" the registration. When the link is clicked, the user is marked as validated and they are directed to a new page to complete optional "user profile" type information. So, pretty basic stuff. I have done some research and found django-registration by James Bennett. I do know who James is and have seen him at PyCons and DjanoCons in the past. There is obviously very few people in the world that know Django better than James (so, I know the quality of the code/app is good). But, it almost seems like a bit of over kill. I've read through the docs and was a bit confused (maybe I'm just being a bit dense today). I believe that if I do use django-registration, I will need to have some custom forms, etc. Is there anything else out there I should evaluate? Or are there any good tutorials or videos on using django-registration? I've done a bit of googling, but haven't found anything. But, I suspect that it might be a case of a lot of very common words that don't really find what you are looking for (django user registration tutorial/example). Or is just a case where it would be just about as easy to build your own solution with Django forms, etc? Here is the tech stack I'm using: Python 2.7.2 Django 1.3.1 PostgreSQL 9.1 psycopg2 2.4.1 Twitter Bootstrap 2.0.2

    Read the article

  • Can I write this regex in one step?

    - by Marin Doric
    This is the input string "23x +y-34 x + y+21x - 3y2-3x-y+2". I want to surround every '+' and '-' character with whitespaces but only if they are not allready sourrounded from left or right side. So my input string would look like this "23x + y - 34 x + y + 21x - 3y2 - 3x - y + 2". I wrote this code that does the job: Regex reg1 = new Regex(@"\+(?! )|\-(?! )"); input = reg1.Replace(input, delegate(Match m) { return m.Value + " "; }); Regex reg2 = new Regex(@"(?<! )\+|(?<! )\-"); input = reg2.Replace(input, delegate(Match m) { return " " + m.Value; }); explanation: reg1 // Match '+' followed by any character not ' ' (whitespace) or same thing for '-' reg2 // Same thing only that I match '+' or '-' not preceding by ' '(whitespace) delegate 1 and 2 just insert " " before and after m.Value ( match value ) Question is, is there a way to create just one regex and just one delegate? i.e. do this job in one step? I am a new to regex and I want to learn efficient way.

    Read the article

  • Deleting a resource in a Cucumber (Capybara) step doesn't work

    - by Josiah Kiehl
    Here is my Scenario: Scenario: Delete a match Given pojo is logged in And there is a match with the following: | game_id | 1 | | name | Game del Pojo | | date_and_time | 2010-02-23 17:52:00 | | players | 2 | | teams | 2 | | comment | This is an awesome comment | | user_id | 1 | And I am on the show match 1 page And show me the page When I follow "Delete" And I follow "Yes, delete it" Then there should not be a match with the following: | game_id | 1 | | name | Game del Pojo | | date_and_time | 2010-02-23 17:52:00 | | players | 2 | | teams | 2 | | comment | This is an awesome comment | | user_id | 1 | If I walk through these steps manually, they work. When I click the confirmation: Yes, delete it, then the match is deleted. Cucumber, however, fails to delete the record and the last step fails. And I follow "Yes, delete it" # features/step_definitions/web_steps.rb:32 Then there should not be a match with the following: # features/step_definitions/match_steps.rb:8 | game_id | 1 | | name | Game del Pojo | | date_and_time | 2010-02-23 17:52:00 | | players | 2 | | teams | 2 | | comment | This is an awesome comment | | user_id | 1 | <nil> expected but was <#<Match id: 1, name: "Game del Pojo", date_and_time: "2010-02-23 17:52:00", teams: 2, created_at: "2010-03-02 23:06:33", updated_at: "2010-03-02 23:06:33", comment: "This is an awesome comment", players: 2, game_id: 1, user_id: 1>>. (Test::Unit::AssertionFailedError) /usr/lib/ruby/1.8/test/unit/assertions.rb:48:in `assert_block' /usr/lib/ruby/1.8/test/unit/assertions.rb:495:in `_wrap_assertion' /usr/lib/ruby/1.8/test/unit/assertions.rb:46:in `assert_block' /usr/lib/ruby/1.8/test/unit/assertions.rb:83:in `assert_equal' /usr/lib/ruby/1.8/test/unit/assertions.rb:172:in `assert_nil' ./features/step_definitions/match_steps.rb:22:in `/^there should (not)? be a match with the following:$/' features/matches.feature:124:in `Then there should not be a match with the following:' Any clue how to debug this? Thanks!

    Read the article

  • Python 4 step setup with progressBars

    - by Samuel Taylor
    I'm having a problem with the code below. When I run it the progress bar will pulse for around 10 secs as meant to and then move on to downloading and will show the progress but when finished it will not move on to the next step it just locks up. import sys import time import pygtk import gtk import gobject import threading import urllib import urlparse class WorkerThread(threading.Thread): def __init__ (self, function, parent, arg = None): threading.Thread.__init__(self) self.function = function self.parent = parent self.arg = arg self.parent.still_working = True def run(self): # when does "run" get executed? self.parent.still_working = True if self.arg == None: self.function() else: self.function(self.arg) self.parent.still_working = False def stop(self): self = None class MainWindow: def __init__(self): gtk.gdk.threads_init() self.wTree = gtk.Builder() self.wTree.add_from_file("gui.glade") self.mainWindows() def mainWindows(self): self.mainWindow = self.wTree.get_object("frmMain") dic = { "on_btnNext_clicked" : self.mainWindowNext, } self.wTree.connect_signals(dic) self.mainWindow.show() self.installerStep = 0 # 0 = none, 1 = preinstall, 2 = download, 3 = install info, 4 = install #gtk.main() self.mainWindowNext() def pulse(self): self.wTree.get_object("progress").pulse() if self.still_working == False: self.mainWindowNext() return self.still_working def preinstallStep(self): self.wTree.get_object("progress").set_fraction(0) self.wTree.get_object("btnNext").set_sensitive(0) self.wTree.get_object("notebook1").set_current_page(0) self.installerStep = 1 WT = WorkerThread(self.heavyWork, self) #Would do a heavy function here like setup some thing WT.start() gobject.timeout_add(75, self.pulse) def downloadStep(self): self.wTree.get_object("progress").set_fraction(0) self.wTree.get_object("btnNext").set_sensitive(0) self.wTree.get_object("notebook1").set_current_page(0) self.installerStep = 2 urllib.urlretrieve('http://mozilla.mirrors.evolva.ro//firefox/releases/3.6.3/win32/en-US/Firefox%20Setup%203.6.3.exe', '/tmp/firefox.exe', self.updateHook) self.mainWindowNext() def updateHook(self, blocks, blockSize, totalSize): percentage = float ( blocks * blockSize ) / totalSize if percentage > 1: percentage = 1 self.wTree.get_object("progress").set_fraction(percentage) while gtk.events_pending(): gtk.main_iteration() def installInfoStep(self): self.wTree.get_object("btnNext").set_sensitive(1) self.wTree.get_object("notebook1").set_current_page(1) self.installerStep = 3 def installStep(self): self.wTree.get_object("progress").set_fraction(0) self.wTree.get_object("btnNext").set_sensitive(0) self.wTree.get_object("notebook1").set_current_page(0) self.installerStep = 4 WT = WorkerThread(self.heavyWork, self) #Would do a heavy function here like setup some thing WT.start() gobject.timeout_add(75, self.pulse) def mainWindowNext(self, widget = None): if self.installerStep == 0: self.preinstallStep() elif self.installerStep == 1: self.downloadStep() elif self.installerStep == 2: self.installInfoStep() elif self.installerStep == 3: self.installStep() elif self.installerStep == 4: sys.exit(0) def heavyWork(self): time.sleep(10) if __name__ == '__main__': MainWindow() gtk.main()

    Read the article

  • Unable to step into interface implementation configured by unity application block

    - by Rahul
    I have configured a set of interface implementations with EntLib. unity block. The constructor of implementation classes work fine as soon as I run the application: 1. The interface to implement when I run the application the cctor runs fine, which shows that unity resolution was successful: But when I try to call a method of this class, the code just passes through without actually invoking the function of the implemented class: Edit: Added on June 11, 2012 Following is the Unity Configuration I have. (This is all the unity configuration I am doing) public class UnityControllerFactory : DefaultControllerFactory { private static readonly IUnityContainer container; private static UnityControllerFactory factory = null; static UnityControllerFactory() { container = new UnityContainer(); UnityConfigurationSection section = (UnityConfigurationSection)ConfigurationManager.GetSection("unity"); section.Configure(container); factory = new UnityControllerFactory(); } public static UnityControllerFactory GetControllerFactory() { return factory; } protected override IController GetControllerInstance(RequestContext requestContext, Type controllerType) { return container.Resolve(controllerType) as IController; } } I am unable to step into this code and the implementation simply skips out without executing anything. What is wrong here?

    Read the article

  • Visual Studio breaks, and steps, but sometimes steps out

    - by James Wilkins
    Something very odd is going on. It's been going on for some time, but I've just ignored it up to now. I have both a Silverlight and WCF service in my solution, which shares .CS file between them (one project has a link to the file, which exists in the other project). While debugging the Silverlight app, pressing the F10 key steps through code as normal, and when I get to a method call which exists in the shared file (between the projects), and Press F11, it simply skips the method instead of stepping into it (and yes, the "Just My Code" option is not checked). If I put a breakpoint in the method I'm trying to get into, it works fine (as in the debugger will break on the line), but as soon as I step (F10) it exits the method (and with F11 [step into] also). Ok, on first thought, you might think it's to do with the link, but no, it isn't. I tried removing the link and using a copy instead, but the same thing happens. And no, it's not the debug symbols, I looked into that already. The method I'm trying to step through is static, and is in a non-static partial class, in a file shared by both projects. My guess: The same types and static methods exist in the WCF and Silverlight ... would the debugger get confused?

    Read the article

  • Saving custom attributes in NSAttributedString

    - by regulus6633
    I need to add a custom attribute to the selected text in an NSTextView. So I can do that by getting the attributed string for the selection, adding a custom attribute to it, and then replacing the selection with my new attributed string. So now I get the text view's attributed string as NSData and write it to a file. Later when I open that file and restore it to the text view my custom attributes are gone! After working out the entire scheme for my custom attribute I find that custom attributes are not saved for you. Look at the IMPORTANT note here: http://developer.apple.com/mac/library/DOCUMENTATION/Cocoa/Conceptual/AttributedStrings/Tasks/RTFAndAttrStrings.html So I have no idea how to save and restore my documents with this custom attribute. Any help?

    Read the article

  • Using QT to build a WYSIWYG Editor for a Custom Markup Language

    - by Aaron
    I'm new to QT, and am trying to figure out the best means of creating a WYSIWYG editor widget for a custom markup language that displays simple text, images, and links. I need to be able to propagate changes from the WYSIWYG editor to the custom markup representation. As a concrete example of the problem domain, imagine that the custom markup might have a "player" tag which contains a player name and a team name. The markup could look like this: Last week, <player id="1234"><name>Aaron Rodgers</name><team>Packers</team></player> threw a pass. This text would display in the editor as: Last week, Aaron Rodgers of the Packers threw a pass. The player name and the team name would be editable directly within the editor in standard WYSIWYG fashion, so that my users do not have to learn any markup. Also, when the player name is moused-over, a details pop-up will appear about that player, and similarly for the team. With that long introduction, I'm trying to figure out where to start with QT. It seems that the most logical option would be the Rich Text API using a QTextDocument. This approach seems less than ideal given the limitations of a QTextDocument: I can't figure out how to capture navigation events from clicking on links. Following links on click seems to only be enabled when the QTextEdit is readonly. Custom objects that implement QTextObjectInterface are ignored in copy-and-paste operations Any HTML-based markup that is passed to it as Rich Text is retranslated into a series of span tags and lots of other junk, making it extremely difficult to propagate changes from the editor back to the original custom markup. A second option appears to be QWebKit, which allows for live editing of HTML5 markup, so I could specify a two-way translation between the custom markup and HTML5. I'm not clear on how one would propagate changes from the editor back to the original markup in real-time without re-translating the entire document on every text change. The QWebKit solutions looks like awfully bulky to me (Learning WebKit along with QT) to what should be a relatively simple problem. I have also considered implementing the WYSIWYG with a custom class using native QT containers, labels, images, and other widgets manually. This seems like the most flexible approach, and the one most likely not to run into unresolvable problems. However, I'm pretty sure that implementing all the details of a normal text editor (selecting text, font changes, cut-and-paste support, undo/redo, dragging of objects, cursor placement, etc.) will be incredibly time consuming. So, finally, my question: are there any QT gurus out there with some advice on where to start with this sort of project? BTW, I am using QT because the application is a desktop application that needs platform independence.

    Read the article

  • Custom validator not invoked when using Validation Application Block through configuration

    - by Chris
    I have set up a ruleset in my configuration file which has two validators, one of which is a built-in NotNullValidator, the other of which is a custom validator. The problem is that I see the NotNullValidator hit, but not my custom validator. The custom validator is being used to validate an Entity Framework entity object. I have used the debugger to confirm the NotNull is hit (I forced a failure condition so I saw it set an invalid result), but it never steps into the custom one. I am using MVC as the web app, so I defined the ruleset in a config file at that layer, but my custom validator is defined in another project. However, I wouldn't have thought that to be a problem because when I use the Enterprise Library Configuration tool inside Visual Studio 2008 it is able to set the type properly for the custom validator. As well, I believe the custom validator is fine as it builds ok, and the config tool can reference it properly. Does anybody have any ideas what the problem could be, or even what to do/try to debug further? Here is a stripped down version of my custom validator: [ConfigurationElementType(typeof(CustomValidatorData))] public sealed class UserAccountValidator : Validator { public UserAccountValidator(NameValueCollection attributes) : base(string.Empty, "User Account") { } protected override string DefaultMessageTemplate { get { throw new NotImplementedException(); } } protected override void DoValidate(object objectToValidate, object currentTarget, string key, ValidationResults results) { if (!currentTarget.GetType().Equals(typeof(UserAccount))) { throw new Exception(); } UserAccount userAccountToValidate = (UserAccount)currentTarget; // snipped code ... this.LogValidationResult(results, "The User Account is invalid", currentTarget, key); } } Here is the XML of my ruleset in Validation.config (the NotNull rule is only there to force a failure so I could see it getting hit, and it does): <validation> <type defaultRuleset="default" assemblyName="MyProj.Entities, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null" name="MyProj.Entities.UserAccount"> <ruleset name="default"> <properties> <property name="HashedPassword"> <validator negated="true" messageTemplate="" messageTemplateResourceName="" messageTemplateResourceType="" tag="" type="Microsoft.Practices.EnterpriseLibrary.Validation.Validators.NotNullValidator, Microsoft.Practices.EnterpriseLibrary.Validation, Version=4.1.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35" name="Not Null Validator" /> </property> <property name="Property"> <validator messageTemplate="" messageTemplateResourceName="" messageTemplateResourceType="" tag="" type="MyProj.Entities.UserAccountValidator, MyProj.Entities, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null" name="Custom Validator" /> </property> </properties> </ruleset> </type> </validation> And here is the stripped down version of the way I invoke the validation: var type = entity.GetType() var validator = ValidationFactory.CreateValidator(type, "default", new FileConfigurationSource("Validation.config")) var results = validator.Validate(entity) Any advice would be much appreciated! Thanks, Chris

    Read the article

  • python protobufs - avoid the install step ?

    - by orion elenzil
    i'm writing a small python utility which will be consumed by moderately non-technical users and which needs to interface w/ some protobufs. ideally, i would like the only prerequisites to using this on a local machine to be: have python installed * have an SVN checkout of the repository * run a simple bash script to build the local proto .py definitions * run "python myutility" i'm running into trouble around importing descriptor_pb2.py, tho. i've seen Why do I see "cannot import name descriptor_pb2" error when using Google Protocol Buffers? , but would like to avoid adding the additional prerequisite of having run the proto SDK installer. i've modified the bash script to also generate descriptor_pb2.py in the local heirarchy, which works for the first level of imports from my other _pb2.py files, but it looks like descriptor_pb2.py itself tries to import descriptor_pb2 can't find it: $ python myutility.py Traceback (most recent call last): File "myutility.py", line 4, in <module> import protos.myProto_pb2 File "/myPath/protos/myProto_pb2.py", line 8, in <module> from google.protobuf import descriptor_pb2 File "/myPath/google/protobuf/descriptor_pb2.py", line 8, in <module> from google.protobuf import descriptor_pb2 ImportError: cannot import name descriptor_pb2 my local folder looks like: * myutility.py * google/ * protobuf/ * descriptor.py * descriptor_pb2.py * protos * myProto_ob2.py also, i'm a python n00b, so it's possible i'm overlooking something obvious. tia, orion

    Read the article

  • GenerateDSYMFile warning: unable to open object file

    - by regulus6633
    The background: I have a project that I last built on 10.5 on a PPC computer using xcode v3.1. It builds against the 10.4 SDK. I now have a MacBook with 10.6 on it and Xcode v3.2.1. I installed the 10.4 SDK with xcode. So now I want to build the project on an intel chip on 10.6. I first get a build error because I have the wrong version of gcc setup so I change the build settings to use gcc 4.0. The problem: Now when I build the project I get the following warning: GenerateDSYMFile "build/Release/What's Keeping Me?.app.dSYM" "build/Release/What's Keeping Me?.app/Contents/MacOS/What's Keeping Me?" cd "/Users/hmcshane/Development/ Cocoa Projects/What's Keeping Me?" /Developer/usr/bin/dsymutil "/Users/hmcshane/Development/ Cocoa Projects/What's Keeping Me?/build/Release/What's Keeping Me?.app/Contents/MacOS/What's Keeping Me?" -o "/Users/hmcshane/Development/ Cocoa Projects/What's Keeping Me?/build/Release/What's Keeping Me?.app.dSYM" warning: (i386) /Users/hmcshane/Downloads/Csu-71/crt.dynamic_no_pic.o unable to open object file warning: (ppc7400) /Users/hmcshane/Downloads/Csu-71/crt.dynamic_no_pic.o unable to open object file Any idea what this is? And why is the path for the problem files rooted in my downloads folder? The project certainly doesn't reside there.

    Read the article

  • iPhone 4.0 on iPhone but still Ad-Hoc compile for 3.1.3?

    - by Mark
    Device: Version : 3.1 Build: 3511 Device: iPhone OS: iPhone OS 4.0 xCode 3.2.2 (Old) xCode 3.2.3 (New; For iPhone 4.0 Beta) Background: As you can see I installed 4.0 on my iPhone as I read on this forum it's really hard to near impossible to downgrade back to 3.1.3, but it's my only device I have and use for development. When I try to continue to develop and build with the old xCode it tells me that "No provisioned iPhone OS device is connected". When I select Simulator it does compile and build, however when I spread this file it does not work on the devices of my testers, they get a Signed error. When I run the new xCode, it does compile and build on the Device and when I spread this file, it does work on the devices of my testers (which are running the current official version 3.1.3). Questions: Why is there a difference between building for Simulator and Device? A simulator build never seem to work on the devices of my testers because of signing issues and the build for device does work. Currently it seems the old xCode became useless, however I read that you may not use the Beta xCode to build your application for release. So knowing the above how am I able to pull this off with my current setup due the fact the old xCode won't let me build properly.

    Read the article

  • Layout of Ant build.xml with junit tests

    - by Derk
    In a project I have a folder src for all application source code and a different folder test for all junit test (both with a simular package hierarchy). Now I want that Ant can run all tests in in test folder, bot the problem is that now also files in the src folder with "Test" in the filename are included. This is the test target in the build.xml: <target name="test" depends="build"> <mkdir dir="reports/tests" /> <junit fork="yes" printsummary="yes"> <formatter type="xml"/> <classpath> <path location="${build}/WEB-INF/classes"/> <fileset dir="${projectname.home}/lib"> <include name="servlet-api.jar"/> <include name="httpunit.jar"/> <include name="Tidy.jar"/> <include name="js.jar"/> <include name="junit.jar"/> </fileset> </classpath> <batchtest todir="reports/tests"> <fileset dir="${build}/WEB-INF/classes"> <include name="**/*Test.class"/> </fileset> </batchtest> </junit> And I have added the test folder to the build target: <target name="build" depends="init,init-props,prepare"> <javac source="1.5" debug="true" destdir="${build}/WEB-INF/classes"> <src path="src" /> <src path="test" /> <classpath refid="classpath"/> </javac> </target>

    Read the article

  • Filtering custom fields on wordpress admin page

    - by Kyril
    I'm currently working on a wordpress 2.9.2 plugin (my first) that creates additional custom fields that will later be read from the template. The plugin adds an additional meta box to the "Edit Post" screen which is responsible for manipulating these values. My problem is that the custom fields generated by the plugin also show up in the "Custom Fields" box. Ideally I would like for the custom fields generated by the plugin to be managed separately from any other custom fields for that same post/page. Is there a way that I can filter fields specific to my plugin to prevent them from being displayed in the "Custom Fields" box? I have yet to locate any action or filter that will let me capture and manipulate those values before they are rendered on "Edit Post".

    Read the article

  • Strange build issue using Flex Mojo. Looking for troubleshooting suggestions.

    - by WeeJavaDude
    I have ran into a strange issue and I was hoping for some suggeestion on how to attack the problem. Here is the environment. 1) We develop locally using Flex Builder. 2) We use QuickBuild with FlexMojo 3.4.2 for test builds and production 3) In both cases we don't believe optimization is enabled. What we are seeing is some strange behavior relating to the Ctrl-Enter key when doing testing on IE only in our test environment but not locally. By copying some files over locally I have narrowed the issue down to swf files differences. We do see a difference in the size of swf files in our test environment vs our local environments. Couple things that would help me in troubleshooting would be. 1) Is there a way to know what exactly is in the SWF file? What SWCs are included. 2) How does one compare compile settings between a maven mojo configuration and Flex IDE envioronment? Any thoughts or opinions would be very helpful.

    Read the article

  • VS 2008 C++ build output?

    - by STingRaySC
    Why when I watch the build output from a VC++ project in VS do I see: 1Compiling... 1a.cpp 1b.cpp 1c.cpp 1d.cpp 1e.cpp [etc...] 1Generating code... 1x.cpp 1y.cpp [etc...] The output looks as though several compilation units are being handled before any code is generated. Is this really going on? I'm trying to improve build times, and by using pre-compiled headers, I've gotten great speedups for each ".cpp" file, but there is a relatively long pause during the "Generating Code..." message. I do not have "Whole Program Optimization" nor "Link Time Code Generation" turned on. If this is the case, then why? Why doesn't VC++ compile each ".cpp" individually (which would include the code generation phase)? If this isn't just an illusion of the output, is there cross-compilation-unit optimization potentially going on here? There don't appear to be any compiler options to control that behavior (I know about WPO and LTCG, as mentioned above). EDIT: The build log just shows the ".obj" files in the output directory, one per line. There is no indication of "Compiling..." vs. "Generating code..." steps. EDIT: I have confirmed that this behavior has nothing to do with the "maximum number of parallel project builds" setting in Tools - Options - Projects and Solutions - Build and Run. Nor is it related to the MSBuild project build output verbosity setting. Indeed if I cancel the build before the "Generating code..." step, the ".obj" files will not exist for the most recent set of "compiled" files. E.g., if I cancel the build during "c.cpp" above, I will see only "a.obj" and "b.obj".

    Read the article

  • How to write rule for ICU genrb and pkgdata for boost-build?

    - by sandy
    jamroot.jam rule genrb ( sources + : requirements * ) # create *.res files in binary directory { local result ; for local r in $(sources) { res $(r:B) : $(r) ; } } res.jam type.register RES : res ; type.register TXT : txt ; generators.register-standard res.resource : TXT : RES ; actions resource { $(icu_home)\bin64\genrb "-d$(<:D)" "$()" } I need to run pkgdata with parameters: pkgdata [-options] [-] [packageFile] packageFile is a text file containing the list of res-files to package.

    Read the article

  • Consecutive build of VS2005 and VS2008 C++ projects causes LNK1104 error

    - by TestAccount
    I have VS2005 and VS2008 installed on the same machine. I also have a common codebase that I build using both '05 and '08. For this purpose, I have 2 VC projects.. A '08 project called XYZ_2008.vcproj and a '05 project called XYZ_2005.vcproj, and the corresponding 2 slns as well. Both projects output dlls, libs and pdbs to the same output directory (all with appropriate _2005 and _2008 suffixes). Assuming that I am starting from a clean state, I first open XYZ_2005.sln (containing XYZ_2005.vcproj) in VS2005 and build it successfully. Then I close VS2005. Next, I open XYZ_2008.sln (containing XYZ_2008.vcproj) and build (not rebuild) it. At this point, I get an error saying: LINK : fatal error LNK1104: cannot open file 'mfc80u.lib' If now I rebuild the '08 solution, the error goes away and the build succeeds. The build also succeeds if I directly do a rebuild instead of a build for the '08 sln. In spite of everything being separate, the VS08 build seems to be picking up a MFC8 file (from VS05) instead of a MFC9 file. Can somebody please help out with this issue? Thanks in advance!

    Read the article

< Previous Page | 53 54 55 56 57 58 59 60 61 62 63 64  | Next Page >