w3hello.com logo
Home PHP C# C++ Android Java Javascript Python IOS SQL HTML videos Categories
Share project between Windows Store Application And WCF Service
To share code between the two projects create a Portable Class Library (PCL) project and reference it in the two projects. Make sure you choose the right .Net framework (for compatibility with WCF project).

Categories : C#

VS2012 project x86 target not running on 32 bit Windows XP
Make sure you target .NET 4.0 (not 4.5). Also make sure both .NET 4.0 Runtime and Reliability Update 2 have been installed on your XP machine (it must be an XP SP3 machine).

Categories : C#

Choosing the right project type and Windows Azure Services for SignalR ASP.NET project
Take a look at SignalR Scaleout - most likely, you want to develop your web application and deploy the web application to an Azure Cloud Service. The Cloud Service runs any number of instances behind a load balancer without any configuration on your part other than pointing your CNAME record to the Cloud Service. For the SignalR part, to make it scalable, you will want to use the Azure Service Bus Relay as a backplane for your SignalR implementation (again, load balanced without you having to woory lots about configuring/maintaining). The referenced example is a good start.

Categories : Azure

Identify application when sharing something from charm in windows 8 store application c#
I believe that you can't, the idea is to have sandboxed applications that don't know about each other. You register them as share sources or targets and then a broker handles the interaction between them so there is never any direct contact. Looking at the available members on the objects used for the implementation I can't see anything that would provide information about where the share was made from. Provide some information about what you want to achieve.

Categories : C#

How to connect WPF Application project to Windows Game project?
System.Diagnostics.Process.Start(@"c:gameGame1.exe"); Try the above with your path. More here: http://msdn.microsoft.com/en-us/library/53ezey2s.aspx

Categories : C#

ADO application compiled in Windows 7 runs in Windows 7 does not run in Windows XP, msado15.dll
I have found the solution. See the bolded section for my exact solution, although this may also solve others. (Taken from this website) Notes •Consider the scenario where you are a C++ developer, and you include the following line of code in the application: #import msado15.dll Consider the scenario that you are not using MSJRO, and you recompile the application on Windows Vista, on Windows Server 2008, or on later versions of Windows. The compiled application must run in Windows Vista, in Windows Server 2008, or in later versions of Windows. In this scenario, you must change #import msado15.dll to the following: #import msado60.tlb Consider the scenario that you are using MSJRO, and you recompile an application that must run in Windows Vista, in Windows Se

Categories : C++

Using a dll in a Windows Store Application
You must not add the dll to your project. Instead rightclick on the references node in your Solution Explorer and then click Add Reference. This popups a dialog where you can selected multiple assemblies you can add. You then can click on browse and select your dll. After that you can use it in your project. If you are generating a simple sheet. You could much easily generate a .csv file. On MSDN there is an example of this.

Categories : C#

How to create Windows Phone 8 app package for windows store using VS Express 2012 for windows phone?
If I understand correctly, you're hoping to publish a Windows Phone 8 app to the Windows Store (on Windows 8)? Publishing to each store (phone/Windows) is a separate process, requiring different projects, and as you've seen, different versions of Visual Studio Express 2012. There's an helpful Windows Phone 8 and Windows 8 App Development Dev Center for guidance on doing this, and a recent article by Doug Holland on "Sharing Code between Windows Phone 8 and Windows 8 Applications" that should help as well.

Categories : Windows Phone 8

How do I launch a Windows Store application programmatically?
The correct way to launch Metro applications is to use the IApplicationActivationManager interface. This is also what Visual Studio itself uses for launching the application. All methods on the interface have a DWORD out parameter which gets you the PID of the newly launched process.

Categories : C++

3D molde rendering SDK for Windows 8 store application in C#
Have you seen this projects Visual-Studio-3D-Starter-Kit, SharpDX or look at this article on section Writing Windows Store DirectX Games -- SharpDX

Categories : C#

How to store Application state in windows phone
You need to implement tombstone functionality. Just read App activation and deactivation for Windows Phone

