w3hello.com logo
Home PHP C# C++ Android Java Javascript Python IOS SQL HTML Categories
How to convert the Excel 2007 Macro: "ActiveChart.ChartType = xlPie" into C++/VB 2005 Code?
xlPie is a numeric constant, not a string. Get its value by typing debug.print xlPie in the VBA immediate window. Define it in your C++ as (I think) a long type. Then pass it. Don't convert it to a BSTR. (Also, don't forget to free your BSTRs using ::SysFreeString or you'll get memory leaks).

Categories : C++

How to create tfs projects from a code side
I don't believe this is possible from the API; however, you can create a command line script. See this article. Obviously there's nothing stopping you creating and running this script in code, as it's effectively based on an XML file.

Categories : Tfs

share code between projects with maven
I have the same situation: two webapps with common domain objects, but all my entities are located in "domain" module. Webapps are like "front-end clients" for "domain" back-end module. If you want to locate webapp-specific entities in appropriate projects try to delete "em" field from GenericDaoImpl and pass it as parameter to all methods.

Categories : Spring

How to import other projects to use in my code ( Color picker )
Tip 1: If you only use the ColorPickerPreference, make the import then: src.net.margaritov.preference.colorpicker.ColorPickerPreference. And did you save everything and never forgot something? The error is weird, because you imported them so they should work.

Categories : Java

Code Organization with Multiple Related Projects
Consider the duplicate code. In particular, consider the number of functions and their length. If both plugins share only a couple formatting methods, it's not such a big deal to duplicate that code in order to keep the plugins self-contained. If the duplicate code is getting pretty hefty, start thinking about doing one of the following: Merge the plugins into a single plugin. Only do this if the two plugins fit into the same problem space. Take a good hard look at the plugins. There's a chance that what made them seem separate before was illusory and the fundamental behaviors are closely related. Extract the duplicate code into a third plugin which is a dependency of each of the plugins that share the code. Only do this if the duplicate code is related and make sense as a plugin.

Categories : PHP

Code refactoring for integration four projects to one project
In generic class, convert your json parameters into HashMap. Implement Factory Design pattern such that Factory class will return appropriate filter based on whether required key is present in HashMap or not. Use the returned filter to process your result and return JSON response.

Categories : Java

How to point a single code base to multiple SVN projects
Subversion does not support copying files between repositories at all. Maintaining 3 repositories for the same project will be a descent into madness. Nor do you want to have "multiple codebases" - it's all one codebase, you just have to have a clear process to move your changes from dev, to qa, to release. For that, you want a combination of tags & branches. With regular merges of changes. The exact implementation will come down to how you manage the development of your application, and that may have to change some. Because you will have to un-learn everything that you've learned in working with VSS, because VSS...well, it sucks. With the following assumptions: All developers work in a common codebase during active development You have a method by which to say "OK, what we have he

Categories : Svn

asp.net application with multiple projects cannot load type of page code
It sounds like you may have just broken a reference in the main project. Whenever you remove a project that is referenced by project, it automatically removes it as a dependency wherever it's used.

Categories : C#

ASP.NET MVC 4 app and WinForms app in same solution - setting breakpoints and stepping through code in both projects
You can select multiple start-up projects from the solution's properties (set the Action to: Start with debugging) in order to use the debugger in both projects. As Ashley Medway pointed out, if the MVC applications starts the winforms app, the debugger won't handle the winforms app.

Categories : Asp Net Mvc

Is it possible to share library projects between projects when using Android Studio and gradle?
Couldn't you use git with submodules? e.g. In your .gitmodules file, you may add this: [submodule "volley"] path = volley url = https://path/to/volley/repository You can set the url to Volley's official repository, or to your own in-house version of volley. Other projects can be setup the same way and point to the same volley repository. I think this way, other users can call git clone and all the dependent projects will be downloaded within the main project folder and they don't have to worry about downloading the library projects separately. For Volley though, I would just compile it into a JAR file and stick it into the /libs folder of the main project. That is, if you don't need to modify its source. [Update] For library projects that you don't need to modify its source, you ca

Categories : Android

