slugonamission's Q&A profile
Smart Device Development SQL mobile 2005
Hi There, I'm currently writing an application for a windows mobile 5 device which will store data in sql mobile 2005. I would like to know which would be the most efficient way of writing the following example to work with the above. (up until now all the code i have written has been in vb6 and connecting to an access database) Set db = DBEngine.OpenDatabase("location\database.mdb") ' strSQL = "SELECT * FROM Floats WHERE AgentName = '" & lblAgentName.Caption & "' AND Status = 0 " ' Set rs3 = db.OpenRecordset(strSQL) If rs3.RecordCount > 0 Then rs3.MoveLast lngRecordCount3 = rs3.RecordCount rs3.MoveFirst Else lngRecordCount3 = 0 End If ' If lngRecordCoun ...Show All
.NET Development Compound Document Properties
Is there any way to access Compound Document Properties using C# I'm specifically trying to retrieve properties from PDF files. Thanks in advance. Derek. You will need to use a third party library to do what you need for the format is not owned by Mircosoft. See this post where someone was discussing outputing pdf files. Check out Adobe's web site for other tools in working with PDFs. ...Show All
.NET Development .NET encourages poor coding?
The more I look at .NET error handling, and how to deal with it, the more frustrating it gets. Take this class for example. It has a single boolean property. You have to know on which side of the call an error will be raised… by the caller or the callee… well here’s a prime example. Say you have to read data from somewhere like a text file and you cannot ensure the format of the data is proper. Well, you cannot depend on a property to check that data for you if you strongly type the property. Read the orange comment to see what I mean, and please let me know how you deal with this situation since to me it appears to require horrible program design. Public Class ...Show All
Visual C++ cannot convert from '__const_Char_ptr' to 'wchar_t __gc *'
Hello! Error 1 error C2440: 'return' : cannot convert from '__const_Char_ptr' to 'wchar_t __gc *' When I try to compile this code I receive the above error message. wchar_t __gc * GetFileMappingName( int processId = GetCurrentProcessId(), int threadId = GetCurrentThreadId()) { String* fileMappingName = String::Format(S "wfavhook_{0}_{1}_filemap" , __box (processId), __box (threadId)); return PtrToStringChars(fileMappingName); } Hi Here is my origional problem: Error 10 error C2664: 'PtrToStringChars' : cannot convert parameter 1 from 'System: bject ^' to '__const_String_handle' C:\Programfiler\Microsoft Visual Studio 8\VC\atlmfc\include\cstri ...Show All
Visual Basic PrintPreview awkward to use?
It might be just me, but doesn't PrintPreview work rather backwards I'm used to constructing a report from the top down: Whenever the line count goes over say 60, I do a formfeed which prints the page, set the line count back to 0, and carry on like that. That seems very natural. But with PrintPreview, I must have a single routine for handling the printing of any page. What if I don't know what will be on page 6 until I've printed pages 1 to 5, which happens often What might be on page 6 with one report run might be a different page with another run, depending on the content. What if pages may have various different formats I can't do a 'switch' on the page number because I may not know on which physical page some parts of ...Show All
.NET Development Get list of tables in ACCESS using VB.Net app
I am using Visual Studio 2005 (VB.NET). My app. is using an Access db in the background. Once connected to the DB, I want to display a list of all the tables in a combobox on one of the forms. How do I go about doing this Thanks Nihal, thanks your code seems to be working well, except for the error message below: "More restrictions were provided than the requested schema ('Tables') supports." If I take the restrictions out, the code works, but all tables are displayed, which I don't want. Any idea how I would fix it ...Show All
Visual Studio Team System Validation Rule: Find Text - Regular Expression
I need to verify that a transaction id and confirmation id were actually returned. Both values appear on the page but I do not know what the exact values will be. The transaction id should be six digits long and the confirmation id should be 16 characters long (0-9,A-Z,a-z). The challenge is that I am trying to use a web test and I want to avoid writing code if at all possible. The Find Text Validation Rule has an option to set "Use Regular Expression" to True, but I am having trouble finding examples using this. Can anyone give me examples of how to use Find Text to search for transaction id = 123456 or confirmation id = 12345abcd67ef89gh when the exact ids are not known Thanks in advance... ...Show All
Game Technologies: DirectX, XNA, XACT, etc. Intermittent Audio Problem
Hi, I've been developping a game recently and I'm having major trouble sith sound. I am pretty much using the code from the XNA Framework audio sample. So I can't imagine what's wrong with that code. The problem is that I'm getting intermittent clips being played. Some don't even play at all when I call the Sound.Play method, some play but stop before the end on the clip, sometimes they play fully. This does not happen rarely, I'd say this is about 50% of the time and more often on longer clips. The only one sound I've got that seems to play correctly is a clip that I am looping (alarm sound), which is of lower quality 8KHz vs 44.1KHz for the other ones. So that's basically it, I'm using XACT V2.0. I tried following the instructions ...Show All
Visual Studio Team System R
Maybe a Bug in Visual Studio 2005 SP 1 !!! I'm able to reproduce on different machines with Windows XP and Vista with (Vista Update for VS SP1) Problem: 1. Start Solution and run Tests - works fine as desired. 2. Rerun Tests - VS freezes and processorload becomes 50% Additional Information: We have a Solution with ~ 95 Projects and the tests are grouped together in ordered tests. Is someone out there who has similar problems or can help Greets, Helmut Hi David, Thank you for your reply. Unfortunately I can't even reproduce the problem on my home computer (identical software config as the one at work). Unlike the freeze problems reported by Jeff, mine are predictable and occur only when I execute a b ...Show All
SQL Server Should SQL 2005 be a dedicated server without other apps installed?
I'm planning an SQL 2005 deployment and would like to know if an SQL server should be kept as dedicated as possible. Should apps that access SQL be kept on other servers What are the do's and don't's along these lines The plan here is to install everything that accesses SQL on the same server with the database, but this seems like a bad move to me. Am I right Thanks! Gregg SQL Server should always have a predictable level of system resources. Response from hard drives, memory, processor speed, bus speed, etc should always be the same. Otherwise, your compiled query plans are useless. So no additional apps, no funky compression engines, no diskkeeper, no disk replication, no shared SAN luns. You can, h ...Show All
Game Technologies: DirectX, XNA, XACT, etc. first impressions
Install seemed to work ok. - I chose complete when it finished it didn't launch either a readme or vs launched vs just got the same/normal ide I always get. File -> New project, brings up the usual screen, with 3 new items for creating xna games. Double clicking on space wars starter kit item, eventually brings up a large project, which when run doesn't appear to work - tried pressing a/b/x nothing ever happens - machine/grphx may not be upto job. tried looking for examples, nothing I assume ther're on my hard disk somewhere Now need to find tutorial on how to use this thing You can use either one actually, there's no difference. The one I bought for my PC is an XBox360 contro ...Show All
.NET Development problems importing data from XML
Hello, Sorry not having written a more detail Subject for this topic, but i dont know how to explain it in so few words! I'm developing a pocket pc application, which is using a database also used on the desktop computer, and both apps exchange data using export and import functionalities. I've done this once with no problems, but this time there is a different person developing the desktop application, and i'm having problems reading the xml from the exported file. Taking a quick look at xml file i'm trying to read, i can only see one cause for this problem: Instead of specifying the various elements like <table> <row1> <atr1> <atr2> <row2> etc.... its is ...Show All
SQL Server EXECUTE AS , fatal exception
Hi There If i add a new sysadmin login and that login is a user in a DB. If i execute the command EXECUTE AS 'LoginName': I get the following error: SqlDumpExceptionHandler: Process 57 generated fatal exception c0000005 EXCEPTION_ACCESS_VIOLATION. SQL Server is terminating this process WHats up with this If my dbo for this db is linked to a sysadmin login i have no problem with EXECUTE as 'dbo'. WHy do i get fatal errors when trying to execute as a a login name that is sysadmin On the net all referencing to the fatal error have nothing to do with EXECUTE AS Thanx Hi Raul As luck would have it i am having trouble re-creating the problem. I am running MS WInder Server 2003 ...Show All
SharePoint Products and Technologies Help with InfoPath Contact Selector Control & Active Directory...
I have successfully configured a contact selector control on my InfoPath form and am able to get the following information for a selected person. DisplayName AccountId AccountType My question what if I need additional fields to be returned from this lookup. Does this control return additional fields from Active Directory like phone number, title, etc. or do I have to write additional code to get more AD properties Att... Thanks for the reply. I am trying to add the additional AD fields onto my InfoPath form not on my SharePoint document library as additional fields to be displayed. ...Show All
Game Technologies: DirectX, XNA, XACT, etc. Spacewar slow build
I just tried to build the Spacewar starter kit and it took quite some time to build (5-10min). It spent most of its time building the content. Now, I could perfectly understand the slow build time since there's a lot of content to process (50MB output), but what bugs me, is that my computer becomes nearly unusable during the build. It takes about half a minute to alt-tab from C# to an explorer window while the build is busy. The thing is, I have a dual core processor (which was only at 50% during build) and neither the HDD nor the RAM were actually stressed during the build, so I would expect it to be responsive. For example, when I use the windows calculator to calculate 80000!, the taskmanager shows the same situation as when build ...Show All
