Ashtom's Q&A profile
Visual Basic Preventing application startup after Publishing
I have a VS Windows app written in VB. After I publish the project it automatically starts to run the application. However, for various reasons unimportant to this post I DO NOT want the application to begin running after the publish process has completed. Is there a way to tell a VS project to NOT start the app when publishing is done Also, for another set of various reasons I want to use Publish rather than Install. Thank you in advance. Sean. Had the same issue myself and got round it by creating a setup and deployment project for the application, lose some of the nice features of clickonce but the application does not run and you know where it is... Michael. ...Show All
SQL Server Select statement possiblities??
Hello all, I was wondering if there was anyway to use an "IF" statement inside an SQL SELECT statement. something like the following: SELECT somecolumn, SUM(something, something) AS Total, (IF Total <= 40 Then SUM(something, something) / 60 * somecolumn) AS Total2, SUM(0,0) AS GrandTotal Else SUM(something, something) / 60 * somecolumn) AS Total2, SUM((Total - 40) * somecolumn) AS GrandTotal End If) FROM someTable any idea how to accomplish something simular to this Sum(something,something) is not SQL Server syntax, so if you are doing access again, you will want to use IIF, most likely. If this is SQL Server, this could be written as: SELECT somecolumn, SUM(something) A ...Show All
SQL Server SQL Server 2000 - SQL Query and Explain Plan CACHING
Hi, I would like to know whether in SQL Server 2000 individual queries (not SPs) along with the query plans are cached or not If yes then how can I check it Also, what would be the measurement Is there a hit/miss ratio In the SQL Profiler Trace events, I do not see any event for Individual Query & Query plan caching but I do see for SPs. Any guidance/steps would be really apprecaited. Thanks/ ...Show All
Visual Studio 2008 (Pre-release) How to exit a WPF application
Is there a way to force a WPF application to exit,.. something like application.Exit() in windows forms If not, how can I, for example force an application to exit on a button click Thanks in advance, Marko Vuksanovic. Well it seems like Application.Current.Shutdown(); should work fine.... but there seems to be a problem. If I open window2 from window1 (when it is not yet displayed, that is, in window1 constructor) and then execute Application.Current.Shutdown(); when a button is clicked the application crashes. Any idea what might be wrong P.S. Below is the Window1 constructor: public Window1() { this .InitializeComponent(); // Insert code required on object creation below ...Show All
SQL Server Why select top 100 percent was disabled in SQL Server 2k5 views
And how to get it work And by the way why Sql Server 2k5 became slower then 2k How to get to query planes in the management studio SELECT TOP 100 PERCENT in views is not disabled. You can use it but you need to understand that it doesn't guarantee that the rows from the view will be ordered. This is how it always has been. It just happens that some of the optimizations in SQL Server 2000 is not aggressive enough to produce plans that breaks your expectations or misconceptions I would say. Even in SQL Server 2000, you can get query plans that will not produce the rows in ordered manner. The ONLY way to get ordered rows from server to client is to include ORDER BY clause in the outer-most query scope. This is also according to th ...Show All
.NET Development MS access database used but client does not have access is this possible??
I am developing a program using visual studio 2003 and c# and want to use access as the database. The client does not want to install access on all the workstations is there still any way for the program to still use an access database Thanks in advance Lorne you should have the MS Jet engine/ODBC drivers installed and it should be ok. Try it on a virtual machine system, just install a plain Windows OS and .NET Framework, run your application and see if it will work. ...Show All
Game Technologies: DirectX, XNA, XACT, etc. Height map from texture
Hello this is the old mdx 2.0 code that use system.drawing public float [,] Heightmap = null ; public void LoadHeightmap( string file, Vector3 scale) { HeightMapScale = scale; Bitmap map = Bitmap .FromFile(file) as Bitmap ; Width = map.Width; Depth = map.Height; Heightmap = new float [Width, Depth]; for ( int x = 0; x < Width; x++) { for ( int z = 0; z < Depth; z++) { Heightmap[x, z] = map.GetPixel(x, z).GetBrightness(); } } Console .WriteLine( "loadet and created heightmap" ); //NormalizeTerrain(); //CreateVertices(); //Console .WriteLine( "created vertex" ); } private void CreateVertices() { NumberOfVertices = Width * Depth; ...Show All
Visual Basic Timer Help?
How do I make a timmer that will run code every 5 min drag and drop timer on form in designer view Set the timer interval property to 5 minutes (1 second = 1000 and the interval is calculated in milliseconds) in code, whereever you are going to start running the timer: Me.theTimer.Start() whenever you are going to stop the timer from running: Me.theTimer.Stop() then in the timer tick event (double click the timer control), place your code there - it will run when the time interval has elapsed ...Show All
Visual C++ Problem with legacy application - ATL
Hi All... We have a legacy ATL server that was built under 6.0, specifically its skeleton was built with the application wizard. When registering as an ATL server, a call to UpdateRegistryFromResource is failing with error code 0x80040154. The resource being passed to the function is: HKCR { NoRemove AppID { {21C5E527-62A2-4DAE-BDEB-BF24AC44A7CC} = s 'P100CommSvc' 'P100CommSvc.EXE' { val AppID = s {21C5E527-62A2-4DAE-BDEB-BF24AC44A7CC} } } } Anyone know what the problem might be Thanks! -- Curt Ah yes... Thanks, Ted. I did read something about that on my travels on the web... I've made a note to check that next time we talk to the customer. Thanks again! -- Curt ...Show All
Visual Basic MAKING .NET CONTROLS - OCX VB6 COMPLIANT
Hi all, I have to create a .NET control. It have to run in a vb6 app. I'd like to use it like a standard OCX control. I've found in the net that it's possible. there's anyone who can tell me in which way I can do it It's simple: have a .net control and import it in a VB6 controls list by "add control". and have it working right. Dario TIA for any suggestion! I have found that although it is possible to create a windows control and register it as an activex com control that apparently works under various applications using the template at http://www.sweetpotatosoftware.com/SPSBlog/PermaLink,guid,3dd24f92-a52c-4bb0-8121-c2e6e2cc4f93.aspx it may in effect be unreliable ...Show All
Visual Studio Express Editions Database Connections
How we can connect an Ms Access Database with a visual basic express application Which are best techniques for making database connection & which are faster connection types I use this version on my applications: Using DatabaseConnection As New OleDbConnection("Provider=Microsoft.Jet.OLEDB.4.0;Data Source=c:\db.mdb") DatabaseConnection.Open() 'do work here End Using ...Show All
.NET Development .Net3 merge module
Where can I find a merge module of .Net3 for Installshield. INFO: Including the .NET Framework ...Show All
Game Technologies: DirectX, XNA, XACT, etc. Graphics Device
Why do I keep getting an error box saying d3dx9d.dll was not found how do I fix that do i need to do somethink to the directx sdk after it is installed. dontknow wrote: could it be because it wasn't the redistributable version that they downloaded If you downloaded the most recent SDK you should be fine. It was the August '06 SDK, right Check the C:\Program Files\Microsoft DirectX SDK\Developer Runtime\x86 folder (or wherever you installed it). Is the DLL there ...Show All
Visual Studio 2008 (Pre-release) encoder implementation and proxy resolution
Hello, I have two questions, so if anyone can help: 1) What I need to do/use to implement a custom encoder - a MessageEncodingBindingElement to do a custom stream 2)On the genetated client proxy: How does the innerproxy knows how to resolve the call to some interface contract method and what is this object for ex (on HelloService example): public partial class HelloServiceProxy : System.ServiceModel. ClientBase < HelloService >, HelloService { public string sayHi(){ return base .InnerProxy.sayHi();} } Thanks, Mauro Ok, regarding my second question I know that, but I mean: How does the framework resolves that call (and mapping), wich classes interact to make t ...Show All
SQL Server MSDASQL error requires SQL Service restart
I am having trouble with a linked server using MSDASQL. I'm connecting to a PostgreSQL database and pulling over data. This process has been working fine. In trying to pull data from a different client database (same schema), I received an error that the MSDASQL couldn't read the column names. The actual problem I want help on is that after this happens, I am no longer able to make valid connections to any of my Linked Servers using MSDASQL. The only way I can get my other linked servers to work again is to restart the SQL Service. Usually this is impossible for me to do because of the number of active users. Two questions: 1) Is there another way to restart a more targeted service or sub-set to reset MS ...Show All
