|
I'm working on getting some IPC between a VC++ application and a console C# 2.0 application. I'm having a problem on the C# side of things, though: I'm subclassing a System.Windows.Forms.Form, so I can override and listen to WndProc. The form isn't meant to be visible, I just need some way of receiving these WndProc messages. However, when I try and start up the form class, I get a ComponentModel.Win32Exception: Error creating window handle. code:
I must be missing something simple to setup the form, right? EDIT: Okay, I realized what I was doing wrong: If you override WndProc, you need to make sure you call base.WndProc(ref message); at the end Sabotaged fucked around with this message at 22:12 on Aug 31, 2007 |
# ? Aug 31, 2007 10:37 |
|
|
# ? Jun 10, 2024 18:09 |
|
nullfunction posted:Smart Devices and creating .NET applications I believe that a WiFi capable Smart Phone will automatically switch between GPRS and WiFi when it's in an area that has WiFi. You don't need to manage it from within your application. It's like in Windows when it would automatically dial your Internet connection when it needed to connect. The .NET Compact Framework has a SQL Client built in. If you're going to use it over a public network, you'll want to encrypt it and use certificates for authentication. If you want to go the HTTP route, there's no sense in using AJAX. Just build a web service. SQL Server 2005 has that built in or you can do it from your web server very easily with ASP.NET. For ruggedized Windows Mobile Barcode readers, I like Symbol. They're tough as hell and widely supported. I have a client who still has PALM III-based scanners in use and they're run by teenagers. If that doesn't speak to their reliability... (*NOTE*) If you do set up a WiFi in your warehouse, contract with someone to set it up correctly who KNOWS wireless systems. They can come in, scope your environment, measure for interference and place the Access Points and Antennas accordingly to minimize cross-talk, interference, and god knows what else. Also, in the WiFi setup for the scanners enable CAM on the power setting feature. Just trust me on this. It will save you months of headache trying to figure out why pings are high and packets get dropped.
|
# ? Sep 2, 2007 20:57 |
|
What's the difference between using data types like int vs Int, or string vs String? which one is preferred?
|
# ? Sep 4, 2007 03:08 |
|
There is no difference AFAIK. The lower-case option is just some compiler magic catering to the java types. Personally, I use int and string because that was the way I learned and that seems to be the standard.
|
# ? Sep 4, 2007 03:11 |
|
wwb posted:There is no difference AFAIK Yep, there isn't. string = System.String, int = System.Int32, long = System.Int64, etc. It's just syntactic sugar to save you from having to refer to those common types by a more complex name.
|
# ? Sep 4, 2007 03:51 |
|
Has anyone ever used Reporting Services embedded in an application? Basically, I want to store the RDL in the database itself. This way changes made will be available to users instantly. (Column Type XML) I want the app to load the RDL (I assume this would be accomplished with a Stream), prompt for anything it needs to prompt for, then throw the report up on the screen. I don't want to do this with Crystal Reports (even though I have the Pro version of VS2005) because I don't want to have to push out the CR Runtime to the users as well. I'm pretty sure this can be done, I'm just not too sure where to start. In fact, when I click Add Item I don't see anything relating to reports that isn't Crystal. Anyone have any experience on this they can share?
|
# ? Sep 4, 2007 06:59 |
|
I am new to this databinding stuff. Is there a way to use databinding with a DataGridView, but customize the columns which are displayed? For instance I know if you code:
For instance if Foo has a number of public functions int foox() and int fooy(), and I want a column which produces foox() + fooy(), how is this done? Or am I completely thinking about things the wrong way? I have been searching for DataGridView tutorials for making custom column types with datasources but all I find is articles for overriding the onpaint method for existing columns, not defining new columns.
|
# ? Sep 4, 2007 12:57 |
|
@Wizzle: You don't see reports because the reports live in SQL server, not in your application. What you want to do is add a Reporting Services project to your solution. Then you use the reportviewer control to pull them into your UI. Another option would be to serve up reports using SSRS web services, but that is probably overkill here. @adante Yes, that sort of thing is possible. First, you want to set AutoGenerateColumns to false to take care of the extraneous data issue. Insofar as creating derived columns, that requires using TemplateColumns and databinding syntax. For example: code:
|
# ? Sep 4, 2007 16:05 |
|
adante posted:I am new to this databinding stuff. Is there a way to use databinding with a DataGridView, but customize the columns which are displayed? wwb posted:@adante code:
|
# ? Sep 4, 2007 16:50 |
|
wwb posted:@Wizzle: I don't have the Business Intelligence Projects. I guess I need to install SQL2005 Developer Edition on my workstation.
|
# ? Sep 4, 2007 17:44 |
|
^^^If you don't want Sql 2005 running on your workstation, you can just choose to install the client tools and the Business Intelligence Studio (which is really Visual Studio w/ Reports and analysis projects).quote:Alternatively, if you have control over the Foo class and you aren't using it for anything except the DataGridView you can use the [Browsable(false)] attribute on any properties you wish to hide from the DataGridView and then also create a read only property like Technically valid, but really a bad design option in general. UI should not drive classes if at all possible, and databinding is easy enough once you get the hang of it.
|
# ? Sep 4, 2007 20:04 |
|
I feel like I have a lack of understanding of something fairly basic when asking this question, but.... Background: Currently I am using a VB6 program to read in multiple text files and create an Access Database (or I guess maybe a data file is a better description? a .MDB file nontheless). Then I have a seperate program that accesses this database, and create a seperate .MDB file on its own. Goal: Migrate to vb.net 2005 and get rid of all COM referrences. Problem: The only way to programatically "create" a .MDB file in .NET is to include the ADODB COM referrence via the interop somethingorother. I am not stuck on .MDB, but I cannot use something that tries to access data from a "database server". It basically must be a stand-alone datafile of some time, but I would like for it to keep the structure of some time of database (access, sql, oracle, xml, I really don't care, as long as it doesn't require any other software to "create"). What are my options here? I've been leaning towards making a sql database (I believe this would be a .mdk file?) but most everything I come accross points me towards needing a sql server. I started thinking about XML, but I'd need to make sure that the file wasn't accessible to the user, only to the program (i.e. I don't want the user to be able to open it and edit it from outside my program). Though I know people can open Access DB's, my .MDB file is pw protected (which I suppose could be cracked if they really wanted to). Anyways, I feel like I'm rambling now. If anyone can help point me in the right direction, I'd be greatfull.
|
# ? Sep 5, 2007 06:39 |
|
wwb posted:... thanks. I had a quick google for TemplateColumns and all the results seem to be ASP.NET centric. I should have specified that this is for the datagridview in visual studio winforms (maybe it is all part some microsoft grand unified presentation scheme, but if not, do equivalences exist for non asp .net? I haven't yet had a chance to look at this in more detail but I will when I get home.
|
# ? Sep 5, 2007 08:24 |
|
Xycoth posted:I feel like I have a lack of understanding of something fairly basic when asking this question, but.... 2. I'd still be more inclined to use a SQL server for the data. Using SQL Express (which is included with VS.NET), you can specify a file-based connection. In my app, I'm using SQL express to house the data, but coding it using the enterprise library so it's pretty to point it to a different data source if needed.
|
# ? Sep 5, 2007 13:07 |
|
The real trick about having database agnostic code is writing database agnostic SQL. Which is very tricky for non-trivial applications. Anyhow, I think your best bet here is to use Sql 2005 express combined with the file-type databases. You could just embed the create script in your app and call that when you need to create the DB. Users could still get to the data directly, but Sql 2005 does not ship with GUI tools so that is unlikely. @adante Sorry, that was very ASP.NET specific. I really know gently caress all about WinForms beyond the basics, so someone else will have to field your question here.
|
# ? Sep 5, 2007 13:39 |
|
I'm in the middle of a C# ASP.NET 2.0 project at work here. I'm pretty new to it. My problem is that I'm supposed to move all of the C# code out of my .aspx file and into a .aspx.cs file that gets included with the Src="" directive. I had written it more like PHP with the code embedded in the HTML because that's what I'm used to. Anyway, I got all of it moved except some literal print statements that I used to pass arrays to Javascript. Basically I have a string in my C# file that needs to be printed at a specific place inside the HTML file that includes it. Is there an ASP tag that translates to <script>, another way to do it, or am I screwed?
|
# ? Sep 5, 2007 15:21 |
|
uncle vernon posted:I'm in the middle of a C# ASP.NET 2.0 project at work here. I'm pretty new to it. You can either do <%= MethodInYourCodeBehindThatReturnsTheStringOfJS() %> in your aspx, or output the whole js block via ClientScript.RegisterClientScriptBlock in your code behind.
|
# ? Sep 5, 2007 15:32 |
|
havelock posted:You can either do <%= MethodInYourCodeBehindThatReturnsTheStringOfJS() %> in your aspx, or output the whole js block via ClientScript.RegisterClientScriptBlock in your code behind. Regardless of which method you use, I think it's a good idea to put the bulk of your javascript code in a separate .js file, and only put function calls in your aspx or aspx.cs files. Most examples on the internet seem to put all the javascript code in strings in the .cs file, which I think is a hilariously bad idea.
|
# ? Sep 5, 2007 16:27 |
|
^^^Yes, for the actual core of the javascript functionality. But I think outputting local stuff, like say an array mapping some values to the ClientID property, makes sense. Insofar as outputting a javascript array to a page, I would just use a repeater to generate the code if it makes sense to actually have it in the page.
|
# ? Sep 5, 2007 17:45 |
|
I'm trying to make a multi-select capable datagrid inside an UpdatePanel. I've got something like this:code:
Anyone know how I could go about it? Edit: nevermind. I was calling databind() during page.load. Doh Dromio fucked around with this message at 19:43 on Sep 5, 2007 |
# ? Sep 5, 2007 19:36 |
|
If you do:code:
However if you do: code:
|
# ? Sep 6, 2007 09:32 |
|
dwazegek posted:It compiles just fine, why? InternalClass is still unaccessible, so registering an eventhandler should be impossible. Or is it possible to register a method that takes (e.g.) an EventArgs as parameter instead of an InternalClass? This behavior is a bug in VS2005 and earlier. In VS2008, you can't expose a type that's less accessible than the delegate via its parameters. biznatchio fucked around with this message at 15:18 on Sep 6, 2007 |
# ? Sep 6, 2007 15:02 |
|
I don't even know if this is possible, I might be googling the wrong terms. Is it possible to get the information in combo boxes/list boxes/text fields in a different application? Also, can you enumerate through the controls in another application? I know you can get the selected text from a text box using SendMessage, so I suspect it might be possible, but the examples/documentation for SendMessage aren't that great. Basically I need to get the information present on some POS software so my app can process it.
|
# ? Sep 6, 2007 17:54 |
|
Edit: I've figured it out for now. Question was stupid. ahawks fucked around with this message at 21:14 on Sep 10, 2007 |
# ? Sep 10, 2007 18:33 |
|
I'm developing a simple (very simple) html form layout tool for a winforms app*. Is there a decent library that makes it easy to drag little graphical widgets around and manipulate them a little (resize, right click menus, etc)? I just want the user to be able to drag controls around on the screen to place them where they want. I thought about just making some winform controls draggable, but that seems pretty cheesy. *I know there are a few free/cheap html designer controls, but everyone I've seen is just a wrapper for mshtml, which I think is A) overkill B) too much trouble to get the output I want, which is basically the x/y coordinates of each control. If there's something else free/cheap you know of, that would be great too.
|
# ? Sep 11, 2007 00:58 |
|
This is a .net non-technical question, but requires the help of .net developers. We're developing an application that requires the following on the developer's workstations: Web Service Software Factory (3) Smart Client Software Factory (3) Enterprise Library 3.1 (3) Composite UI Application Block (3) Guidance Automation Toolkit (2) Guidance Automation Extensions (2) Visual Studio 2005 Extensions for .NET 3.0 (1) Our legal department is very, very keen on knowing if the software is: 1) only used internally in the development process 2)Automatically generates code for us (somewhat questionable, as studio itself will generate some code just for a blank project) 3) Results in shipping someone else's intellectual property (i.e. bundling their DLL with our system)[/list] Can anyone with some experience in the tools above? I've asked our developers, and the responses haven't been ... great. I've included my guesses above.
|
# ? Sep 11, 2007 18:58 |
|
I'm working on an ASP.NET site and I'm having issues with the way ASP is resolving URLs. The site is at http://company.com/Default.aspx (which works) but under SSL its: https://hostingname.com/company.com/Default.aspx This causes all my Response.Redirects to blow up, ASP forgets the company.com directory and goes to hostingname.com/Default.aspx. Is there a way to change the way ResolveURL() works to force the company.com back in? Or maybe there is a config setting to tell it its actual application path?
|
# ? Sep 11, 2007 21:40 |
|
quote:Visual Studio 2005 Extensions for .NET 3.0 (1) quote:Enterprise Library 3.1 (3)
|
# ? Sep 11, 2007 22:30 |
|
Is it possible to start and write C# code within a VB.NET windows form solution and have it work seamlessly with the existing VB code? I'm starting to move over to C# and have a large VB project that I'd like to gradually convert to a C# project. I've tried Google and is looks like it's possible with ASP.net.
|
# ? Sep 12, 2007 09:54 |
|
Frank Butcher posted:Is it possible to start and write C# code within a VB.NET windows form solution and have it work seamlessly with the existing VB code? I'm starting to move over to C# and have a large VB project that I'd like to gradually convert to a C# project. I've tried Google and is looks like it's possible with ASP.net. You may have both VB.NET and C# projects in the same solution (output to different assemblies). As far as I know, you cannot mix languages within a single assembly.
|
# ? Sep 12, 2007 13:41 |
|
Did I stump the panel?
cadmium fucked around with this message at 18:06 on Sep 12, 2007 |
# ? Sep 12, 2007 16:16 |
|
Frank Butcher posted:Is it possible to start and write C# code within a VB.NET windows form solution and have it work seamlessly with the existing VB code? I'm starting to move over to C# and have a large VB project that I'd like to gradually convert to a C# project. I've tried Google and is looks like it's possible with ASP.net. I don't think that's possible, but you can use Roeder's Reflector for .NET, build your vb application, and disassemble it into c#. You'll lose your commenting, but the code should work. These two together are awesome http://www.aisto.com/roeder/dotnet/ http://www.denisbauer.com/NETTools/FileDisassembler.aspx I have a question too. I have 3 buttons bound like: code:
Shayla fucked around with this message at 16:46 on Sep 12, 2007 |
# ? Sep 12, 2007 16:43 |
|
Dromio posted:You may have both VB.NET and C# projects in the same solution (output to different assemblies). As far as I know, you cannot mix languages within a single assembly. Edit: I was right. Here is an example with Mono's compiler, but it uses the exact same arguments as Microsoft's C# compiler csc. http://www.gotmono.com/docs/tools/mbascomp-cmdlo.html waffle iron fucked around with this message at 16:51 on Sep 12, 2007 |
# ? Sep 12, 2007 16:49 |
|
waffle iron posted:I thought it is possible to build an unlinked module and then compile it into an assembly with other source files. code:
code:
|
# ? Sep 12, 2007 20:37 |
|
I'm developing a WPF application to manage a collegiate debate tournament (Swiss style) as a personal development project. I need to persist: Schools, Debaters, Teams, Judges, Rooms, Rounds, and Matches. To clarify terms, the style dictates two teams in every match, each of which consists of two debaters. Every debater comes from a different school, although hybrid teams (teams that consist of debaters from two different schools) are allowed. I'm wondering whether it would down the road be easier for me to keep all of this data in a series of custom objects with, say, a Tournament class that manages a series of collections, or as a separate SQL (compact) database. I would like to be able to do some dynamic databinding to visual components (as debaters, teams, and schools will have to be manually entered for each tournament), and as an "it would be nice" feature, to allow multiple simultaneous data entry of tournament results within a college network. I would not like to require tournament directors to set up a separate server to host the database, as TD's are not likely to be very tech savvy. Is this reasonably possible to achieve using SQL compact or should I just use objects and collections, or is there a third option that might better meet my needs? I'm not sure what other information might be useful, so let me know if this question is unanswerable with this level of detail.
|
# ? Sep 12, 2007 22:38 |
|
Tomatoedipus posted:Debate tracker app thingy What do you mean by a "separate" server? Since apparently you want to make this a WPF app, I'm assuming that you will have a few computers somewhere. You could easily use one of those as a database server. You don't need an extra computer just to host your database. As for which option, I go for option 3. Custom objects and databases are not mutually exclusive things. Use a database as persistent storage and use custom objects where you should in your program to help keep related data together. Also, is there some reason besides not "setting up a separate server" that you are picking on compact sql? That is designed for mobile apps and for instances when you need a database and you have very limited resources. What you probably really want is express edition. Installing it is pretty much as simple as clicking next a few times and entering a password for the admin account. I wouldn't worry to much about using WPF for your interface until you get your back end thought out a bit more. Fake edit: Too lazy to edit my above paragraph. When you say custom objects, do your really mean things like structures and classes or are you talking about something like xml files? XML would work for data storage but in my opinion using a real database would be easier.
|
# ? Sep 13, 2007 01:54 |
|
Hi guys, I'll start off by apologising for being a bit new to the .Net family. I'm currently If anyone's familiar with Access Grid, it's comprised of a Python front end application which uses two Tcl/Tk applications (VIC and RAT) for videoconferencing. I have no problems using SendMessage operations to talk with the Python app, but these methods have no effect on the Tcl/Tk applications. Here's a snippet of what I'm doing (it's just a proof of concept at the mo and I've hard coded the window ID for testing. I would enumerate the child windows to find it normally): code:
code:
Are there any methods for communicating with Tcl applications from VB.NET other than using user32? I'm a Java person normally and I've had all of about 3 days on learning VB far, sorry if this seems obvious. I can do it the cheap way by moving the mouse cursor and creating a mouse click, but I really want to do it elegantly without having to bring windows to the front or take the mouse control away from a user.
|
# ? Sep 13, 2007 10:18 |
|
Is it possible to use variable names in the Table adapter configuration window to build the data source without extra crap? I've got other datasets that I've built during generation without a problem, but I'm trying to make life as easy as possible for report generation. Here's what I'm after. Example code:
|
# ? Sep 13, 2007 16:41 |
|
http://forums.somethingawful.com/showthread.php?s=&action=showpost&postid=331764464 Does anyone have any ideas about this question? Basically, the idea is "chaining" Container, or Container.DataItem, or whatever, so that nested databound controls can inspect the DataItem that their parent is currently binding to. It's not a show-stopper but it's preventing me from doing neat UI things that I want to do. Thanks in advance for any ideas anyone has.
|
# ? Sep 13, 2007 21:27 |
|
|
# ? Jun 10, 2024 18:09 |
|
This should work:code:
|
# ? Sep 13, 2007 22:33 |