GROTH's Q&A profile
Windows Forms Quick Brush Question
I am making a drawing program. I have made it so I can change the color of the tool when drawing. I've decided to try to add a transparent type draw, and I've been told I have to use NULL_BRUSH. I'm not sure exactly how to get this brush though. I have tried: brush = GetStockObject(NULL_BRUSH) but that ends up with a compile error. So I think I am missing something. Some of the other ones that I have tried are: brush = CreateBrushIndirect(GetStockObject(NULL_BRUSH)); (compile error) brush = CreateBrushIndirect(NULL_BRUSH); (compile error) I suspect this is an easy question and being new makes things harder then they have to be. Thanks. If you're working in native code, GetStockObject( ...Show All
.NET Development Best Practices question.
I want to use typed datasets in the projects that I am working on, however ( and this may just be a symptom of my .Net ignorance ), in order to create the typed dataset I need to specify database and connection info at design time. This can be an issue since I am developing against a test database, so as not to disturb production. What I have done to get around this is to change the connection information at run time, based on values that I am storing in the registry. Are there any better ideas out there for this kind of a scenario That is a good scenerio as long as the schema for your test db matches the production db...and yes that way all you have to do is select the proper connection string at runtime( ...Show All
SQL Server SELECT Query duplicating rows
Hi, I have a small problem that i cant seem to get my head around regarding the results of the following SELECT query. The result set contains two rows for every Employee - one for Annual (EntitlementID = 1) and one for Long (EntitlementID = 2) Where have i gone wrong Thanks in advance. --Tables: Employee (EmployeeID, EmployeeCode) -- EmpEntitlementValue (EntitlementID, EmployeeID, Balance) -- Entitlement -- Department -- Position -- Contact (FName, LName USE Employees go SELECT EmployeeCode As 'Employee Number', FName + ' ' + LName As 'Employee Name', Department .[Name] As 'Department', Position .[Name] As 'Position', CAST(DAY(DateStarted) ...Show All
Visual C# How to Split text file into multiple text files?
Hi experts I'm looking for help to split a large text file into multiple text files based on size of the File. Can anybody help me in this Thanks for the reply Sean Hederman Suppose if I've text(.txt) file more than 500KB , I want to split it into muliple files. Ex : temp.txt is file with 1209KB size Now the result should be temp1.txt temp2.txt temp3.txt ...Show All
Visual C++ first steps
Hi Im just starting out to learn VC++, I have previous expericience of c, Java and SmallTalk. I have the VC++ 2005 compiler and the book 'MicrosoftR Visual C++R .NET Step by Step--Version 2003, the first exercise is 'Hello World' to give you the idea...which compiles and runs ok, My question is will I run into lots of problems working through this book...or maybe translating the code will aid my learning I realise its not the best way to start off, but my budget wont stretch to buying another book, Some feedback would be appreciated Are you guys all sitting at the same table or what lol I first started programming BASIC on the Amstrad 464(integrated audio tape loader/saver)... then ...Show All
Game Technologies: DirectX, XNA, XACT, etc. Missing dxut.h header file in June 2006 SDK
Hi, i recently tried to run the DXUT samples of the SDK documentation but did not find the dxut.h header file in the include directory. Anyone a suggestion where this header file is located And i still need help on creating a simple box. Thanks very much. ...Show All
Windows Forms WebBrowser - setting value for "type=file"
I'm using the VS 2005 control System.Windows.Forms.WebBrowser. I want to be able to set the value for a text area that indicates a file to be uploaded, where type=file HTMLInputElementClass iElement = (HTMLInputElementClass)element.DomElement; if (iElement.type.ToLower() == "file") { if (iElement.name == name) { iElement.value = text; Application.DoEvents(); ok = true; break; } } iElement.value is still null after the assignment. Help. I've seen some posts saying that this is done on purpose as a security issue. They don't want people to be able to ...Show All
SQL Server Role Playing dimensions Currency Conversion issue
Hi, Having issues with Currency Conversion in SSAS when using role playing dimensions of Time. When the Dim Usage in the cube is set for the role playing dimensions, i.e. defining the relation between the Exchange rate fact and the role playing time dims. the base $ measures (no calculations) return a null value. The generated conversion script in Calculations has leaves(Time), not the leaves for each role playing dim. With leaves for each along with leaves(time), the base measures return null. Regards ...Show All
Visual C++ compiler switches
I am working on a new project that has a lot of regular DLLs. I wanted to find out when and where a particular DLL got loaded. Is there a compiler swicth that would list that in output window If not, where should I set my breakpoint to iterate the flow Is there an easy way of doing it BTW, It got loaded in the very beginning. My guess is that there are some global variables. But I don't know which one since there are too many classes in this particular DLL. Thanks The error is "Error loading type library/DLL". I guess it is still a managed DLL even though regasm created an entry in the registry. My question is that how do I use it in C++ program after I regasm the C# Dll into COM ...Show All
SharePoint Products and Technologies BDC Business Data Related List web parts pass the wrong entity
I am having a problem with the Business Data Catalog Business Data Related List web parts. I have the following generalized BDC schema: Entity A in Business Data List Entity B in Business Data Related List connected to entity A list via A to B relationship Entity C in Business Data Related List connected to entity B list via B to C relationship When selecting for a Business Data Related List with entity B to provide data to Business Data Related List with entity C, it passes the wrong entity--the one from the source Business Data List (entity A), not the entity exposed by the first Business Data Related List (with entity B). The same error results that I was getting after applying beta 2 TR (this worked in beta 2): 01/31/2007 09: ...Show All
Visual Basic VB Express debug adds missing file to directory when starting???
This is in reference to my previous post concerning changing Access databases. It seems VB Express in the debug mode does not use the Access database files defined in the code. Instead it loads a copy of the database from somewhere unknown and writes that copy to the directory where the code specifies the database should be, whether it is there or not. If it is there it replaces it. Here's the code: dbpath = "C:\XData\PPPos.mdb" DB1 = DAODBEngine_definst.OpenDatabase(dbpath) rs1 = DB1.OpenRecordset( "ModeTable" , DAO.RecordsetTypeEnum.dbOpenDynaset) I have been working with computers since 1960 and I have never seen anything like this where the code is ignored and the compiler goes and gets a copy of ne ...Show All
SQL Server Dynamic Security in SSAS 2005
I am trying to create dynamic security and was hoping to use a named query to link the fact table to a dimension that contains Active Directory users and companies - a user can have access to multiple companies. The problem is that I cannot find out how to get the username of the current user. Anyone have any ideas thanks in advance. thanks for the feedback - however, I am relatively new to Analysis Services (and 2005) - and cannot see where this would be created. Are you saying that this is a calculated Dimension (or measure ) Many thanks ...Show All
SQL Server Group age by a parameter and find out the value corresponding to that.
Hi guys... My goal is to change the given stored procedure so that I can find out the different age gorup according to users parameter and find out sumof these values for that group: s.TVmins, s.Notional$, COUNT(*) AS Qty, SUM(s.TVmins) AS TVMinsAmt, SUM(s.Notional$) AS NotionalAmt For that I am planning to put another parameter @count for the group interval and I need to group accordingly. So my answer should look like: if the user give the @count value as 10: the result should: age group TVMins Notional 1-9 1560 125632( the sum of that particluar group) 10-19 -- -- --- 91-100 -- --- I have a field DOB( Date of birth) , I have to extract age from that field first and then g ...Show All
Visual C++ Still having problems with printing out INT64 integers
Still having problems with printing out INT64 integers I am still having problems with this code. This prints out a number, but it's not exactly what I want. I need to print out an INT64 number that is in sync all the way through. For example: The hex: FF D8 FF E1 1E 63 45 78 is the first line of the file test.jpg. I would like to display its integer (unsigned) value: 18435766416983672184 But what it does it prints out is the number for hex 78 45 63 1E E1 FF D8 FF, which is 8666442042236197119. I thought this would be ok, but later when I want to do more stuff to the program it won't work. There has to be a simple way of reading in 64 bits of data and then output the decimal value into a .txt file. Please can someo ...Show All
Visual J# Slowly losing my hair
Three weeks of spare time and counting. It's so simple, and I just can't do it. If I translate an applet to a J# object, how then do I access it from an HTML page < SCRIPT LANGUAGE = 'javascript' > function access(a,b){document.testApplet.testMethod(a,b)} </ SCRIPT > It works perfectly with an applet called testApplet, using a method called testMethod. What *is* the corresponding code when the applet is translated into an object, and loaded through use of an <OBJECT> tag Don't give me references. I've looked at them all. None of them applies exactly, and when I alter the code, things don't work. I've actually purchased the full version of Visual Studio, to see if I get any information beyond what I get from the Express ...Show All
