Search Results

Search found 2682 results on 108 pages for 'michael mao'.

Page 59/108 | < Previous Page | 55 56 57 58 59 60 61 62 63 64 65 66  | Next Page >

  • MakeFiles and dependencies

    - by Michael
    Hello, I'm writing a makefile and I can't figure out how to include all my source files without having to write all source file I want to use. Here is the makefile I'm currently using: GCC = $(GNUARM_HOME)\bin\arm-elf-gcc.exe SOURCES=ShapeApp.cpp Square.cpp Circle.cpp Shape.cpp OBJECTS=$(SOURCES:.cpp=.o) EXECUTABLE=hello all: $(EXECUTABLE) $(EXECUTABLE): $(OBJECTS) #$(CC) $(LDFLAGS) $(OBJECTS) -o $@ .cpp.o: $(GCC) -c $< -o $@ How do I automatically add new source file without having to add it to the sources line?

    Read the article

  • When I make a database change, how do I know what needs to be removed and readded to the LinqToSql O

    - by Michael Maddox
    For example, I alter a column in a table to be not null from null. I need to then delete and readd the table. That part is pretty clear. What about views, functions, and stored procedures that access the table, especially that column in the table? I've tried running diffs against the files generated by SQLMetal with some limited success, but even with that it's fairly unclear. I know there is at least one commercial tool out there that claims to address this problem, but I am looking for something free. How are people dealing with this issue?

    Read the article

  • iCloud + Storage of media in iPhone Documents folder

    - by Michael Morrison
    I, like many developers, got an email from Apple recently that stated we should move our data from the documents directory into another folder to permit more streamlined backup to iCloud. In recent testing it appears that [your app] stores a fair amount of data in its Documents folder. Since iCloud backups are performed daily over Wi-Fi for each user's iOS device, it's important to ensure the best possible user experience by minimizing the amount of data being stored by your app. Marco Arment, of instapaper fame, has a good take on the issue, which is that the recommended location for storing downloadable files is in /Library/Caches. However, the problem is that both /tmp and /Caches can be 'cleaned' anytime the OS decides that the device is running low on storage. If your app is cleaned then the data downloaded by your app and stored by your user is gone. Naturally, the user will blame you and not Apple. What to do?

    Read the article

  • Possible uncommitted transactions causing "System.Data.SqlClient.SqlException: Timeout expired" erro

    - by Michael
    My application requires a user to log in and allows them to edit a list of things. However, it seems that if the same user always logs in and out and edits the list, this user will run into a "System.Data.SqlClient.SqlException: Timeout expired." error. I've read comments about increasing the timeout period but I've also read a comment about it possibly caused by uncommitted transactions. And I do have one going in the application. I'll provide the code I'm working with and there is an IF statement in there that I was a little iffy about but it seemed like a reasonable thing to do. I'll just go over what's going on here, there is a list of objects to update or add into the database. New objects created in the application are given an ID of 0 while existing objects have their own ID's generated from the DB. If the user chooses to delete some objects, their IDs are stored in a separate list of Integers. Once the user is ready to save their changes, the two lists are passed into this method. By use of the IF statement, objects with ID of 0 are added (using the Add stored procedure) and those objects with non-zero IDs are updated (using the Update stored procedure). After all this, a FOR loop goes through all the integers in the "removal" list and uses the Delete stored procedure to remove them. A transaction is used for all this. Public Shared Sub UpdateSomethings(ByVal SomethingList As List(Of Something), ByVal RemovalList As List(Of Integer)) Using DBConnection As New SqlConnection(conn) DBConnection.Open() Dim MyTransaction As SqlTransaction MyTransaction = DBConnection.BeginTransaction() Try For Each SomethingItem As Something In SomethingList Using MyCommand As New SqlCommand() MyCommand.Connection = DBConnection If SomethingItem.ID > 0 Then MyCommand.CommandText = "UpdateSomething" Else MyCommand.CommandText = "AddSomething" End If MyCommand.Transaction = MyTransaction MyCommand.CommandType = CommandType.StoredProcedure With MyCommand.Parameters If MyCommand.CommandText = "UpdateSomething" Then .Add("@id", SqlDbType.Int).Value = SomethingItem.ID End If .Add("@stuff", SqlDbType.Varchar).Value = SomethingItem.Stuff End With MyCommand.ExecuteNonQuery() End Using Next For Each ID As Integer In RemovalList Using MyCommand As New SqlCommand("DeleteSomething", DBConnection) MyCommand.Transaction = MyTransaction MyCommand.CommandType = CommandType.StoredProcedure With MyCommand.Parameters .Add("@id", SqlDbType.Int).Value = ID End With MyCommand.ExecuteNonQuery() End Using Next MyTransaction.Commit() Catch ex As Exception MyTransaction.Rollback() 'Exception handling goes here End Try End Using End Sub There are three stored procedures used here as well as some looping so I can see how something can be holding everything up if the list is large enough. Other users can log in to the system at the same time just fine though. I'm using Visual Studio 2008 to debug and am using SQL Server 2000 for the DB.

    Read the article

  • Very Intermittent Orientation on Device & Simulator

    - by Michael Waterfall
    I've noticed that I'm getting very intermittent orientation on my device & the simulator. I have a modal view controller that I present, and that is the only thing in my app which supports rotation. If I launch the app in portrait without moving the device, open the modal VC and then rotate the device, it usually works. However sometimes if I open the app holding the device in landscape, then rotate to portrait, launch the VC and then rotate the device, no rotation occurs. It seems very intermittent. Sometimes if I launch the app in portrait mode and then open the VC and rotate the device, nothing happens, and until I quit and relaunch it no orientation occurs in the app. It's strange because 50% of the time it works! Whenever I launch it through Xcode and set breakpoints in shouldAutorotateToInterfaceOrientation it always works! Anyone ever had this or know what's going on?

    Read the article

  • How to call a wpf singleton service within a wpf singleton service without hanging?

    - by Michael Hedgpeth
    I have two services, one that calls another. Both are marked as singletons as follows: [ServiceBehavior(InstanceContextMode = InstanceContextMode.Single, ConcurrencyMode = ConcurrencyMode.Multiple)] public class Service : IService And I set these up with a ServiceHost as follows: ServiceHost serviceHost = new ServiceHost(singletonElement); serviceHost.Open(); When the parent service tries to call the child service on the same machine, the parent service hangs, waiting for the child service. I'm already considering moving away from the singleton model, but is there anything wrong with my approach? Is there an explanation for this behavior and a way out of it?

    Read the article

  • Blittable Value Types

    - by Michael Covelli
    Here is a list of blittable types. It contains Int32 and Int64. But I don't see just plain "int" on the list. How does C# treat the plain "int" type? Does it just get replaced with Int32 or Int64 depending on the system? Or is there a subtle difference? Will using "int" ever cause a performance hit for marshalling?

    Read the article

  • How can I find out where is my code causing GLib-GObject-CRITICAL

    - by michael
    Hi, When I c/c++ application fails with the following CRITICAL, can you please tell me how can I find out where is the code causing the error? I have tried to run it in Debugger, trying to do a 'bt when the program fails. But it does not show where is the code causing the CRITICAL: (process:3155): GLib-GObject-CRITICAL **: /build/buildd/glib2.0-2.22.3/gobject/gtype.c:2458: initialization assertion failed, use IA__g_type_init() prior to this function (process:3155): GLib-CRITICAL **: g_once_init_leave: assertion `initialization_value != 0' failed (process:3155): GLib-GObject-CRITICAL **: /build/buildd/glib2.0-2.22.3/gobject/gtype.c:2458: initialization assertion failed, use IA__g_type_init() prior to this function (process:3155): GLib-GObject-CRITICAL **: /build/buildd/glib2.0-2.22.3/gobject/gtype.c:2458: initialization assertion failed, use IA__g_type_init() prior to this function (process:3155): GLib-GObject-CRITICAL **: /build/buildd/glib2.0-2.22.3/gobject/gtype.c:2458: initialization assertion failed, use IA__g_type_init() prior to this function (process:3155): GLib-GObject-CRITICAL **: g_type_add_interface_static: assertion `G_TYPE_IS_INSTANTIATABLE (instance_type)' failed (process:3155): GLib-GObject-CRITICAL **: /build/buildd/glib2.0-2.22.3/gobject/gtype.c:2458: initialization assertion failed, use IA__g_type_init() prior to this function Thank you.

    Read the article

  • Using RouteExistingFiles to block access to existing files even if no route exists

    - by Michael Stum
    In ASP.net MVC 2, I can use routes.RouteExistingFiles = true; to send all requests through the routing system, even if they exist on the file system. Usually, this ends up hitting the "{controller}/{action}/{id}" route and throws an exception as the controller cannot be found. I do not want to use that route though (I have only a few URLs and they are specifically mapped), yet I would still like to prevent access to the file system. Basically I want to Whitelist pages using IgnoreRoute. Is there a built-in way to do this? My current approach is to still have the "{controller}/{action}/{id}" route and generate a 404 when this is hit, but I'm just wondering if something is built-in already?

    Read the article

  • SQL Server: Granting db_datawriter on all databases

    - by Michael J Swart
    I want to manage permissions and access to a SQL Server database server on a development machine. I've created a local windows group (called DBReaderGroup) and assigned various people to it. The group was created as a SQL Server login successfully: create login [MYMACHINE\DBReaderGroup] from windows My goal is to grant this group read/write access to all databases (which are constantly being added and dropped). Is it possible to configure the right settings so that SQL Server manages this? My biggest challenge is that each time a db is created, I have to update the "User Mapping" settings for this group on the new database. Am I missing something simple?

    Read the article

  • Using wildcards in prepared statement - MySQLi

    - by Michael Irwin
    Hi! I'm trying to run the following query, and I'm having trouble with the wildcard. function getStudents() { global $db; $users = array(); $query = $db->prepare("SELECT id, adminRights FROM users WHERE classes LIKE ? && adminRights='student'"); $query->bind_param('s', '%' . $this->className . '%'); $query->execute(); $query->bind_result($uid, $adminRights); while ($query->fetch()) { if (isset($adminRights[$this->className]) && $adminRights[$this->className] == 'student') $users[] = $uid; } $query->close(); return $users; } I'm getting an error that states: Cannot pass parameter 2 by reference. The reason I need to use the wildcard is because the column's data contains serialized arrays. I guess, if there's an easier way to handle this, what could I do? Thanks in advance!

    Read the article

  • Memory cleanup on returned array from static method (objective-c)

    - by Michael Bordelon
    In objective-c, I have a utility class with a bunch of static methods that I call for various tasks. As an example, I have one method that returns an NSArray that I allocate in the static method. If I set the NSArray to autorelease, then some time later, the NSArray in my calling method (that is assigned to the returned pointer) losses it's reference because the original form the static method is cleaned up. I can't release the NSArray object in the static method because it needs to be around for the return and assignment. What is the right way to return an object (like the NSArray) from a static class, and have it hang around for the calling class, but then get cleaned up later when it is no longer needed? Do I have to create the object first in the caller and pass in a pointer to the object and then return that same object form the static method? I know this is a basic O-O problem, I just never had this issue in Java and I do not do much C/C++. Thanks for your help.

    Read the article

  • exception message getting lost in IIOP between glassfish domains

    - by Michael Borgwardt
    I'm running two glassfish v2 domains containing stateless session EJBs. In a few cases, an EJB in one domain has to call one in the other. My problem is that when the called EJB aborts with an exception, the caller does not receive the message of the exception and instead reports an internal error that is not helpful at all in diagnosing the problem. What happens seems to be this: At the transport layer, a org.omg.CORBA.portable.ApplicationException is created,which already loses all detail information about the exception except its class. Inside com.sun.jts.CosTransactions.TopCoordinator.get_txcontext(), the status of the transaction ass rolled back causes a org.omg.CosTransactions.Unavailable to be thrown, which gets wrapped and passed around a few times and eventually results into this error being displayed to the user: org.omg.CORBA.INVALID_TRANSACTION: vmcid: 0x0 minor code: 0 completed: No at com.sun.jts.CosTransactions.CurrentTransaction.sendingRequest(CurrentTransaction.java:807) at com.sun.jts.CosTransactions.SenderReceiver.sending_request(SenderReceiver.java:139) at com.sun.jts.pi.InterceptorImpl.send_request(InterceptorImpl.java:344) at com.sun.corba.ee.impl.interceptors.InterceptorInvoker.invokeClientInterceptorStartingPoint(InterceptorInvoker.java:271) at com.sun.corba.ee.impl.interceptors.PIHandlerImpl.invokeClientPIStartingPoint(PIHandlerImpl.java:348) at com.sun.corba.ee.impl.protocol.CorbaClientRequestDispatcherImpl.beginRequest(CorbaClientRequestDispatcherImpl.java:284) at com.sun.corba.ee.impl.protocol.CorbaClientDelegateImpl.request(CorbaClientDelegateImpl.java:184) at com.sun.corba.ee.impl.presentation.rmi.StubInvocationHandlerImpl.privateInvoke(StubInvocationHandlerImpl.java:186) at com.sun.corba.ee.impl.presentation.rmi.StubInvocationHandlerImpl.invoke(StubInvocationHandlerImpl.java:152) at com.sun.corba.ee.impl.presentation.rmi.bcel.BCELStubBase.invoke(BCELStubBase.java:225) Is there anything I can do here to preserve information about the actual cause of the problem?

    Read the article

  • Upload a Photo to Facebook with REST API and Ruby

    - by Michael Waxman
    It's much harder than you'd think: http://wiki.developers.facebook.com/index.php/Photos.upload The tricky part is how to create the MIME multi-part message in Rails, which Facebook requires. I'm also using a Ruby Facebook API gem (mini_fb) which signs my other requests, and in addition to having no idea how to set up the MIME multi-part, even if I did I'm not sure how to add in the required signature values with the gem. Please help!

    Read the article

  • Detecting death of spawned process using Window CRT

    - by Michael Tiller
    Executive summary: I need a way to determine whether a Windows process I've spawned via _spawnl and am communicating with using FDs from _pipe has died. Details: I'm using the low-level CRT function in Windows (_eof, _read) to communicate with a process that was spawned via a call to _spawnl (with the P_NOWAIT) flag. I'm using _pipe to create file descriptors to communicate with this spawned process and passing those descriptors (the FD #) to it on the command line. It is worth mentioning that I don't control the spawned process. It's a black box to me. It turns out that the process we are spawning occasionally crashes. I'm trying to make my code robust to this by detecting the crash. Unfortunately, I can't see a way to do this. It seems reasonable to me to expect that a call to _eof or _read on one of those descriptors would return an error status (-1) if the process had died. Unfortunately, that isn't the case. It appears that the descriptors have a life of their own independent of the spawned process. So even though the process on the other end is dead, I get no error status on the file descriptor I'm using to communicate with it. I've got the PID for the nested process (returned from the _spanwnl call) but I don't see anything I can do with that. My code works really well except for one thing. I can't detect whether the spawned process is simply busy computing me an answer or has died. If I can use the information from _pipe and _spawnl to determine if the spawned process is dead, I'll be golden. Suggestions very welcome. Thanks in advance. UPDATE: I found a fairly simple solution and added it as the selected answer.

    Read the article

  • Can't access CodeBase from a dynamically generated assembly.

    - by Michael Meadows
    I'm trying to create an assembly dynamically in .Net. I can't seem to figure out how to get the CodeBase property to return a value, however. Here's an example: var assemblyName = new AssemblyName { Name = "Whatever", CodeBase = Directory.GetCurrentDirectory() }; var assemblyBuilder = AppDomain.CurrentDomain .DefineDynamicAssembly(assemblyName, AssemblyBuilderAccess.RunAndSave); var moduleBuilder = assemblyBuilder.DefineDynamicModule("WhateverModule", "Whatever.dll"); var typeBuilder = moduleBuilder.DefineType("WhateverType", TypeAttributes.Public); var type = typeBuilder.CreateType(); assemblyBuilder.Save("Whatever.dll"); var codeBase = type.Assembly.CodeBase; // throws the below exception System.NotSupportedException was unhandled Message=The invoked member is not supported in a dynamic assembly. Source=mscorlib StackTrace: at System.Reflection.Emit.InternalAssemblyBuilder.get_CodeBase() at Stupid.Program.Main(String[] args) in C:\Users\Walking Disaster\Documents\Visual Studio 10\Projects\Lingual.Proxy\Stupid\Program.cs:line 25 at System.AppDomain._nExecuteAssembly(RuntimeAssembly assembly, String[] args) at System.AppDomain.ExecuteAssembly(String assemblyFile, Evidence assemblySecurity, String[] args) at Microsoft.VisualStudio.HostingProcess.HostProc.RunUsersAssembly() at System.Threading.ThreadHelper.ThreadStart_Context(Object state) at System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state, Boolean ignoreSyncCtx) at System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state) at System.Threading.ThreadHelper.ThreadStart() Can anyone see what I'm doing wrong?

    Read the article

  • Should i use a trigger or Behaviors for this?

    - by Michael
    I have an abstract object called Applicant and two different types of objects that inherit from Applicant called Business and Individual. So I have three classes that look like this: public abstract class Applicant { ... } public class Individual : Applicant { ... } public class Business : Applicant { ... } Now in the DataGrid I want to show all the details of Applicant object. When you choose a row I want to show details of either the business or individual as a internal grid. Something like this <DataGrid> <DataGrid.Columns> <!--Show different columns --> </DataGrid.Columns> <DataGrid.RowDetailsTemplate> <!--Show if Individual --> <DataGrid> <DataGrid.Columns> <DataGridTextColumn Header="First Name" ... /> <DataGridTextColumn Header="Last Name" ... /> </DataGrid.Columns> </DataGrid> <!--Show if business --> <DataGrid> <DataGrid.Columns> <DataGridTextColumn Header="Business Name" ... /> <DataGridTextColumn Header="Tax id" ... /> </DataGrid.Columns> </DataGrid> </DataGrid.RowDetailsTemplate> </DataGrid> Now I'm not sure if I need to use a Triggers or Behaviors to accomplish this? Thanks for everyones help! FYI I'm using Silverlight 4.0 with Prism.

    Read the article

  • conversion of a varchar to a smalldatetime results in an out-of-range value

    - by michael
    The code: strSql = "insert into table2 (transactiondate) values ('" & transactiondate & "')" seems to be giving me the runtime error: The conversion of a varchar data type to a smalldatetime data type resulted in an out-of-range value In the code, strSql is a String object and transactiondate is a Date object. In the SQL database however, transactiondate is a smalldatetime object. I've tried changing the smalldatetime to a datetime (in the database) and I've tried transactiondate.toString() but with no success. How can this be fixed? Note: I know about the dangers of inline SQL. I am looking for a quick fix solution here and not a discussion about SQL injection.

    Read the article

  • Trouble with LINQ databind to GridView and RowDataBound

    - by Michael
    Greetings all, I am working on redesigning my personal Web site using VS 2008 and have chosen to use LINQ to create by data-access layer. Part of my site will be a little app to help manage my budget better. My first LINQ query does successfully execute and display in a GridView, but when I try to use a RowDataBound event to work with the results and refine them a bit, I get the error: The type or namespace name 'var' could not be found (are you missing a using directive or an assembly reference?) This interesting part is, if I just try to put in a var s = "s"; anywhere else in the same file, I get the same error too. If I go to other files in the web project, var s = "s"; compiles fine. Here is the LINQ Query call: public static IQueryable pubGetRecentTransactions(int param_accountid) { clsDataContext db; db = new clsDataContext(); var query = from d in db.tblMoneyTransactions join p in db.tblMoneyTransactions on d.iParentTransID equals p.iTransID into dp from p in dp.DefaultIfEmpty() where d.iAccountID == param_accountid orderby d.dtTransDate descending, d.iTransID ascending select new { d.iTransID, d.dtTransDate, sTransDesc = p != null ? p.sTransDesc : d.sTransDesc, d.sTransMemo, d.mTransAmt, d.iCheckNum, d.iParentTransID, d.iReconciled, d.bIsTransfer }; return query; } protected void Page_Load(object sender, EventArgs e) { if (!this.IsPostBack) { this.prvLoadData(); } } internal void prvLoadData() { prvCtlGridTransactions.DataSource = clsMoneyTransactions.pubGetRecentTransactions(2); prvCtlGridTransactions.DataBind(); } protected void prvCtlGridTransactions_RowDataBound(object sender, GridViewRowEventArgs e) { if (e.Row.RowType == DataControlRowType.DataRow) { var datarow = e.Row.DataItem; var s = "s"; e.Row.Cells[0].Text = datarow.dtTransDate.ToShortDateString(); e.Row.Cells[1].Text = datarow.sTransDesc; e.Row.Cells[2].Text = datarow.mTransAmt.ToString("c"); e.Row.Cells[3].Text = datarow.iReconciled.ToString(); }//end if }//end RowDataBound My googling to date hasn't found a good answer, so I turn it over to this trusted community. I appreciate your time in assisting me.

    Read the article

  • How does one inject variables into page templates from a custom Drupal module?

    - by Michael T. Smith
    We've created a custom module for organizing and publishing our newsletter content. The issue I'm running into now -- and I'm new to theming and Drupal module development, so it could just be a knowledge issue as opposed to a Drupal issue -- is how to get each newsletter themed. At this point the URL structure of our newsletter will be: /newsletters/{newsletter-name}/{edition-name}/{issue-date} which means that we can create template files in our theme using filenames like page-newsletters-{newsletter-name}-{edition-name}.tpl.php, which is great. The one issue I'm running into is that all of the content comes through in the $content variable of the theme. I'd like to have it come through as different variables (so that I can, inside the theme, place certain content in certain areas.) Is there a proper way for doing this?

    Read the article

  • error: gnome.h: No such file or directory

    - by michael
    I would like to resolve this 'error: gnome.h: No such file or directory ' on ubuntu. I get this error: /bin/sh: gnome-config: not found In file included from TestMDI.cpp:18: ../../../../dist/include/system_wrappers/gnome.h:3:24: error: gnome.h: No such file or directory From this: http://ubuntuforums.org/showthread.php?t=295105 I tried: $ sudo apt-get install libgnomeui-dev Reading package lists... Done Building dependency tree Reading state information... Done libgnomeui-dev is already the newest version. 0 upgraded, 0 newly installed, 0 to remove and 21 not upgraded. But that still does not resolve my problem. Any idea how to fix it?

    Read the article

  • .NET Sockets Buffer Overflow No Error

    - by Michael Covelli
    I have one thread that is receiving data over a socket like this: while (sock.Connected) { // Receive Data (Block if no data) recvn = sock.Receive(recvb, 0, rlen, SocketFlags.None, out serr); if (recvn <= 0 || sock == null || !sock.Connected) { OnError("Error In Receive, recvn <= 0 || sock == null || !sock.Connected"); return; } else if (serr != SocketError.Success) { OnError("Error In Receive, serr = " + serr); return; } // Copy Data Into Tokenizer tknz.Read(recvb, recvn); // Parse Data while (tknz.MoveToNext()) { try { ParseMessageAndRaiseEvents(tknz.Buffer(), tknz.Length); } catch (System.Exception ex) { string BadMessage = ByteArrayToStringClean(tknz.Buffer(), tknz.Length); string msg = string.Format("Exception in MDWrapper Parsing Message, Ex = {0}, Msg = {1}", ex.Message, BadMessage); OnError(msg); } } } And I kept seeing occasional errors in my parsing function indicating that the message wasn't valid. At first, I thought that my tokenizer class was broken. But after logging all the incoming bytes to the tokenizer, it turns out that the raw bytes in recvb weren't a valid message. I didn't think that corrupted data like this was possible with a tcp data stream. I figured it had to be some type of buffer overflow so I set sock.ReceiveBufferSize = 1024 * 1024 * 8; and the parsing error never, ever occurs in testing (it happens often enough to replicate if I don't change the ReceiveBufferSize). But my question is: why wasn't I seeing an exception or an error state or something if the socket's internal buffer was overflowing before I changed this buffer size?

    Read the article

  • How to set up 3rd party developer portal

    - by Michael
    I am developing a web service and depend on 3rd party developers to write client applications for it. I need to set a developer portal, a web site where existing and potential developers would find documentation html pages doc files for download libraries downloads wiki forums support ticketing system. There should be a public part and a part protected by login. I want only logged in users to submit tickets, for example. I don't want to host it. I would prefer a generic design based on a sensible template, where I can add minimal customization, such as logo. I don't want to add code to get any of the above functionality. I will do all that if necessary, but I'd hope there would be an online service to do thing like that. What services would you guys recommend?

    Read the article

  • What's a good way of building up a String where you specific start and end locations?

    - by Michael Campbell
    (java 1.5) I have a need to build up a String, in pieces. I'm given a set of (sub)strings, each with a start and end point of where they belong in the final string. Was wondering if there were some canonical way of doing this. This isn't homework, and I can use any licensable OSS, such as jakarta commons-lang StringUtils etc. My company has a solution using a CharBuffer, and I'm content to leave it as is (and add some unit tests, of which there are none (?!)) but the code is fairly hideous and I would like something easier to read. As I said this isn't homework, and I don't need a complete solution, just some pointers to libraries or java classes that might give me some insight. The String.Format didn't seem QUITE right... I would have to honor inputs too long and too short, etc. Substrings would be overlaid in the order they appear (in case of overlap). As an example of input, I might have something like: String:start:end FO:0:3 (string shorter than field) BAR:4:5 (String larger than field) BLEH:5:9 (String overlays previous field) I'd want to end up with FO BBLEH 01234567890

    Read the article

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