visual-studio-2008

Using libcurl on windows, in my c++ project, with visual studio, does not work because string get corrupted

风格不统一 提交于 2020-01-16 17:36:20
问题 As explained in the title, I am trying to use the libcurl C API to submit simple http query. I am using windows as an OS, C++ as a language, Visual Studio 2008 as an IDE. My code is quiet simple: I initialize curl: CURLcode init = curl_global_init(CURL_GLOBAL_ALL); I initialize my handle: CURL* handle = curl_easy_init(); I set the url: CRULcode set_url = curl_easy_setopt(handle, CURLOPT_URL, "http://www.example.com") I submit my request: CURLcode submit = curl_easy_perform(handle); As a

How do I access a cell in Excel Interop when using filtered ranges?

廉价感情. 提交于 2020-01-16 14:54:45
问题 I originally had a code segment that iterated through rows of an Excel spreadsheet using the UsedRange as such: range = ws.UsedRange; for (int row = 3; row <= range.Rows.Count; row++) { Object nObj = ((Excel.Range)ws.Cells[row, "N"]).Text; } But I needed to only get the rows that remained after I applied a filter so (after viewing How can I get the Range of filtered rows using Excel Interop?) I changed the code as such: range = ws.UsedRange.SpecialCells(Excel.XlCellType.xlCellTypeVisible,

How do I access a cell in Excel Interop when using filtered ranges?

帅比萌擦擦* 提交于 2020-01-16 14:53:10
问题 I originally had a code segment that iterated through rows of an Excel spreadsheet using the UsedRange as such: range = ws.UsedRange; for (int row = 3; row <= range.Rows.Count; row++) { Object nObj = ((Excel.Range)ws.Cells[row, "N"]).Text; } But I needed to only get the rows that remained after I applied a filter so (after viewing How can I get the Range of filtered rows using Excel Interop?) I changed the code as such: range = ws.UsedRange.SpecialCells(Excel.XlCellType.xlCellTypeVisible,

How to programatically set menu shortcut keys in .NET?

强颜欢笑 提交于 2020-01-16 13:13:10
问题 In my application, I have a "recent files" drop down menu. It will contain anywhere between 0 and 9 files to load. I want to set shortcut keys on these menu items such that Ctrl+1 loads the first file, Ctrl+2 loads the second, etc... I understand that I need to set the ShortcutKeys property of the ToolStripMenuItem but I am looking for a way to do this inside of a loop. I have the files in an array that I read them from when initially building the menu. I'd like to be able to do something

Copy to output directory issue with .inf file

若如初见. 提交于 2020-01-16 08:40:12
问题 Apologies if dup, I did try searching several times and found nothing like it... I have a number of 'config' files that my application edits. Really it is just a gui for editing these files as they have a special format. Anyway, everytime I put a new group of files in visual studio, and select "Copy to Output directory" to "Copy always", this works fine. Except all other files will have "Build Action" set to "None" except the .inf file which will always have "Build Action" set to "Resource"..

Access Class library from MVC project?

情到浓时终转凉″ 提交于 2020-01-15 12:15:53
问题 I have a Class Library project and MVC project in the one solution. My class library has the namespace MyStuff.Classes My MVC project has the namespace MyStuff.Web I can't seem to access my class library from the mvc project or vice versa directly or with a using directive?? Whats the best way to use namespaces in this instances? and in general? any hints tips welcome. Thanks 回答1: You need to add a reference to your Class project If you right click on references in your MVC project hit the

Crystal Reports different versions on pc and on server

末鹿安然 提交于 2020-01-15 11:09:04
问题 I'm building a winforms application using a crystalreportviewer control (version 10.5.3700.0). Application works fine (it loads report from resources and displays it fine). But when I put my application on server (other pc) that has runtime in versions 12.0.1100.0 and 12.0.2000.0. My application isn't showing at all, even errors don't show :/ I was trying to use dll's in version 12.0.1100.0 in my application by removing references and adding new, but this generates errors. I can't install

Don't publish particular folder in ASP.NET

▼魔方 西西 提交于 2020-01-15 05:46:27
问题 Is it possible to exclude a folder in a web project from being published? We've got some documentation and scripts that included in a particular project folder, and are added to the project, but when I do a VS publish, I don't want them to go up to the production server. I know they shouldn't be in the project, but I thought I'd find a workaround before I try to convince the owner to modify the way he's doing things. 回答1: This doesn't answer your question, exactly, but my feeling is that

How do I strong name a C++ assembly in VS2008?

眉间皱痕 提交于 2020-01-15 01:24:09
问题 I have no experience developing C++ on Windows, but I am a C# developer. I have a wrapper around some native DLLs that is written in C++. (A LGPL project)). I was to use this from a strong named assembly. How do I set up the strong naming of the C++ assembly? There is no 'Signing' properties tab available as there is in C# projects. I imagine that I need to edit the vcproj file and put a reference to the key file, something like /KEYFILE:"sgKey.snk" that I found at this site: http://www

where is the threads window in vs2008

我怕爱的太早我们不能终老 提交于 2020-01-14 14:02:02
问题 I'm trying to find the threads window in VS 2008 described here and here, but I can't find it anywhere. I've looked in View and don't see anything remotely like this. This seems very useful. Thanks for any help EDIT: yes i am debugging EDIT: thanks, I found it! 回答1: You are debugging, right? It doesn't show up otherwise. Also, it may be docked along with some other window, so check that it's not embedded in a tab somewhere. And the menu is Debug->Windows->Threads. It lists a shortcut of Ctrl