Kimball's Q&A profile
SQL Server USE MULTIPLE ROLES IN CUBE BROWSING
Hi, I'm developing a cube browsing aspx application using the OWC11 controls, both Pivot and Chart, associated with Analysis Service on SQL2005. I did quite a bunch of that but now I'm having some troubles to solve the following problem. Using the SSAS IDE, I defined two Roles in a Cube and I defined a filtering function on the dimension in both of them. When I choose each one of them and I check the functionality they works because I can see what I expect to see, only one result from a dimension where the filter is acting in the role definition . But, if I choose both of the roles, and I can do that because it let me select the two checkbox instead of all (having more than two Roles), the filter doesn't work anymore, showing a ...Show All
SQL Server Using Sum with a SubQuery to Sum each Distinct Value
I'm having some trouble getting the results I need. I am trying to Sum a Value based upon the result set of a subquery. What I'm getting is a Sum for all of the rows. For Example: Select Sum(OwnerName2.CELL_TABLE.HOURS) FROM OwnerName2.CELL_TABLE WHERE EXISTS (SELECT DISTINCT OwnerName2.LINE_TABLE.YEAR, OwnerName2.LINE_TABLE.PERIOD, OwnerName2.LINE_TABLE.CHARGE, OwnerName2.CELL_TABLE.HOURS FROM OwnerName2.LINE_TABLE, OwnerName2.CELL_TABLE, dbo.temp_table WHERE OwnerName2.LINE_TABLE.EMPL_ID = OwnerName2.CELL_TABLE.EMPL_ID AND OwnerName2.LINE_TABLE.SCHEDULE = OwnerName2.CELL_TABLE.SCHEDULE AND OwnerName2.LINE_TABLE.YEAR = OwnerName2.CELL_TABLE.YEAR AND OwnerName2.LINE_TABLE.PERIOD = OwnerName2.CELL_TABLE.PERIOD AND O ...Show All
Visual C++ Screencapture and pixel problem
hello! I have a problem to take pixel from captured window.. Here is my code example: Color Screen_class::takeScreenshot(HWND window) { HDC hDC; HDC hMemDC; hDC = GetWindowDC(window); hMemDC = CreateCompatibleDC(hDC); RECT r; GetWindowRect(window,&r); SIZE size; size.cx = r.right-r.left; size.cy = r.bottom-r.top; hBitmap = ::CreateCompatibleBitmap(hDC, size.cx, size.cy); if (hBitmap) { HBITMAP hOld = (HBITMAP) SelectObject(hMemDC, hBitmap); BitBlt(hMemDC, 0, 0, size.cx, size.cy, hDC, 0, 0, SRCCOPY); Color col; col = Image::FromHbitmap(hBitmap)->GetPixel(160,485); SelectObject(hMemDC, hOld); DeleteDC(hMemDC); ReleaseDC(NULL, hDC); DeleteObject(window); DeleteObject(hBitmap); ...Show All
.NET Development Limit the row number result in a .Select() method.
Hi! I have a DataTable with 180.000 rows, i need get the rows one by one with a less ID and TTL = 0, i use this: DataRow[] NextValue = dt.Select("TTL = 0", "ID") ; Debug.Print("Arr" + NextValue.Length.ToString()); if (NextValue.Length > 0) { // Do stuff with NextValue[0] .... } The problem is, that the firsts times ... the NextValue array could have 179.999 DataRows... and next 179.998 ... etc.. etc... Do this query spend a lot of time, i need reduce the time but ... how Some idea Regards. Fill the datatable with only the records you need at that particular moment. dt.Fill(myTable, myCustomParameter, myCustomParameter) ...Show All
Visual Studio Express Editions Learning Resources Zip File
I was going throught videos on learning Visual Basic 2005 Express Edition and in lesson 2 (I just started) he says that you can download a learning resources .zip file from the location where this video was. I can't find the file anyone know where it is We are talking about tool strips and adding images tot he button and the zip file supposidly has the images. Thanks, Rick When I down load what I'm running the video off the web. I did download the visual basic 2005 express edition and installed that, but I did a search for rss and there were 2 folders but they only had 3 files. Not the gif files I was looking for Thanks, I know this is a trivial question/issue so THANKS for taking the time to hel ...Show All
Game Technologies: DirectX, XNA, XACT, etc. Weapons
Hey everyone, I've got a problem with my weapon in my game. I have them shooting a ray relative to the player and if the other actor is in front of the player they'll get hit and die. No problem. But now I want to implement a better aiming system. I have my camera class working the way I want, but now I want to know if anyone can explain and help me shoot a ray from the camera position through a 2D pixel on the screen (where the aiming reticle is on). Here's a screenshot. http://ravenousgames.com/public/msdn/streetdreams_problem_aim.jpg Picking is indeed the right method, which involves unprojecting your screen coords into the viewport, and testing if a mesh was hit (probably with the same test you are usi ...Show All
.NET Development Can @@Identity Be Used With MDB Databases?
I want to insert a record into a table and then retrieve the value of the Idx field, which is the table's AutoNumber Primary Key. I am using C#, an OleDbConnection, and an MS Access 2002 database. I did a lot of reading and it seemed that using "@@Identity" was the best approach. Here's my code: sqlText = "INSERT INTO tblMain ..." // Abbreviated here on MSDN RunSQLNonQuery(DBconn, sqlText); // Insert new record (works fine) string sqlText = "SELECT @@Identity"; long newIdx = DBTools.RunSQLNonQueryScalar(DBconn, sqlText); public static long RunSQLNonQueryScalar(OleDbConnection dbConn, string cmdText) { long retVal = -1; dbConn.Open(); OleDbCommand cmd = new OleDbCommand(cmdText, dbConn); object ...Show All
Visual Studio GAX and templates in VS
Hi! I tried to enable in Guidance Package Manager one of the template options Template->Data Access-> Web Service Factory(Data Access) and then I got an error: System.TypeLoadException: Microsoft.Practices.RecipeFramework.Library.Actions.CreateUnboundReferenceAction, Microsoft.Practices.RecipeFramework.Library ---> System.IO.FileNotFoundException: Couldn't find assembly Microsoft.Practices.RecipeFramework.Library. at Microsoft.Practices.Common.Services.TypeResolutionService.GetAssembly(AssemblyName assemblyName, Boolean throwOnError) at Microsoft.Practices.Common.Services.TypeResolutionService.GetType(String typeName, Boolean throwOnError, Boolean ignoreCase) --- End of inner exception stack trace --- at Microsoft.Practi ...Show All
Smart Device Development setting Bluetooth FTP profile to an already established socket.
Hi All, Ok. Here's the background to my problem. I have to create an application that will connect to a device using the Bluetooth File Transfer Profile over a socket connection. I have used the following code to do this. My problem is that once I have the socket I do not know how to establish the GUUID and bind the socket to the FTP profile. Truly I highly appreciate and thank any help in advance! int main(int argc, char* argv[]) { WORD wVersionRequested = 0x202; WSADATA m_data; If (0 == ::WSAStartup(wVersionRequested, &m_data)) {   ...Show All
Windows Forms question of DoubleClick on ListView, need help!!
Hi, does anyone know the codes on how to create a double click event for ListView to delete/remove the item that i select from ListView control quite easy,just take this piece of code: private void listView1_DoubleClick( object sender, EventArgs e) { this .listView1.Items.Remove( this .listView1.SelectedItems[0]); } Moreover, do a loop through all items in listView1.SelectedItems to remove all the selected item if you want to achieve this. Regards, Ye ...Show All
.NET Development MSMQ remote transactional queues
VC2005, C#. When trying to use a remote (private) transactional queue for sending, it fails when querying the queue for 'Transactional' with 'Specified Format Name is invalid etc.' It works with a public queue, using the PUBLIC format name. I can find no documentation to say that private remote queues do not support transactions (for sending). Any ideas re-posted from c# general Thanks Tony ...Show All
Internet Explorer Development Security issue on using XMLHTTPRequest
Hi, I am facing security issue in using XMLHTTPRequest in the Javascript of the .NET web page. Some of the browser having the security issue executing this, the error message is "Permission denied". i have created an xmlHTTP object and using as mentioned below xmlHttp.open("GET", "http://Server1/WebApp/Matter_Types.aspx",true) xmlHttp.send(null); I am getting error on executing the send method. Is there anything need to be set on the browser security settings. Thanks, Hi, make shore that the server specified in the URL of the open() function is the same as the server the webpage is running on. Otherwise there will be a security error... Hope this helps, Thomas ...Show All
Visual C# Switching Between .NET 2.0 and .NET 1.1
I have installed VS.NET 2005 and VS.NET 2003 in same machine, i need a steps how to switch from 1.1 to 2.0 whenever i want to create web application in 2003 , and vice versa in VS.2005 Regards seems i mis-explain what i want, actually i have VS.2005 and VS.2003 installed on same machine, some times some proof of concepts for WEB APPLICATION needed to be on 2005 and some on 2003 , what i need when i need to create a web application in 2003 is to make IIS communicating with .NET 1.1 and same for 2.0. Regards ...Show All
SQL Server Handling flat files that do not exist
Hello, I have a package that contains 22 data flow tasks, one for each flat file that I need to process and import. I decided against making each import a seperate package because I am loading the package in an external application and calling it from there. Now, everything works beautifully when all my text files are exported from a datasource beyond my control. I have an application that processes a series of files encoded using EBCDIC and I am not always gauranteed that all the flat files will be exported. (There may have not been any data for the day.) I am looking for suggestions on how to handle files that do not exist. I have tried making a package level error handler (Script task) that checks the error code ("System:: ...Show All
Visual Studio 2008 (Pre-release) BindingList<T>, works via remoting but not via WCF
I have a custom list EntityCollection<T> which inherits from BindingList<T> When I try and get one of these custom collections through WCF I get an error similar to that below; >> Type 'System.DelegateSerializationHolder+DelegateEntry' >> with data contract name is not expected. Add any types not >> known statically to the list of known types - for example, by using >> the KnownTypeAttribute attribute or by adding them to the >> list of known types passed to >> DataContractSerializer. Im not using a generated proxy, I am using the same assembly both on the client and the server (this is a closed system) this seems to work fine via .NET remoting - how can ...Show All
