Pete_M's Q&A profile
SQL Server What's wrong with SQL Server E-Leanring?
Hi, all, Thank you very much for your kind attention. Think I should put this post here for help as I cant find any other forums appropriate for this problem tho. Thanks a lot for that. My question is: what is wrong with the E-Learning for the Microsoft online E-learning courses (the one I am looking at is new features of Microsoft SQL Server 2005 Analysis Services) As I have tried so many times to launch the E-learning tools, but it always just showed me the content while not any tool to start the learning. I have tried ages for that. Could anyone here give me any advices and guidance for that (I actually just used it yesterday, it was fine, but not now I have tried both 'launch e-learning' and 'view e-learning details' , bo ...Show All
Visual C# Check file signature?
Is it possible to compare a file's signature to a string Thank you. Evan Mulawski Hi Evan. I'm answering to your post asuming a couple of this... since I'm still not sure of what you want. Most files start with a header. For example, a bmp starts with the BITMAPFILEHEADER. Within this header usually , the first bites are a signature . For example, the BITMAPFILEHEADER start with BM. Anyhow, I assume you will not know what your file contains... so you can't assume that it starts with text. Therefor the answer to your question is " no ". What you can do is convert the string to binary and compare it with the file's first bytes. This is: public bool FileStartsWith ( string signature, string file ...Show All
Visual C# Method Parameter Naming Style
Sometimes I have a method that initializes a class by passing in a few values. In this situation, I generally want to set the value of a private member from the parameter value passed in. (In other words, I don't want to "Set" the property and trigger code in the Set method.) So my code would look like this (** this obviously won't work.. hence, my question... *) public class MyClass{ int x; int y; public void Init( int x, int y ) { x = x; y = y; } I have read many suggestions on naming styles, but so far I haven't seen an example of the "right" way to handle this. I've played with different prefixes and other tricks to rename the method parameter, and of course any of them work , but I ...Show All
.NET Development MySql- Help me
I'm with a error in my mysql, I want to fill my database by a WinForms. An unhandled exception of type 'MySql.Data.MySqlClient.MySqlException' occurred in mysql.data.dll Additional information: #42000Voce tem um erro de sintaxe no seu SQL proximo a 'page) VALUES (''', '''', '''', '''', '''', '''', '''', '''', '''', '''', '''')' na linha 1 My code is here down. using System; using MySql.Data.MySqlClient; using System.Data; namespace Rodrigues__Projeto { /// <summary> /// Summary description for Acesso. /// </summary> class SQL_methods { public static MySqlConnection Conexao_mysql() { MySqlConnection conn = new MySqlConnection(); try { ...Show All
Visual Studio Express Editions Math.Sqrt Problem
Im having a problem with this code: float quad1( float a, float b, float c) { float d; float e; d=Math.Sqrt(b*b-4*a*c); e=(-b+d)/(2*a); return e; } And here is the error: c:\documents and settings\zach williamson\my documents\visual studio 2005\projects\workplace\workplace\workplace.cpp(42) : error C2065: 'Math' : undeclared identifier c:\documents and settings\zach williamson\my documents\visual studio 2005\projects\workplace\workplace\workplace.cpp(42) : error C2228: left of '.Sqrt' must have class/struct/union type is ''unknown-type'' Am I not including a library If you're building a managed program, use Math::Sqrt(). If you're building a c ...Show All
Game Technologies: DirectX, XNA, XACT, etc. z-buffer sorting?
In experimenting with drawing multiple objects on the screen, I've found an interesting situation. I the picture below, the larger craft is closer to the camera, the smaller craft away from the camera. But if you look at it, the larger craft cuts into the shape of the smaller one, even though it is far enough away not to do that. In my drawing code, I know I'm drawing my smaller craft after the first, so there is clearly some kind of z-buffer problem. What I don't know is how to decide which object to draw first reglardless of camera positioning, or even if XNA has any help with that. Any ideas http://www.spellflight.com/images/zbuffer.PNG It's simple, just set these two render states before you draw y ...Show All
SQL Server how to skip applying the current remaining logs?
Hi, My replication application need to be able to skip the from-last-stop remaining logs (that means to skip the logs generated from the last stop time of my replication application), how can i realize it thanks. thanks for reply!:) "my replication application" is an application written using SQL Replication ActiveX Controls, used to replicate transcations from a source SQL server to another ODBC destination, because of a special requirement, this replication app should stop everyday, and when it starts next day, it should skip all the transactions generated from the last stop time of my replication app to the start time of it. I wonder how i can implement this "skip" operation. ...Show All
Software Development for Windows Vista Step-by-step UAC Guide
Can someone tell me, step by step, on how to add UAC elevation to apps in Vista I'm looking for elevation prompts to let the application carry out some Admin-specific tasks sometimes. UAC dcumentation is really, really poor and non-existent and existing Microsoft sites just goes on about how ingenious UAC is but never really goes into much details on HOW TO ADD it to applications. It's all very confusing. Thanks < Eretria-chan@discussions.microsoft.com > wrote in message news:2552aad5-baae-47bd-848d-7d45983e6417@discussions.microsoft.com ... Can someone tell me, step by step, on how to add UAC elevation to apps in Vista I'm looking for elevation prom ...Show All
SQL Server SQL Agent Database Mail
Hello ! I want to send a Email if my Job fails.I activated the Database Mail and send a TestMail to my Account. This works ! I configured the SQL Agent to my Standard Database Mail account with the EMail Destination. But in The SQL Agent Job under the Notification The Email Combox is empty. I can not select my create Database Mail Account ! "This is the german Version of the SQL Server 2005!" Anyone knows why I can not select the Database Mail Account Thanks Pseudo ...Show All
Windows Forms Does anyone got this unable to copy setup.exe error?
I get the following error once it a while. I reboot the box and it goes away. It looks like something making setup.exe hot. Failed to copy file "local setup.exe" to "server setup.exe". Unable to add 'setup.exe' to the web. The file 'setup.exe' already exists in this web. Thanks. This is really making me nervous. For some reason when I try to publish I keep on getting this error. I changed the version numbers and nothing happened. I asked all the users to reboot(in real world that would be disasterous) and still getting the problem. Only thing pending is to go to the box and see who is holding the file and release file manually. But my concern is why would this happen and in enterprise situation we ...Show All
Windows Forms GDI+/C#: Transition between two images
I have two images that I wanted to transform. http://img462.imageshack.us/img462/7600/day8iz.png http://img254.imageshack.us/img254/1530/night7hv.png Because I'm not going to be using Windows Presentation Framework (formly code-named "Avalon"), I wanted to use .net Framework 2.0 with GDI+. How will I do this Will this require math for subtracting the differences between two colors, divide by 100, and subtract the color by number that I've divided by 100 For example, in pixel X:0 and Y:0 of day.png and night.png, day.png has a color of R:64, G:224, and B:255. Night.png has a color of R:0, G:24, and B:32. So here's how I do it: day.R - night.R = 64 - 0 = 64 day.G - night.G = 224 - 24 = 200 day.B - night.B ...Show All
.NET Development Using Regex/Match to find decimal Index location from RightToLeft.
I am trying to find the decimal index location from RightToLeft using Regex/Match. When the code below runs, I keep getting the index value from LeftToRight even though I specified RegexOptions .RightToLeft . What am I missing here Regex r = new Regex ( @"[.]" , RegexOptions .RightToLeft); Match m = r.Match(tbMainInput.Text); if (m.Success) { m.Index.ToString(); } Thanks for your help... cablehead wrote: Why would you want to add an extra line of code You are absolutely correct. I posted the my last post prior to seeing your solution. Thanks cablehead :) ...Show All
Visual Studio 2008 (Pre-release) if client use more than one service
Dear All, Please explain me, how client can access more than one service I generate 2 proxy-files over "svcutil" tool but these files cannot be compiled together in one project because it has doubled types in this proxies. If anybody have a sample - it would be great! There are a few things to consider here: Two services with distinct types Two services that share types The default behavior of "Add Service Reference" calls svcutil.exe to generate your proxy and related types. It wraps the types and service contract and proxy within a single CLR namespace, that you specify, but it defaults to "lo ...Show All
Visual Studio SP1 Error / Cancel Compile
When compiling my solution, if I select the cancel build option (Build -=> Cancel) Visual Studio believes that it is still compiling when it is not. I can't then exit VS or kick off another build, I have to kill VS it in my processes. Is this a known issue, because if it isn't, it should be! Regards, Andy Andy Burrow wrote: Is this a known issue, because if it isn't, it should be! I take it then you're either researching this problem or making your developers aware I've not yet heard of anyone else reporting this problem. Andy ...Show All
Visual C++ converting a string pointer type to a const char type
Hi there I am coding a function which is supposed to save a file using a save dialog box. IDE is MS.VSCC.2003. I am struggling to accept the string pointer type file name and giving it a relative name, which of a const char type, in my function, can you help thank-you-in-advance stamp What are you source and destination data types If I parse your sentence, you want to go from std::string* str to const char* If that's the case, str->c_str() will give you what you want. Otherwise, you'll need to be specific with some code. ...Show All
