alerts

UITesting of Alerts in xCode 7.1

与世无争的帅哥 提交于 2019-12-03 07:13:42
I'm writing UITests in xCode 7.1 and have a problem in testing alerts (Allow notifications in my case). While creating a test xCode writes this code: app.alerts["\U201cAppName\U201d Would Like to Send You Notifications"].collectionViews.buttons["OK"].tap() Which immediately causes error: Invalid escape sequence in literal So I replaced xCode's code with: app.alerts["\u{201c}AppName\u{201d} Would Like to Send You Notifications"].collectionViews.buttons["OK"].tap() But when I run UITest it fails with message: UI Testing Failure - No matches found for Alert The same for code app.alerts["“AppName”

Alert Popups from service in Python

放肆的年华 提交于 2019-12-01 21:21:21
I have been using win32api.MessageBox to do alerts, and this works for apps running from the interactive prompt and normally executed code, however when I built a Python service when a MessageBox is triggered I can hear the 'beep' but the box does not display. Is it possible to display alerts from services? No, Windows services run on a completely separate hidden desktop and have no access to the logged-on user's desktop. There is no way around this from a service developer's perspective. In previous versions of Windows, it was possible for a service to be marked as "allowed to interact with

iPhone App - Generate Alert Popups when App is Closed

為{幸葍}努か 提交于 2019-12-01 10:55:23
In creating an iPhone app, is it possible to generate a popup alert on the iphone (similar to a Push notification) when the app has been closed. A simple example would be to have an app that can set a reminder at 5:00PM January 5th, 2010. The app can be closed and the reminder will popup at that time. I don't think this is possible but would like to know if anyone has any ideas? Again, i do not want a Push solution but rather a solution that does not require internet access (i.e. "local" push from iPhone). Thanks. You can do it now! And it's really rather simple. Create a UILocalNotification.

iPhone App - Generate Alert Popups when App is Closed

别说谁变了你拦得住时间么 提交于 2019-12-01 08:43:59
问题 In creating an iPhone app, is it possible to generate a popup alert on the iphone (similar to a Push notification) when the app has been closed. A simple example would be to have an app that can set a reminder at 5:00PM January 5th, 2010. The app can be closed and the reminder will popup at that time. I don't think this is possible but would like to know if anyone has any ideas? Again, i do not want a Push solution but rather a solution that does not require internet access (i.e. "local" push

When to use a UIAlertView vs. UIActionSheet

三世轮回 提交于 2019-11-30 12:34:03
问题 Are there situations where a UIAlertView is better to use than a UIActionSheet? What are the typical scenarios where you would use one over the other? I'm programming a navigation bar button to open a UIWebView in an external application, and at first I started programming a UIAlertView, then I thought that an action sheet might be better for this situation. Are there any formal guidelines for which to use in different situations? Thanks. 回答1: From Apple's iPhone Human Interface Guidelines:

When to use a UIAlertView vs. UIActionSheet

你。 提交于 2019-11-30 03:31:15
Are there situations where a UIAlertView is better to use than a UIActionSheet? What are the typical scenarios where you would use one over the other? I'm programming a navigation bar button to open a UIWebView in an external application, and at first I started programming a UIAlertView, then I thought that an action sheet might be better for this situation. Are there any formal guidelines for which to use in different situations? Thanks. Brad Larson From Apple's iPhone Human Interface Guidelines : Alerts, action sheets, and modal views are designed to communicate different things: Alerts give

jConfirm with this existing code

只谈情不闲聊 提交于 2019-11-29 07:59:42
I need help to use jConfirm with this existing code (php & Jquery & jAlert). function logout() { if (confirm("Do you really want to logout?")) window.location.href = "logout.php"; } If I just change confirm to jConfirm this not enough to make it work... Thanks for your help Lena function logout() { jConfirm('Do you really want to logout?', 'Logout', function(r) { if (r) window.location.href = "logout.php"; }); } EDIT for comments: function sid(id){ $_sidId = id; jConfirm("Delete System ID for " + id + "?", 'Delete Sid', function(r) { if (r){ window.location.href = "del_sid.php?id=" + $_sidId;

How can I disable javascript errors on “TWebbrowser”?

烂漫一生 提交于 2019-11-28 11:59:52
I am getting javascript errors popping up in some webpages I am browsing to. Does anyone know how to disable javascript error boxes from displaying in a Delphi app using a TWebbrowser? or any other messageboxes? Try to set WebBrowser1.Silent := True 来源: https://stackoverflow.com/questions/2722060/how-can-i-disable-javascript-errors-on-twebbrowser

Can Twitter Bootstrap alerts fade in as well as out?

 ̄綄美尐妖づ 提交于 2019-11-28 02:58:48
When I first saw the alerts in Bootstrap I thought they would behave like the modal window does, dropping down or fading in, and then fading out when closed. But it seems like they are always visible. I guess I could have them sit in a layer above my app and manage showing them but I was wondering if the functionality was built in? thanks! Edit, what I have so far: <div id="saveAlert" class="alert-message success fade in" data-alert="alert" style="top:0"> <a class="close" href="#">×</a> <p><strong>Well done!</strong> You successfully read this alert message.</p> </div> DivZero I strongly

jConfirm with this existing code

烈酒焚心 提交于 2019-11-28 01:25:51
问题 I need help to use jConfirm with this existing code (php & Jquery & jAlert). function logout() { if (confirm("Do you really want to logout?")) window.location.href = "logout.php"; } If I just change confirm to jConfirm this not enough to make it work... Thanks for your help Lena 回答1: function logout() { jConfirm('Do you really want to logout?', 'Logout', function(r) { if (r) window.location.href = "logout.php"; }); } EDIT for comments: function sid(id){ $_sidId = id; jConfirm("Delete System