twaltz's Q&A profile
Visual Studio 2008 (Pre-release) Override properties set manualy with resourcedictionary.
Look at this code: mediaplayer.Height = 500; mediaplayer.Width = 500; Stream s = File .Open( "myskin.xaml" , FileMode .Open); ResourceDictionary rd = ( ResourceDictionary ) XamlReader .Load(s); s.Close(); this .Resources = rd; Skin.xaml contains this: < Style x:Key = " mediaplayer " TargetType = " {x:Type Grid} " > < Setter Property = " Width " Value = " 200 " /> < Setter Property = " Height " Value = " 200 " /> </ Style > Why will the mediaplayer get the height/width 500 and not 200 I want the last assigned value to have priority over the old one, regardles ...Show All
Visual C# static contstuctor called multiple times?
i guess we've broken smth in our application and now i see a pretty weird thing - static contructor is called twice from the same process here is the code: static bool temp = false ; /// <summary> /// Initializes the static members of this class. /// </summary> static WebTransaction() { // EXCEPTION_REFACTORING AppDomain currentDomain = AppDomain .CurrentDomain; currentDomain.UnhandledException += new UnhandledExceptionEventHandler ( MyUnhandledExceptionEventHandler ); // Log the start of the service. EventLog .Information( "Web Transaction Service is starting: " + Process .GetCurrentProcess().Id + " / " + temp); temp = true ; try { ...Show All
.NET Development Spontaneous Uninstalls
Hi: This is a bit wierd...we have a number of .net applications (2003) that use crystal reports. Recently (and very intermittenly), some of the applications will be in use and they will spontaneously uninstall themselves. We reinstall and they run fine...no errors thrown. My search on the internet hasn't turned anything up and I was curious if anyone had any thoughts. Thanks! f_red Thoughts... I'm thinking is is going to take some social engineering. .NET apps just don't do this out of the box; if you'd want them to, you'd have to write some pretty complicated code. Anybody out there that is adverse to the idea that .NET is getting main stream Who has access Any Click-Once deployments (poorly understand by me and anybody I k ...Show All
Gadgets Possiable to have text with no background or transparent background
I'd like to have text just floating with no background at all how would I do that. Thanks I have this working <body> <g:background id="bodyBackground" src="blank.png"/> <script language="JavaScript"> text = "Some text"; bodyText = bodyBackground.addTextObject(text, "Segoe UI", 12, "White", 1, 1); </script> </body> the style tag seem to make the text dissapear If I load a non blank png, the picture is offset to the right by quite a bit, therefore you can't see anything, plus you get a weired halo floating away from the main part of the picture and the text. If I scale up the font size of the text I ge ...Show All
Smart Device Development Type.GetConstructors() - InvalidProgramException on CF, works fine on the standard framework
I have a piece of generated code that the CF (2.0SP1, August patch) just won't accept. The code is working just fine on the big framework, but mscorlib in CF gives me an InvalidProgramException. The context of the call to Type.GetConstructors(): protected virtual object CreateInstanceWrapper(Type type, params object[] args) { object instance; #if !CF instance = Activator.CreateInstance( type, args ); #else ConstructorInfo constructor; Type[] argTypes; argTypes = GetTypeArray(args); constructor = type.GetConstructor(argTypes); if (constructor == null) throw new ArgumentException("There is no matching constructor"); instance = Activator.CreateInstance(type); constructor. ...Show All
.NET Development How to empty a table in a database
Hi, I use VB 2005 Express edition. I want to empty a table in a MS Access data base and set the primary key to 1 for the next entry. How can I do that Thanks! Could you post your connection string The error usually indicates that there is a problem with the connection string syntax or the provider/driver is not installed or is misconfigured. ...Show All
Windows Forms Controls acting as a treenode within a Treeview Control
Is there no out of the box support to have different form controls acting as a node in a treeview eg. When I expand a node it shows a data grid. thanks, dave I've seen several control vendors out there that have this feature that you like. Component One has a grid control that can be configure many different ways. ...Show All
Visual Studio 2008 (Pre-release) BitmapEffects.... What the???
Howdy.. I am trying to create a BitmapEffect to turn an image into grayscale... I am almost there accept I get a COM failure... (I shall not go into the managed rant...) The specific return error is: System.Runtime.InteropServices.COMException was unhandled Message="Error HRESULT E_FAIL has been returned from a call to a COM component." Source="mscorlib" ErrorCode=-2147467259 StackTrace: at System.Runtime.InteropServices.Marshal.ThrowExceptionForHRInternal(Int32 errorCode, IntPtr errorInfo) at System.Runtime.InteropServices.Marshal.ThrowExceptionForHR(Int32 errorCode) at MS.Internal.HRESULT.Check(Int32 hr) at System.Windows.Media.Effects.BitmapEffect.SetValue(SafeHandle effect, String propertyName, Objec ...Show All
Visual C# Exception has been thrown by the target of an invocation?
hi, What do these errors mean Method 'GetDataAdapter' in type 'Business.SimpleDataAdapter' from assembly 'Business.DataAdapters, Version=1.0.0000.00005, Culture=neutral, PublicKeyToken=12fgdfg12fgeg2gfdg' does not have an implementation. Warning 1 Exception has been thrown by the target of an invocation. 0 0 why do they stop the UI designer from displaying the form Thanks. The method is ... public virtual Business. IDataAdapter GetDataAdapter( ) { return new DataAdapter ( ) ; } Sorry for the confusion, i have only just started here and this is someone elses code im tryin to figure out. Thanks. ...Show All
Visual Basic WebBrowser control in vb.net.
Hi, How can a get the text from WebBrowser control in vb.net. Thread will be moved to the appropriate forum once the forums are back up and running again. You can use the DocumentText property: Dim theHtmlText as String = Me.theWebBrowserControl.DocumentText or you can go into the Document property itself, there you can go into say the Body property to get the body part of the Html page. I hope this link helps you/gives you more information about the control http://msdn2.microsoft.com/en-us/library/system.windows.forms.webbrowser.aspx http://msdn2.microsoft.com/en-us/library/system.windows.forms.webbrowser.document.aspx http://msdn2.microsoft.com/en-us/library/syst ...Show All
SQL Server The underlying connection was closed: Could not establish trust relationship for the SSL/TLS secure channel
I'm using SQL Server 2005 (SP1) Reporting Services on Windows Server 2003 SP1. I access the report server from Internet using SSL, but the server is not exposed directly to the internet. It is behind a firewall, where the required ssl port is setup and is working fine. In my Reporting Server, the /ReportServer folder works perfect and I can navigate and view all reports. It is the /Reports folder the one that does not work fine. I can enter the /Reports folder, and can list all the reports. But, when I select one of the reports, and it starts rendering, I get the error message: "The underlying connection was closed: Could not establish trust relationship for the SSL/TLS secure channel. The remote certificate is invalid according ...Show All
Visual C++ dataReceived String???
I am receiving data from the serialPort. The data is in the form of a System String. I am able to display the data in a text box but now I want to work on it! The data is from a hardware device so there are a few states that I need to display. Each string begins with a U, I, O, or P. There is some 0's and 1's and ends with a carriage return, line feed. When the program sees a \r\n I want to the program to examine what was received and give the correct output accordingly. I assume that I will need to read the data received into an array - but each time I try, I get error messages relating to the fact that you cannot convert a system string into a char or int. How would I store the string data that is received How do I then lo ...Show All
Visual C# Unable to upload file to OS/400 using FTPWebRequest Any idea ?
When I issue following command to OS/400 i-Series system : Error is exception = {"The remote server returned an error: (501) Syntax error in parameters or arguments."} Work good for ftp://localhost (windows operating system ) FTPAddress contains FTPAdddress : = ftp://ip address/path/test.txt request = ( FtpWebRequest ) FtpWebRequest .Create( new Uri (FtpAddress ) ); request.Method = WebRequestMethods . Ftp .UploadFile; request.Credentials = new NetworkCredential (FtpUserName, FtpPassword); request.Timeout = FtpRequestTimeout; Stream requestStream; byte [] buf; int i; Getting error right here---------> when calling getrequeststream() method. requestStream = request.GetRequestSt ...Show All
Software Development for Windows Vista Can i get access of RuleEngine without workflow ?
Hello Every body In my application i have schenerio like this. 1. A user (actually user in this case is admin or domain expert). will configure its UI , means he will select 'column1' column of 'table1' will be of type 'type1' and will follow rules 'rule1' , 'rule2' and 'rule3'. in this way he will prepare his presentation layer, (as he is itself uploading data)now in this case there will be some implecit rules applied , and some will be applied by user. say id field of table is implicitely sey to number, but can be set to alphnumeric by user (its a rule applied to that column, that must be executed before data insert) so my question is what would be best choice of technology , WF with Rule engine, or just RuleEngine , ...Show All
Game Technologies: DirectX, XNA, XACT, etc. ... I did it VB.NET TRIDEX compile and Load an xfile from content pipe line so easy thans XNA team .....
Hi, They said it could not be none, well here it is for vb.net load and compiling a xnb file nd displaying a model!!!!!! VB.NET code on my website: http://www.tridexconsultants.co.uk/pages/downloads/XNA%20VB.NET.zip Notes: Nice code microsoft, for creating asset files, if I can do this with your setup why not do it for us vb.net users. Secret to going this is highlighted in read, for the moment we have to manually do it, But I guess I could edit the Project file (Visual Basic Project file) xml vb.net users can refrence this file as I have copied the XNA dlls to the bin dir of the zip file: <Import Project="$(MSBuildExtensionsPath)\Microsoft\XNA\Game Studio Express\v1.0\Microsoft.Xna.ContentPipeline.targets" ...Show All