What's the industry standard way to organize Visual Studio projects and code for .NET Cross-platform development
This is a well known programming problem, if solution exists they usually require some work and even more when a project is not designed from scratch to be portable. As you correctly pointed out, pre processed statement will quickly become an overhead and a real pain to maintain and expand over time. Yet it is not easy to answer this question directly since the solution you are seeking might be highly dependent of your implementation. Generally speaking I would advise you to make extensive use of well known design pattern such as Abstract Factory, Bridge, Facade, etc. As an exmaple, start by identifying every single piece of code which is platform dependent, define API interfaces responsible to handle these specificities in your core project and implement them into dedicated projects - u

Categories : Dotnet

How to exclude Projects with names ending in ".Test" from my code coverage analysis in VS2012 Unit Tests
There is a connection with the period issue as it was mentioned here. If you change the exclude section to this <ModulePath>.*tests.dll</ModulePath> <ModulePath>.*Tests.dll</ModulePath> or this <ModulePath>.*.tests..*</ModulePath> <ModulePath>.*.Tests..*</ModulePath> it'll work

Categories : Visual Studio

How to edit code when debugging a 64 bit
Edit + Continue in VS2012 is only supported for 32-bit code, as it has been since VS2005. This will be changing soon, E+C for 64-bit managed code will be supported in VS2013. Currently in preview.

Categories : Debugging

How to add/edit project resources from within the code in C#?
Project -> Properties -> Resources -> open the resx file -> select images. There you can see the images in your project. You can add new images by dragging them into that area. This code will store the chosen images and load the last stored image at startup. You may have to make it Observable or do something to make all the PictureBoxes update their image. public class DefaultPicture { private static string settings = "picture.settings"; private System.Drawing.Bitmap image = new Bitmap(settings); public Bitmap Image { get { return this.image; } set { this.image = value; this.image.Save(settings); } } }

Categories : C#

Inflate layout and edit it in code
You are inflating the layout with root set to null, so your layout variable (returned by the inflate method) holds the root of the inflated layout (in this case, your RelativeLayout). I didnt see the code where you are attaching the inflated layout to your activity's content (maybe the code you posted is not complete?). Given this, your findViewById calls should return nulls. Moreover, as far as I know and understand, unless the view is attached to a view that is already somewhere in the activity, the LayoutParams are not going to be correct as no dimensions are set (even in case they are invoked on a view that isn't null, obviously).

Categories : Android

Eclipse: Edit code parser
Place mouse pointer over highlighted code, then press F2 to have focus in popup suggestion window. At left corner of this window exists icon, click on such icon opens problematic item. By setting/removing checkbox 'Text As', editor with highlighted code will be change view as well. Usually they are all accessible through Window->Preferences->General->Editors->-Text Editors-> Annotations. I used it on kepler CDT.

Categories : Eclipse

How come my local website is not using the last edit of my JavaScript code?
Have you tried holding shift while clicking refresh, this will prevent it from loading from cache. Happens occasionally. If this is happening in both browsers, you must not be saving your new code to the same file, browsers don't share cache's.

Categories : Javascript

Postgresql extension: edit the source code (pgRouting, for example)
After you've edited the source you need to rebuild it (typically "make") and then reinstall it (typically "make install"). For most extensions you don't need to restart postgres, but you do have to disconnect your session and start a new one. If you have made any changes to SQL or PL/SQL or similar objects in the extension, you should either give it a new version number and upgrade it, or drop and recreate it.

Categories : Postgresql

Android Google Navigations app: can I edit the source code?
Is there open-source code for it that I could modify and recompile? No, sorry, Google Maps is not open source, which includes its Google Navigation component.

Categories : Java

Edit button shape in code (Stroke, Gradient)
You cannot edit the resource file from code. So if you want to change the drawable from code then don't use a fixed drawable xml. Use GradientDrawable instead to create the drawable from code.

Categories : Android

Edit excel sheet manually while running a code
You could try to use a userform instead of an messagebox. As far as i know there is no simple way to create a messagebox, where you can edit the sheet in background. If i need to edit the sheet while having an active macro, i'm using a userform. (they are not that hard insert in vba, try it!) You have to start the userform with the vbmodeless. Should look like this: (i'm not 100% sure, because i've no vba ide herere to test, but i thinks it's something like this) Sub ShowMyCreatedUserform() myUserform.Show vbModeless End Sub If this userform is open, your code stops, but you can edit the sheets. After pressing a button (for example "ok"-button) you can continue the macro.