Categories : C#

Common class between Windows store app and WPF application
We use CSLA business object framework at my shop, and it helps address this very need. Essentially, your business project is first written in regular old .NET, and for your non-.NET biz project (ours is SL), you can simply add existing code as a link, and use compiler directives when needed to hide .net-specific code. It works pretty well, give it a look-see. http://www.cslanet.com/ Fair warning, it does take some time to get comfy w/ the framework, but one of its goals is to address this very problem.

Categories : C#

How to deploy windows app store project (Visual Studio Ultimate 2012)
First installing package using Power Shell you would need to If you have a Machine for test try installing in that. If the app is already installed please un-install it and then re install with new package. Make sure all the contents of the app package is in the other machine(total 1 folder 1 file and inside the folder app. inside the folder two more folders and 3 files including the power shell ). After all these go through this link and check Install from powershell Let me know if it worked else Ill go on searching for more.

Categories : C#

Referencing portable libraries in windows store project - cannot resolve assembly
This appears to be a bug in the XAML compiler, and doesn't seem to be limited to only portable class libraries. Store class libraries also exhibit the same behavior. A workaround I found was to add a reference directly from the Store project to the Level 1 portable library. This caused the build to successfully occur. I've filed a bug internally to track this issue - if you would like to track the progress of this, feel free to file a bug at http://connect.microsoft.com/VisualStudio.

Categories : C#

Fade in/out programmatically a Circle in a Windows Store Application
Can't you convert XAML code to C# code? Something like this: var storyboard = new Storyboard(); var timeline = new DoubleAnimationUsingKeyFrames { KeyFrames = new DoubleKeyFrameCollection { new EasingDoubleKeyFrame(0), new EasingDoubleKeyFrame(1, KeyTime.FromTimeSpan(new TimeSpan(0, 0, 4))) } }; storyboard.BeginAnimation(OpacityProperty, timeline);

Categories : C#

Continuous integration for Windows 8 Store Application with Jenkins
We also use Jenkins for Windows Store App CI by launching and MSBuild job. Maybe this snippet will help you? <Target Name="UnitTest" DependsOnTargets="PreTest;Compile" Condition="'$(SkipTests)'=='' and '$(Platform)'=='x86'" > <ItemGroup> <TestAppx Include="$(SolutionDir)***x86****Tests*.appx" /> </ItemGroup> <Message Importance="high" Text="Running tests for %(TestAppx.Identity)" /> <Exec Command='"C:Program Files (x86)Microsoft Visual Studio 12.0Common7IDECommonExtensionsMicrosoftTestWindowvstest.console.exe" %(TestAppx.Identity) /InIsolation /platform:x86 /Logger:trx /UseVsixExtensions:true' WorkingDirectory="$(SolutionDir)"/> </Target>

Categories : Visual Studio

Must of referencing of third-party libs which used in a class library which is referenced by Windows Store App project
If you use classes from your class library which use SharpDX classes, then compiler of main assembly must know what this classes are, so it needs reference to SharpDX. It's common .net behavior.

Categories : Visual Studio 2012

Populating picture boxes from file path. Windows Metro App, Store App, Windows 8 App
See If all the directories were given access for a win rt app then it would be a security risk So some specific folder are available try storing user data in there . After that only File Picker can Help. Heres the link Folders for winrt Its a Microsoft policy so Please design app accordingly. You might needd to set capabilities in the app manifest file for some folders. Please go through it :)

Categories : C#

PhoneGap file write to absolute path in windows store / windows 8 apps
By default, the only areas an app can access programmatically are (a) your local, temp, and roaming appdata folders, and (b) any libraries for which you've declared a capability in the manifest. For anything else, you must first acquire the StorageFolder or StorageFile object through a file picker. The use of the file picker is what obtains user consent to access that file or folder. If you acquire access to a file or folder this way, then you should preserve access through the Windows.Storage.AccessCache API for future sessions (for recently used lists and such). Trying to get to anything else (e.g. absolute file paths) will give an access denied exception. The code you show above will do this--if you use the file picker you'd be using either the StorageFile API or a relative path on a

