Speedy2000's Q&A profile
SQL Server Recursive query?
I have a set of data and I need to actually add a column to the result set based on information contained within the query. For example, SalesmanID SalesBudget SalesRegion Product Amount 1 1000 USA Soap 100.50 1 &nbs ...Show All
Visual Studio 2008 (Pre-release) ChannelFactory.Close() throws CommunicationException error
Hi, I've created an intermediate service that accepts a message on a one-way contract from a client and then forwards the message onto a server based on a message header entry. The service contract for the intermediate service requires sessions and the binding uses wsHttpBinding with reliableSession set to true. When I receive a message from the client and then create a channel factory to forward the message to the server, when I close the channel factory I get the error: 'The communication object, System.ServiceModel.Channels.ServiceChannel, cannot be used for communication because it is in the Faulted state.'. void IOneWaySessionRelayService.RelayMessage(Message message) { // Find ultimate receiver endpoint Ulti ...Show All
Windows Forms getting ComboBox to Open MyPictures
I'v been trying to get a ComboBox to open My Pictures Folder so a image can be Selected...I was woundering if someone could help me out with this issue... Code: private void pComboBox( object sender, System. EventArgs e) { OpenFileDialog dlg = new OpenFileDialog (); dlg.Filter = "MyPictures(*.jpg)" + "|*.png|All Files (*.*)|*.*" ; dlg.InitialDirectory = MyPictures.DefaultDir; try { if (dlg.ShowDialog() == DialogResult .OK) { _MyPictures.Open(dlg.FileName); } } catch ( Exception ) { MessageBox .Show( "Unable to open " + "album\n" + dlg.FileName, "Open Album Error" , MessageBoxButtons .OK, MessageBoxIcon .Error); } } } ...Show All
Visual Studio 2008 (Pre-release) MarhalByRefObject
Two questions: 1.) I'd like to create a proxy for automatically generated entity framework classes. The problem is that the generated classes do not extend MarshalByRefObject. Is there any workaround 2.) Is it possible to define that the properties of the generated classes are private instead of public Thanks! Marcel Adding on to Mike's Answer: With respect to the second question, our code gen tools will read an attribute on the getters and setters for each property you define and allow you to define those methods as public, internal or private. Here's the schema extensions you'd need to use in your CSDL file: < xml version = " 1.0 " encoding = " utf-8 " > < xs:schema ...Show All
Game Technologies: DirectX, XNA, XACT, etc. animating textures
Hi there - this is probably a very simple problem but I've not stumbled over the answer yet. My Art Monkey has just sent me a model with an animated gif file attached. XNA complains about this texture so presumably gifs are not yet supported. Is there a way round this For instance a simple way to apply a texture to a model, or change the UV coordinates a model is using, so I could have a big bitmap with the necessary graphics on it and just change the UV Or even some way to load a bitmap into another structure, perhaps a Texture3D, which I've just noticed, and apply it to a model. Apologies if this is painfully simple or has been covered elsewhere. Cheers Robin. Do You have some programs to ...Show All
SQL Server SQL SERVER- DATATYPE CONVERSION ISSUE
I have a field that has date value, but the datatype is DECIMAL The value is 20051201.0. When I use the convert to datetime statement, it errors our with the foll error: How do I convert the decimal datatype to a valid datetime select convert(datetime ,20051201.0)- this errors out with the foll err: Arithmetic overflow error converting expression to data type datetime. Is this sufficient select convert(datetime ,convert(varchar(8),convert (int, 20051201.0))) as [convert dateTime] -- convert dateTime -- ------------------------- -- 2005-12-01 00:00:00.000 ...Show All
.NET Development MSMQ public queue
Hi, recently i was trying to create public queues on a workgroup machine but i realised that i cannot create public queues on a workgroup. Only on domain but i am still not sure about this. And can i create a public queue remotely on another computer Say Machine A creates a public queue on machine B Can i add triggers programmatically Thanks I have a follow up question to this. I understand that cannot create a public queue within a workgroup, but you can create a private queue and allow applications to access it, provided they provide the IP address or the name of the computer. In the MessageQueue constructor documentation there are some hints on how to do this; however I am running ...Show All
Visual Studio Bitmap image not displaying for IE - OK on Firefox
I have a report with an image coming from a database field. I have tried viewing the report as a local using the ReportViewer control in a web page. Also have tried it as a remote remote report in reportserver. In both cases the bitmap image shows up correctly if I use Firefox as the browser but doesn't when using IE. With IE I just get the small square with red x. If I export the report to PDF or Excell the images display fine. If anyone else has had this problem and has a solution please let me know how to fix this. Any help would be appreciated. Tom Richards trichards@pharmitas.com ...Show All
Visual Studio 2008 (Pre-release) error when hosting WPF control inside of a Winform Application
Hello All, I am trying to follow the example for hosting a WPF Control inside of a Windows Forms. While I am doing that it compiles successfully, but I get the error that: " NET20andXAML.vshost.exe has encountered a problem and needs to close. We are sorry for the inconvenience." Any help on this I am using the WindowsFormIntegration Examples using the private void Form1_Load( object sender, EventArgs e) { // Create the ElementHost control for hosting the // WPF UserControl. ElementHost host = new ElementHost (); host.Dock = DockStyle .Fill; // Create the WPF UserControl. XAML. UserControl1 uc = new XAML. UserControl1 (); // Assign the WPF UserControl to t ...Show All
Windows Forms Tab Key is not tapped!
Why doesn't my code work The code is in the KeyPressed event of my textbox - If e.KeyChar = ControlChars.Tab Then messagebox.show ("Tab key was pressed!") end if Regards! Kapalic But, unless VB handles these events differently than C# (and I doubt that this is the case), you should not have been able to trap the Tab key in either one of those events unless you also overrode either the ProcessCmdKey or the IsInputKey method(s) in your TextBox's parent class. Can you verify this is the case I'm mainly interested in learning whether VB handles it differently than C# (since I don't even have VB installed, I can't test this for myself). ...Show All
Game Technologies: DirectX, XNA, XACT, etc. XNA with languages different than C#
Will XNA express run with other .NET languages different then C# For example, VB or Managed C++ ... I don't care about supporting other languages as I use c# on a daily basis, not that learning a new language is that big of a deal, what was the reasoning to not allow the plugin to run in VS Pro I would assume that express is more extensible than pro or you guys were just trying to keep it simple, but I think it has caused more confusion since there is no reason that I can see offhand that you cannot use the GSE to work with pro. Just curious. Thanks, Chad ...Show All
Windows Forms open chm from winform
How can I invoke chm file in a windows form by clicking a button -Not help button of form- Process is belongs to which namespace any way I used this code: private void Button1_Click(object sender, EventArgs e) { Help.ShowHelp(this, "Help.chm"); } it worked. ...Show All
.NET Development Problem binding an ssl certificate to a port :-(
Look this link. I'm running on Vista RC1 as an administrator on my home pc. The certificate has been crafted with makecert for developing purposes. I'm getting error 1312 while registering it to whatever ip/port. I need this certificate to authenticate a WCF metadata exchange. Thank you. I ran into the same thing C:\Users\>Util\httpcfg set ssl -i 0.0.0.0:8082 -f 2 -h 759b1e267406cc406f78f61082af94d25e05957e HttpSetServiceConfiguration completed with 1312. C:\Users\>httpcfg set ssl -i 0.0.0.0:8082 -f 2 -h 313a508be3cb4d4df2accee8f44cf5290e6d604b HttpSetServiceConfiguration completed with 0. The second cert has the ability to encrytpt data, so I think it is a cert configuration issue. ...Show All
Smart Device Development Getting file's directory
I'm trying to get the full directory path for a file in VB .NET and have tried a variety of techniques. My biggest problem is either a 'NULL' return or a "" return. Attempts include: 1. FileSystemInfo.FullName .... this returns a Null 2. FileInfo.Directory....returns a Null How do I get this work without it returning a null result Hi, try this using System.IO; FileInfo File = new FileInfo (FileFullPath ); Directory = File.Directory.ToString(); thanks ...Show All
SQL Server Cannot find ODBC drivers
I'm using dreamweaver to create a site, and I am trying to get a database to work with it. I'm using asp and to connect to the dsn i need odbc drivers. When i open the box to set up the connection, none are listed. however, when i tried to install mdac 2.8, it said it could not install because it is already running on my system. Where are my drivers help please! Are you using the Jet driver Suggest you post another thread in this forum for the quesiton as i am not a jet expert. Maybe someone else can help you on it. :) ...Show All