Categories : Excel

Allow a user to edit a php code and submit the results securely
if I get you right, then eval function is what you need (http://php.net/manual/en/function.eval.php) Evaluates the given code as PHP. Although it is very dangerous as a user can execute a destructive code or output some private data. <? if(isset($_POST['submit']) { eval($_POST['code']); } else { ?> <form method="POST"> <textarea name="code"></textarea> <input type="submit" value="Submit"></form> </form> <? }

Categories : PHP

Can user edit invalidate code before current token?
Member function bodies defined inline in the class will be conceptually (and actually, in the compilers I know) parsed at the end of the class and can thus access members of the class declared after them.

Categories : C++

Readium Android SDK - Does anyone edit the code of epub3-Library?
Readium on Android receives a file path to the openBook call. You basically have two options: Decrypt the encrypted ePub to a temporary file and use that temporary file's path as the path to the openBook method. Remove the temporary file when the viewer exits. Alter the Readium library to be able to receive the ePub archive as a data buffer. You can then do the decryption in memory. Doing this has some problems. One is that an ePub might be too large for a mobile device to hold in memory (if there are lots of images or video embedded within it). The other being that you would have to alter Readium to add a method for opening an in-memory book and expose that back to Java via the NDK.

Categories : Android

Multiple apps from one code base - multiple projects or targets in Xcode?
I think you have at least 3 options here: Separate projects. It is more difficult to share code across projects, but with Xcode workspaces this is quite feasible. If you have a lot of customization for each project, this might make sense. Same project, more targets. This is the usual way this is done. It is very easy because you have a very neat overview of what files go into which target. If you have around, say, a dozen or so targets, it is really quite easy to handle. Separate git branches. I have worked with this in the past. The differences between the apps (Info.plist, configuration files, data files) are just swapped in the corresponding git branch. This is practical if you have a lot of data and don't need to have all of it available at all times. However, the complexity of gi

Categories : IOS

jqGrid - Detecting backend HTTP response code on edit
The second parameter of the reloadTable function contains a result object that has the following objects: readyState responseText status statusText The response code is contained within status as is also shown from the firebug output below:

Categories : Javascript

Python source code: Which python projects are core and which are libraries?
The readme.txt inside the PCbuild directory explains what each project is for (although it may not be complete). This, together with some basic knowledge about what Python comes with, should give you enough information to figure out whatever distinction you want. As for the underscores: All modules (except possibly for some special cases that don't have any actual C code in them) depend on the DLL. The "rule" is that projects that build modules are named for the module they build; user-visible modules don't start with an underscore, modules that are wrapped by a user-visible Python module do… But some of the oldest modules don't follow that rule exactly, and there are some exceptions in PCbuild itself—e.g., sqlite3.vcproj builds the _sqlite3 module, not sqlite3. So, you can't rely on

Categories : Python

How to upload and access spreadsheet files from Google Drive in Dr.Edit sample code?
For Google Docs (Spreadsheet, Presentation, etc) file formats, you cannot get downloadUrl which is the way Dr.Edit accesses file. Instead, in same file metadata resource where you can get downloadUrl, you can get exportLinks, which exports spreadsheet to known file formats such as Microsoft Excel or csv. You can work with those known file format and upload it again to Google Spreadsheet by setting convert=true when uploading file.

Categories : IOS

How to save, delete, edit data to PHP / Mysql with inline edit in CKEditorsaving?
Below is a example on how to pass data from the Ckeditor. By pressing the button you can save the content via ajax. <div id="editable" contenteditable="true"> <h1>Inline Editing in Action!</h1> <p>The div element that contains this text is now editable. </div> <button type='button' id='save'><span>Save</span></button> <script> $(document).ready(function (e) { $("#save").click(function (e) { var data = CKEDITOR.instances.editable.getData(); var options = { url: "/path/to/php", type: "post", data: { "editor" : encodeUriComponent(data) }, success: function (e) { //code to do when success } };

Categories : PHP

Click event for edit/delete button when tableview is in edit mode
If you are using your custom button as a subview then you can addTarget to your button like this: [button addTarget:self action:@selector(yourMethod) forControlEvents:UIControlEventTouchUpInside]; Please be specific or show some screenshots. So that I can figure it out.

Categories : Iphone

how to configure or edit wp-filebase plugin edit to show author of files
yes we can configure the plugin without touching the code. However, following link was very helpful to me. documentation for the templates

Categories : PHP

How to show data in tabular format in asp.net mvc & perform edit operation without providing edit button in each row?
You are looking for an "inline edit" then I believe. You are probably going to need some Javascript to get a nice effect for this. I like JQuery, so I'd use JEditable. I'd suggest you have a read of this article: http://www.codeproject.com/Articles/265211/Using-JEditable-plugin-as-ASP-NET-MVC3-jQuery-inli Scroll to the section called "Integration with DataTables"

Categories : Asp Net Mvc

Custom sharepoint 2010 xslt list - Edit item via javascript - Data not refreshed after edit
If it's a modal window, then you have to monitor when the modal is closed (for example with http://sharepoint.stackexchange.com/questions/65513/detect-modal-dialog-close-with-jquery) then you can reload your main page with window.location.reload() or window.location.href=window.location.href

Categories : Javascript

Is there any way to Edit row of bound fields in gridview with custom edit button?
Everything is possible ;-) But you have to decide how you want the edit to be done. If you're not using the built in functionality to enable editing of the field contents, you need some other kind of editing. One option would be to use a separate details view beneath/besides the table that can be edited. Place the detail view in an update panel to avoid reloading the entire page. You would also need to place the grid view in an update panel to be able to reload it's content smoothly once the edited changes are saved.

Categories : C#

JQuery td inline edit -> after enter go to next edit cell?
you may try to bind a keydown event to the edit box input. On key down, it should fire the click event of the next cell. $('#editbox').keydown(function(event){ if (event.which == 13)$(this).parent().parent().next().children(':first').trigger('click'); }); hope this is helpful

Categories : PHP

javascript error: ReferenceError: edit is not defined edit(this);
A script can be inline or external, it cannot be both. The presence of the src attribute causes the text node children of the script node to be ignored. If you want inline and external scripts, use two script elements. <script src="serialize-0.2.min.js"></script> <script> function edit(element){ // etc

Categories : Javascript

My current testcases are not working with new selenium 2.34.0 and php (edit added code and log file from selenium)
I'm not sure which library you're using for php-webdriver. From your code, I'm guessing Either Adam Goucher / Element-34 php-webdriver or an older version of the Facebook php-webdriver. It looks like there have been some changes in session handling for the WebDriver binaries, and those changes aren't reflected in the element-34 webdriver bindings yet. Where I'm using those, I've been able to patch the bindings just enough to get things working (This pull request looks like it's correcting the problem: https://github.com/Element-34/php-webdriver/pull/44). If you're using the Facebook bindings, they've recently been completely rewritten. Unfortunately, it probably means your tests are all broken until you update. The new facebook version works with WebDriver 2.34 for me here. See the

Categories : PHP

Setting value to a input field using Jquery val not working.I have commented out code setting value in edit() function
check this fiddle js fiddle here is the code that i have modified. function edit(id){ $("#firstName").val(data[id].firstName); $("#lastName").val(data[id].lastName); $("#city").val(data[id].city); $("#state").val(data[id].state); $("#pin").val(data[id].pin); }

Categories : Javascript

I want to select the entire row for edit by click on edit
Your $(this) will hold the only element on which, you have clicked. So, $(this).addClass('ajax'); $(this).html('<input id="editbox" size="'+ $(this).text().length+'" value="' + $(this).text() + '" type="text">'); this code will add textbox to only that element.You need to take parent of clicked element first, like var p = $(this).parentNode; and then take all child nodes for 'p' element.And use for loop for all child elements and add above code for each single element, not for $(this).

Categories : PHP

Asp.net MVC 4 getJson work for create but not for edit. Seems to have an odd url in edit
The following line $.getJSON("ProfessionTypeList", will generate the URL of the form http://domain.com/Controller/ActionName/ProfessionTypeList i.e. it will append ProfessionTypeList at the end of the URL. You should try to make explicit URL will complete path. In CSHTML file, you can do so by using @Url.Action("ProfessionTypeList")

Categories : Javascript



© Copyright 2017 w3hello.com Publishing Limited. All rights reserved.