I am creating a project for windows phone, and have made numerous backups over the past month, however when I ran the project this morning I received a Value does not fall within the excepted range error. I have researched this on the internet and all I could find was a few isolatedstorage saving issues which does not apply to me
It happens when I try to navigate to my homepage which is a panorama view, all my server calls are done without issues. And all my backups now also gives this issue. I have no idea where to start looking. the inner stack trace looks something like this:
at MS.Internal.XcpImports.CheckHResult(UInt32 hr)
at MS.Internal.XcpImports.SetValue(IManagedPeerBase obj, DependencyProperty property, Double d)
at System.Windows.DependencyObject.SetValue(DependencyProperty property, Double d)
at System.Windows.FrameworkElement.set_Width(Double value)
at Views.homePanorama.dashboard()
at Views.homePanorama.<OnNavigatedTo>d__7.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.CompilerServices.AsyncMethodBuilderCore.<ThrowAsync>b__0(Object state)"
Width of UI element was coming through as "infinite", just changed that and it worked
Related
We have built our entire project automation suite using UFT 15.0.1.416. We have used Visual studio 2019 to build the automation suite. And there are around 900 test cases we have automated and able to run all of them without any issues in IE 11 browser.
As IE 11 sooner going to retired by Microsoft, we are planning to migrate to Chrome & Edge.
But we are facing issues with Chrome & Edge browsers to run automation scripts.
Chrome Browser: we are able to launch the application & run the scripts.
But running scripts on Chrome is very very slow. It is taking couple of minutes even to execute simple script. When we debug, we have noticed that every operation that interacts with web element is taking lot of time. Even getting the properties of web element like Id, Class are also taking time.
We are using chrome version - 91.0.4472.114.
Edge browser - we are unable to lunch the application using edge browser. Keep on getting following error.
Exception: General Error occurred
at HP.LFT.SDK.Core.Communication.CommunicationClient.HandleError(Action2 onError, Int32 status, IDictionary2 data)
at HP.LFT.SDK.Core.Communication.CommunicationClient.Send(String messageType, IDictionary2 data, Action2 onError)
at HP.LFT.SDK.Web.BrowserFactory.BrowserFactoryInstance.InternalLaunch(Dictionary2 launchInfo) at HP.LFT.SDK.Web.BrowserFactory.BrowserFactoryInstance.<>c__DisplayClass2.<Launch>b__1() at HP.LFT.SDK.OperationExecutionWrapper.ExecuteWithEventsInternally[T](ITestObject testObject, Object additionalInfo, Func1 innerAction, MethodBase methodInfo, Boolean reportOnlyOnError, Object[] arguments)
at HP.LFT.SDK.OperationExecutionWrapper.ExecuteWithEvents[T](ITestObject testObject, Object additionalInfo, Func1 innerAction, MethodBase methodInfo, Boolean reportOnlyOnError, Object[] arguments) at HP.LFT.SDK.OperationExecutionWrapper.ExecuteWithEvents[T1,TR](Func1 innerAction, Func`2 originalMethod, T1 param1, Boolean reportOnlyOnError, ITestObject testObject, Object additionalInfo)
at HP.LFT.SDK.Web.BrowserFactory.BrowserFactoryInstance.Launch(BrowserType browserType)
at HP.LFT.SDK.Web.BrowserFactory.Launch(BrowserType browserType)
And Edge extension is already installed.
Has anyone ever encountered this type of problems ?
Thanks in advance for any help
Please upgrade to latest UFTD 15.0.2 to solve the issue.
I currently use Azure Mobile Services with Offline Sync and I it has been working fine. However I now have come to a problem I can't seem to debug. On the PullAsync it never returns, never goes to the Web API, it never errors, it just seems to be stuck somewhere and I don't know where.
IMobileServiceSyncTable<ResponseType> responseTypeTable = MobileService.GetSyncTable<ResponseType>();
await responseTypeTable.PullAsync(responseTypeTable.Where(c => c.CompanyId == companyId));
I use identical code elsewhere with a different type and it works well.
The only thing that happens is the Windows Phone emulator UI locks up, I can press buttons on the keyboard but the input or buttons are all frozen.
I get this on the Debug Output
The thread 0xb80 has exited with code 259 (0x103).
After a 5 seconds and that's about it. Breakpoints everywhere, nothing happening.
The method was in a Command (I'm using MVVMLight). When I call the function on the class initialization and just hold the value it works fine. There is obviously some bug that occurs when calling PullAsync on an event, in an async RelayCommand but getting the call out of there solves the issue.
I'll leave it at that unless anyone comes back with why it is actually happening. This is just a workaround at the moment.
I am building a WP8 app. On the initial page of my app (after login), I am using the GestureService to manipulate the screen and create the effect of a slideout menu. This is all fine, but the problem is the GestureService is activated whenever a swipe action is performed on ListPicker controls on ANY other page of the app, and throws an unhandled Object reference not set exception, like so:
I've done some digging and this appears to be a bug within the WP Toolkit. The behaviour is the same on both the WP8 emulator and the Nokia WP8 dev phone I am using. According to this thread, I can use the ManipulationDelta and ManipulationCompleted events to achieve the same thing the GestureListener does. So I commented out the GestureService code and added Manipulation events onto the grid on my main page. Low and behold, the problem has disappeared.
Here is the GestureService call (on my initial xaml page), which is now commented out:
<toolkit:GestureService.GestureListener>
<toolkit:GestureListener DragDelta="GestureListener_OnDragDelta" DragCompleted="GestureListener_OnDragCompleted" />
</toolkit:GestureService.GestureListener>
The problem I am now facing is translating the code into the new format. Here is the Gesture code I am using (in VB):
If e.Direction = System.Windows.Controls.Orientation.Horizontal AndAlso e.HorizontalChange > 0 AndAlso Not _isSettingsOpen Then
Dim offset As Double = _feContainer.GetHorizontalOffset().Value + e.HorizontalChange
If offset > _dragDistanceToOpen Then
Me.OpenSettings()
Else
_feContainer.SetHorizontalOffset(offset)
End If
End If
If e.Direction = System.Windows.Controls.Orientation.Horizontal AndAlso e.HorizontalChange < 0 AndAlso _isSettingsOpen Then
Dim offsetContainer As Double = _feContainer.GetHorizontalOffset().Value + e.HorizontalChange
If offsetContainer < _dragDistanceToClose Then
Me.CloseSettings()
Else
_feContainer.SetHorizontalOffset(offsetContainer)
End If
End If
Not all the properties in the GestureListener are available/ comparable to the Manipulation events.
So am I best off soldiering on and attempting to recreate the effect within the Manipulation (if it's even possible), or does anyone know of a better way of doing this; i.e. a way of fixing or circumventing the bug to allow the GestureService to work...?
I already tried adding the GestureListener code and empty Try Catch statements to the pages with ListPicker controls on them, but it didn't solve the problem.
On another (related) note, I can avoid the error by simply setting the exception to Handled in App.Xaml. There is still an unhandled exception there, I'm just ignoring it. Is this behaviour likely to cause my app to be rejected from the store?
Any help is appreciated.
Ok, so low views and no replies to this for almost a week, so here's my temorary fix for anyone finding this via Google.
In the app.xaml, I simply stopped unhandled exceptions from displaying messages to the user:
Public Sub Application_UnhandledException(ByVal sender As Object, ByVal e As ApplicationUnhandledExceptionEventArgs) Handles Me.UnhandledException
' Show graphics profiling information while debugging.
If Diagnostics.Debugger.IsAttached Then
'There is a bug in the WP Toolkit which throws an unhandled exception when GestureListener events are used within the app,
'and a ListPicker control is swiped over. Altering this method ignores these exceptions.
'Diagnostics.Debugger.Break()
e.Handled = True
Else
e.Handled = True
'MessageBox.Show(e.ExceptionObject.Message & Environment.NewLine & e.ExceptionObject.StackTrace,
' "Error", MessageBoxButton.OK)
End If
End Sub
This is certainly not an ideal soultion, but is the only thing I could come up with in place of spending countless hours trying to circumvent the Toolkit bug. It's been a while since the last release, so hopefully it will be fixed in the next one. I'll edit this answer if that happens, or if this fix prevents the app from entering the store.
EDIT: App was submitted to the store successfully, so although not a perfect solution, it will do the job.
I'm trying to capture audio using WASAPI. My code is largely based on the ChatterBox VoIP sample app. I'm getting audio buffers, but they are all silent (flagged AUDCLNT_BUFFERFLAGS_SILENT).
I'm using Visual Studio Express 2012 for Windows Phone. Running on the emulator.
I had the exact same problem and managed to reproduce it in the ChatterBox sample app if I set Visual Studio to native debugging and at any point stepped through the code.
Also, closing the App without going through the "Stop" procedure and stopping the AudioClient will require you to restart the emulator/device before being able to capture audio data again.
It nearly drove me nuts before I figured out the before mentioned problems but I finally got it working.
So..
1. Be sure to NOT do native debugging
2. Always call IAudioClient->Stop(); before terminating the App.
3. Make sure you pass the correct parameters to IAudioClient->Initialize();
I've included a piece of code that works 100% of the time for me. I've left out error checking for clarity..
LPCWSTR pwstrDefaultCaptureDeviceId =
GetDefaultAudioCaptureId(AudioDeviceRole::Communications);
HRESULT hr = ActivateAudioInterface(pwstrDefaultCaptureDeviceId,
__uuidof(IAudioClient2), (void**)&m_pAudioClient);
hr = m_pAudioClient->GetMixFormat(&m_pwfx);
m_frameSizeInBytes = (m_pwfx->wBitsPerSample / 8) * m_pwfx->nChannels;
hr = m_pAudioClient->Initialize(AUDCLNT_SHAREMODE_SHARED,
AUDCLNT_STREAMFLAGS_NOPERSIST | AUDCLNT_STREAMFLAGS_EVENTCALLBACK,
latency * 10000, 0, m_pwfx, NULL);
hr = m_pAudioClient->SetEventHandle(m_hCaptureEvent);
hr = m_pAudioClient->GetService(__uuidof(IAudioCaptureClient),
(void**)&m_pCaptureClient);
And that's it.. Before calling this code I've started a worker thread that will listen to m_hCaptureEvent and call IAudioCaptureClient->GetBuffer(); whenever the capture event is triggered.
Of course using Microsoft.XNA.Audio.Microphone works fine to, but it's not always an option to reference the XNA framework.. :)
It was a really annoying problem which waste about 2 complete days of mine.My problem was solved by setting AudioClientProperties.eCatagory to AudioCategory_Communications instead of AudioCategory_Other.
After this long try and error period I am not sure that the problem won't repeat in the future because the API doesn't act very stable and every run may return a different result.
Edit:Yeah my guess was true.Restarting the wp emulator makes the buffer silent again.But changing the AudioClientProperties.eCatagory back to AudioCategory_Other again solve it.I still don't know what is wrong with it and what is the final solution.
Again I encounter the same problem and this time commenting (removing) the
properties.eCategory = AudioCategory_Communications;
solve the problem.
I can add my piece of advice for Windows Phone 8.1.
I made the following experiment.
Open capture device. Buffers are not silent.
Open render device with AudioDeviceRole::Communications. Buffers immediately go silent.
Close render device. Buffers are not silent.
Then I opened capture device with AudioDeviceRole::Communications and capture device works fine all the time.
For Windows 10 capture device works all the time, no matter if you open it with AudioDeviceRole::Communications or not.
I've had the same problem. It seems like you can either use only AudioCategory_Other or create an instance of VoipPhoneCall and use only AudioCategory_Communications.
So the solution in my case was to use AudioCategory_Communications and create an outgoing VoipPhoneCall. You should implement the background agents as in Chatterbox VoIP sample app for the VoipCallCoordinator to work .
I have an air (4.5.1) mobile project that send an ArrayCollection to the server (Tomcat/BlazeDS)
The server manage the object and return a string containing the result (ok/error/etc)..
Everything worked fine, until:
I tried to send an ArrayCollection with length > 35000 (not sure border limit).
After sending the arraycollection the UI seems like frozen for a little time, and after that
I got a FaultEvent Error
NetConnection.Call.Failed: HTTP: Failed
The server however received the request, parsed it and returned the result string
So, because the program get the faultevent, I cannot be sure (from the client) that the request is finished correctly...
How can I fix it? and is this problem generated by the length of the arraycollection?
Other ideas?
Thanks
This is an on going issue with Flex/Air/Flash. The problem you are running into is a defualt value for requestTimeout of 30 seconds. Even if you change the value in your remoteObject, it is not getting used correctly. There are MANY MANY documented bugs on adobe regarding this issue. Below is a link to a site that has collected some info about this problem from around the web. To date adobe has yet to fix the problem even though that claim they have in previous versions.
RemoteObject Issue