cohnerap's Q&A profile
Visual C# How setting property file ??
Hi, I have one file .config: FILE NAME: App.config < xml version = " 1.0 " encoding = " utf-8 " > < configuration > < appSettings > < add key = " DiretorioDestino " value = " c:\ " /> </ appSettings > </ configuration > How I setting the value in this file I know read this value, but not setting. Thanks.... Brunno Tavares One can change App.config file though it's a bit tedious job! Please remember that your App.config file will be renamed to <your-app-name>.exe.config at runtime and can be found either under /bin/release or /bin/debug folder!! Here is h ...Show All
Smart Device Development ORM tools for the compact framework
Hello Everyone, Haven't found much info on this. Is anyone currently using an orm tool such as nhibernate for their compact framework apps Thanks! Ryan ORM is a nicety to speed up development. In the embedded world the speed of the app is generally more important. I wish I could use ORM but the apps I write generally have a lot more going on at the same time and I can't afford the performance hit along with the rest of it. I haven't tried NHibernate on CF but I don't assume it'd be that quick, I have tried DB40 though and that's can be about as reasonable as SqlCe ( e.g. too slow ) in a lot of situations so it might be worth checking out (requires a license for commerical projects). ...Show All
Visual Studio Team System No warnings flagged by /analyze for uninitialized strings?
Hi, Why doesn't code analyzer flag any error in the below case. Incidentally, it does flag C6001 and C4700 if I uncomment the 'if' statement. Is there a way to force the analyzer to flag in direct assignment of uninitialized ptrs as well #include "stdafx.h" int _tmain(int argc, char* argv[]) { char* str; // if ( str) str = argv[argc+1]; printf("%s",str); return 0; } Thanks. The analyzer doesn't know how many elements of argv are valid. It probably should, though, since the contract for main is defined by the C++ standard. We'll look into that for the next release. However, you can use an annotation ( http://msdn2.microsoft.com/en-us/library/ms182032(VS.80).aspx ) to explici ...Show All
Visual Basic Visual Studio 2005 Clickonce Deployment error
I am attempting to deploy an application for others to use. I have been trying to install this application for 3 weeks and have run into many different errors while running the setup.exe on client pc's. I have worked through all of them except for this one: WindowsApplication1 has encountered a problem and needs to close. We are sorry for the inconvenience. This error occurs on every pc that I run Setup.exe on that doesn't have Visual Studio installed. There is no other message that gives me any idea as to what is missing or what to look for. Does anyone know what I can do to successfully deploy this application Thanks, S. Richardson ...Show All
Gadgets SideBar Gadget and <object /> Tags
I assume that SIdebar is using a mini-IE7 window to display themselves, but I can't seem to get an <object /> tag to work in my gadget. Any idea why that wouldn't work Before I spin my wheels understanding what is happening, I wanted to make sure that there wasn't a security prohibition to using an <object /> or a <embed /> tag. It should work, I'm using ActiveX pretty extensively in my gadget without many problems(though security in Vista can be hard to handle). Dan ...Show All
Visual Basic Best place to put application initialisation code
Hiya, I'm trying to get to grips with using a VB2005 splashform. Where's the best place to put in initiliasation code, like loading in XML settings, checking DB connection Is it in the Application OnInitialize function, the splashscreen_Load sub or somewhere else I'm a little concerned in that the splashscreen will close after X number of seconds. How do you ensure that all the initialisation is done before it closes Many thanks John you shouldnt really put the thread to sleep, not only will it pause the entire application as if it has hung but the user would be wondering whats happening and why it appears to be hung. ...Show All
Microsoft ISV Community Center Forums vba create and add a macro for excel programmatically
Hi all I am currently traying to introduce into an excel spreadsheet a macro programatically. I have found examples on the net but they dont seem to work or they are for VB and not VBA. I was wondering perhaps someone knows how. I am currently generating many the excel spreasheets from through access vba. I am stuck when adding the macro to the sheets. They just dont seem to be there even though i save the data. Here are two examples i tried. The first one is VB so not a chance it will work but the second should and it doesnt. It does not give any errors or nothing. The excel sheets are created but no macro! hmmm EXAMPLE 1 myWrkb.VBProject.VBComponents.Add 1 'vbext_ct_StdModuleWith myWrkb.VBProject.VBComponents myWrkb.VBProje ...Show All
Visual Studio 2008 (Pre-release) Writing reusable effects in XAML
After playing around a little bit with storyboards, I decided to create a library of reusable visual effects. Examples include whisking a visual element from one side of its container to the other side, fading in/out in the middle of the container etc. This is easy to accomplish in code, but I'm looking for a way to define such effects in XAML. Naturally, the effects have to be parameterized, so it seems that various property values in the markup should be bound to dynamic resources. Having made this brilliant observation, I don't know how to proceed. Suppose I have a storyboard that targets the translatetransform.X property, using a splinedoublekeyframe to change it. I'd like the value of the keyframe to be based on the width of the panel ...Show All
Smart Device Development MSN Messenger error on POCKET PC: QTEK S200
Hi, Infact i don't really know if this is the right place to ask my question or not but please accept my appology if this is not the right place. I have bought a QTEK S200 (IMATE JAMIN) Pocket PC. It includes Pocket MSN which has MSN messenger in it. I have tried loging in to pocket MSN using my WIFI connection but apperantly it doesnt work. at leaset the MSN didnt work. It just gave me the error: "Logon to the Messenger Service failed because the service is not responding. Please try again later" Retry | Cancel I was just wondering there is a way to solve that problem or not. Thank you for your time. and again sorry if this topic doesnt belong here. -Peymon This f ...Show All
SQL Server What is a good tool for modeling a SQL Server 2005 database?
Hello, I need a tool that will let me model a SQL Server 2005 database and then generate the tables, constraints, etc. from the model. I've never used a modeling tool so my knowledge is quite limited. I don't need to model or reverse engineer an application - my sole concern is on the SQL Server database side. I'm not concerned if the tool integrates with Visual Studio. And, of course, price is one consideration. Are there any good tools that I should look at Thanks, BCB I would suggest checking out QUEST Software - they have been around for years and they build great DB Software for all brands of DB's. I was particularly impressed with their Data Modeler Tool; http://www.quest.com/Toad_ ...Show All
SQL Server Attempting to transpose/pivot columns to rows... I think.
I have something of a challenge for you folks (at least it's very challenging for me). I have a table that has data that looks like this: Date______OrderNum____WorkDay 2006-06-1__AA_________1 2006-06-1__AB_________1 2006-06-2__BA_________2 2006-06-2__BB_________2 2006-06-2__BC_________2 2006-06-5__CA_________3 2006-06-5__CB_________3 etc. So, there are dates that orders happened and each date is marked as the 1, 2, 3, etc. business day of the month. What I am trying to write is a SQL statement that will display results thus: Day1______Day2______Day3_______etc . AA________BA_______CA_________etc. AB________BB_______CB_________etc. Is this making any sense to anyone Basically, I need to turn th ...Show All
Visual Studio 2008 (Pre-release) DataBinding ListBox.ItemTemplate = (DataTemplate)FindSource???
I would like to DataBind the ListBox with the Existing <DataTemplate x:Key=" "> Template ok,i'm trying to DataBind the Current ItemTemplate that currently Exists in Xaml first here is the C#:: ListBox.ItemTemplate = ( DataTemplate )FindResource( ResourceKey .Equals(StackPanel.GetBindingExpression( BindingMode .OneWay, System.Xml.XPath. XPathExpression .Compile( XPath=@version )))); The Xaml DataTemplate:: < DataTemplate x:Key = " itemTemplate1 " > < StackPanel x:Name = " StackPanel1 " > < TextBlock x:Name = " TextBlock1 " Text = " {Binding Mode=OneWay, XPath=title} " /> < TextBlock x:Name = " TextBlock2 " Text = " ...Show All
Windows Forms datetimepicker forecolor change(Window form C#)
Hi, i am using window forms ,with .net framework 1.1.I want to know how can i change forecolor of disabled datetimepicker which is inherited from Syncfusion control. Thanks As you are using the 3rd party controls, I'm afraid it's better to consult the Syncfusion: http://www.syncfusion.com/support/forums/default.aspx . As for the standard control, I'm afraid it's not able to do that. ...Show All
Windows Forms Folder Browser Dialog -- Disk Error
When using the folder browser dialog, how do you trap or prevent the "There is no disk in the drive. Please insert a disk into drive ..." dialog. This is happening for disk which the system has identified as removable media. Excel doesn't experience this problem, I believe I should be able to achieve the same level of performance. Hello All. RoadGlide: The pause you mention is a result of the browser polling all of the drives for media identification. I don't think that this polling behavior would be different just because you're running under the debugger. Could you post the code that you use to initialize and start the FolderBrowser Also, please specify what the property settings are in ...Show All
SQL Server SQL 2005 Express local admin access denied
I am using a standard installation of SQL 2005 Express installed with Visual C# Express. I have tried several connection strings, have tried connecting different databases, all of which end up giving me access denied for user <machineName>\Greg (Greg is the local admin account for this PC. I found this guideline for connectivity questions (http://forums.microsoft.com/MSDN/ShowPost.aspx PostID=362498&SiteID=1), and have gone through it all, posting the answers to questions here. One thing that may be different about this machine is that it is a tablet PC (WinXP Tablet edition) and I am running VMWare Server. I also tried loading it on a WinXP Pro workstation with no VMWare, and have gotten the same results. Any help will be greatl ...Show All