Categories : Cordova

Windows Store Application Metronome Stop Button Not Working
Okay, so what you have done is you've subscribed your metronome to two handlers, each happening on the tick timer. First of all, make a static method in your Listener class as the event handler that you can remove. private static void TickPlay(object sender, EventArgs e) { mmx.Play(); } Then, in your Subscribe method, just say: m.Tick += TickPlay; Lastly, for your Unsubscribe method, say: m.Tick -= TickPlay; This way it won't keep going Play/Stop ever tick interval.

Categories : C#

Playing simple sounds in a Windows Store (Metro) application
Based on this article, below works OK for me: public async Task<IRandomAccessStream> BeepBeep(int Amplitude, int Frequency, int Duration) { double A = ((Amplitude * (System.Math.Pow(2, 15))) / 1000) - 1; double DeltaFT = 2 * Math.PI * Frequency / 44100.0; int Samples = 441 * Duration / 10; int Bytes = Samples * 4; int[] Hdr = { 0X46464952, 36 + Bytes, 0X45564157, 0X20746D66, 16, 0X20001, 44100, 176400, 0X100004, 0X61746164, Bytes }; InMemoryRandomAccessStream ims = new InMemoryRandomAccessStream(); IOutputStream outStream = ims.GetOutputStreamAt(0); DataWriter dw = new DataWriter(outStream); dw.ByteOrder = ByteOrder.LittleEndian; for (int I = 0; I < Hdr.Length; I++) { dw.WriteInt32(Hdr[I]); } for (int T = 0; T < Sa

Categories : C#

Unable to set range header for HttpWebRequest in windows 8 store application
Try this var client = new HttpClient(); var request = new HttpRequestMessage(HttpMethod.Get, this.FileUri); request.Headers.Range = new RangeHeaderValue(0, 1024); //if range is of "bytes=0-1024"; var response = await client.SendAsync(request);

Categories : C#

How to store string values in a Windows mobile application and retrieve it later
There are a bunch of way that this can be made possible. I prefer saving this value (along wiht any other value you would like to save) inside of a .xml file. When you proess the "OK" button on your form, it will save the value to the value. Once you open the form, it will open and read the .xml file assinging the values as need be. Check out this link on how to read and write to .xml files.

Categories : C#

Does each Windows Store application have its own network level/layer that can be accessed?
WebView in 8.1 has mechanism to intercept resource requests and replace them with your own. See http://channel9.msdn.com/Events/Build/2013/3-179 around 42 minutes. Basically you will have to create your own implementation of IUriToStreamResolver.UriToStreamAsync that uses HttpClient to get all of your data through proxy.

Categories : Dotnet

Recursive through Pictures Library in Windows Store Javascript Application
Note that picturesLibrary is just a well-known instance of StorageFolder. Something like this should get you closer (adjustment may be needed depending on whether you're looking for depth first or breadth first listing): handleFolders([ Windows.Storage.KnownFolders.picturesLibrary ]); function handleFolders(folders) { for (var i = 0; i < folders.length; i++) { console.log("Folder: " + folders[i].name); folders[i].getFilesAsync().then(function (files) { handleFiles(files); }); folders[i].getFoldersAsync().then(function(folders) { handleFolders(folders); }); } } function handleFiles(files) { for (var i = 0; i < files.length; i++) console.log("File: " + files[i].name); }

Categories : Javascript

Windows Store Application - Synchronously waiting for an async operation
This is not a solution for doing anything synchronously, it's simply how to avoid calling back to the UI thread when you don't need to. The problem with your actual code is that you've defined an extension for IAsyncOperation<T>, not IAsyncAction.

Categories : C#

How to achieve SematicZoom like Windows App Store in Windows store app?
You can achieve this by wrapping the GridView with a SemanticZoom object <CollectionViewSource x:Name="Results" Source="{Binding esults}" IsSourceGrouped="true" ItemsPath="Items"/> <SemanticZoom > <SemanticZoom.ZoomedOutView> <GridView ItemsSource="{Binding CollectionGroups, Source={StaticResource Results}}"> <GridView.ItemTemplate> <DataTemplate> <!-- Template for ZoomedOut --> </DataTemplate> </GridView.ItemTemplate> </GridView> </SemanticZoom.ZoomedOutView> <SemanticZoom.ZoomedInView> <GridView x:Name="itemGridView" ItemsSource="{Binding Source={Sta

Categories : C#

Best way to store private files in a node.js application hosted on Windows Azure
This question is a bit open-ended, as I'm sure there are several viable ways to securely transfer a file. Having said that: From an Azure-specific standpoint: You should be able to upload a file to your Web Site via ftp. Also, you could push a file to a specific blob and have your app check periodically for files in said blob. To upload (or download later), you'd need the storage account's access key, and as long as you're the only one with that key, you should be ok. When uploading from outside of Azure, you can connect to storage via SSL, further securing the upload. While you could probably use a queue (either Storage or Service Bus) with the .pem file as payload in a message that your node app would monitor, you'd need to ensure that the file fits within the limits of the message siz

Categories : Node Js

TranslateTransform offsets element a bit too much after multiple transforms in Windows 8 store application
OK, I got it to work. The problem was that there was a slight mismatch between the Point coordinates in the following code bits: TranslateTransform translateTransform = (sender as Grid).RenderTransform as TranslateTransform; translateTransform.X += e.Delta.Translation.X; translateTransform.Y += e.Delta.Translation.Y; and double xOffset = -e.Cumulative.Translation.X; double yOffset = -e.Cumulative.Translation.Y; The solution was to retrieve the value of e.Delta.Translation.X and e.Delta.Translation.Y and assign their values to the variables xOffset and yOffset. Retrieving the values of e.Cumulative.Translation.X and e.Cumulative.Translation.Y gave slightly different coordinates so the element kept jumping back to the wrong location.

Categories : C#

Move to the next control on enter/return press in Windows 8 Store application
You can handle the KeyDown/KeyUp events on your TextBoxes (depending on whether you want to go to the next one at the beginning or end of the key press). Example XAML: <TextBox KeyUp="TextBox_KeyUp" /> Code Behind: private void TextBox_KeyUp(object sender, KeyRoutedEventArgs e) { TextBox tbSender = (TextBox)sender; if (e.Key == Windows.System.VirtualKey.Enter) { // Get the next TextBox and focus it. DependencyObject nextSibling = GetNextSiblingInVisualTree(tbSender); if (nextSibling is Control) { // Transfer "keyboard" focus to the target element. ((Control)nextSibling).Focus(FocusState.Keyboard); } } } Full example code including code for t

Categories : C#

thread synchronization in windows store apps (windows 8.1)
AutoResetEvent does exist in Windows 8.1 Store Apps. In fact I was able to create a test application in VS 2013 (preview version) that uses it. All I did was add the following line: using System.Threading; I was then able to access these synchronization classes: AutoResetEvent ManualResetEvent ManualResetEventSlim Monitor Mutex ReaderWriterLockSlim Semaphore

Categories : C#

Calling a WCF service using Windows Auth from a Windows Store App
Turns out that the issue was a result of me hosting the service (for testing) on my laptop and calling it using 'localhost'. I've deployed the same service to another server on our domain and updated the endpoint address in the app and it all worked just fine. Looks like there's a restriction on windows store app calling services on localhost Not quite sure why this is working fine if I provide the credentials explicitly and does not if I just carry the logged on user though..

Categories : C#

getProcAddressW errors when use visual studio2005 and windows mobile SDK to debug windows CE project
The first compiler error is somewhat self explanatory. get "W" at the end of GetProcAddressW means that the method is the wide character API (as opposed to GetProcAddressA, which is the ASCII version). Windows CE only exports the wide character versions of APIs. That means that you have to pass in a wide-character string. You used a TCHAR macro when you used _T, which makes the enclosed string a wide character literal, and the error goes away. The same code should work fine on big Windows (for any recent version anyway), provided that you #define UNICODE (which is probably already on) and #include "tchar.h" which I think you since _T compiles. You could explicitly call GetProcAddressW instead of just GetProcAddress (which should be #defined to the wide version if UNICODE is defined).

Categories : C++

VisualStudio 2012 crashes on opening web-based project - Windows 7 - Windows error message
I really don't know what was the cause of the problem, but after all other tries I've applied all pending updates of Windows Update service and everything works well after that.

Categories : Visual Studio 2012

Accessing office project classes from windows form application in C#
Its all documented, here is a great example: How to automate Microsoft Word to create a new document by using Visual C# So to pass the strings in the datagridview to word to print you do it like this: //Start Word and create a new document. Word._Application oWord; Word._Document oDoc; oWord = new Word.Application(); oWord.Visible = true; oDoc = oWord.Documents.Add(ref oMissing, ref oMissing,ref oMissing, ref oMissing); //Insert a datagridview info into the document. DataTable dt = (DataTable)datagridview1.DataSource; foreach(DataRow dr in dt.Rows) { Word.Paragraph oPara1; oPara1 = oDoc.Content.Paragraphs.Add(ref oMissing); oPara1.Range.Text = dr[0].ToString(); oPara1.Range.Font.Bold = 1; oPara1.Format.SpaceAfter = 24; //24 pt spacing after paragraph. oPara1.Range.InsertParagraphAft

Categories : C#

VB.NET: Is windows form application project deployment with Mysql database is feasible?
You can make add a Setup and Deployment project to the vb.net solution, and include MySql in it. One way to do this is copy the MySQL install file with your project installation, then when your application runs, if it doesn't find MySQL, ask the user if it should be installed.

Categories : Mysql

Azure table storage query fails with AuthenticationFailed error in windows store application
Finally - the root cause of the bug is out. The issue is value of x-ms-date header. Expected value - Thu, 06 Jun 2013 08:09:50 GMT Value computed in the code above - Thu, 6 Jun 2013 08:20:34 GMT The 0 missing before the date is the root cause of this bug. Because of that, stringToSign used in computing the authorization header is incorrect. Hence, Authorization Header is incorrect leading to AuthenticationFailed error. This also explains the reason why this code worked couple of days back (end of may - date had two digits). If someone from MS is reading this, it will be so much useful to have right amount of details along with the error code. AuthenticationFailed error code alone does not give any clue to developer. I had used azure storage blob rest api earlier. It returns better erro

Categories : Node Js

Identity and Access Manager not displaying "Use the Windows Azure Access Control Service" on Existing Project
Did you created any identity provider? Please check the following article to get more detail : http://blog.tomasjansson.com/configuring-windows-azure-active-directory-access-control

Categories : C#

Visual Studios "if Output Type == Windows Application then..."
There is just no point in doing this. That Main() method is only ever going to run when the assembly is built as an EXE project. If it is built as a class library then it is just an unused method that nobody is ever going to call and is never going to get jitted. So there's no point in complicating your build to eliminate it. If you really, really want to do this anyway then you'll have to use a conditional compilation symbol. Project + Properties, Build tab, Conditional compilation symbols setting. And #if in your code. Also note that even building as a class library is unnecessary. An assembly that was built as an EXE project works just as well as a class library. Just add the reference. Not having a real distinction between EXE and DLL assemblies is a very nice .NET goody. On

Categories : C#

installing a console application as a windows service in windows server 2003
Now I want to install this console app using the installutil.exe as a service. You need to convert it to a Windows Service application instead of a console application. See the Walkthrough: Creating a Windows Service on MSDN for details. The other option would be to use Windows Task Scheduler to schedule the system to run your Console Application. This can behave very similarly to a service without actually creating a service, as you can schedule the application to run on any schedule you choose.

Categories : C#



© Copyright 2017 w3hello.com Publishing Limited. All rights reserved.