I am using Struts2 and a bunch of Validation with Annotations. How do I add a global error message as well on top of field validation errors. Thanks, Fedor
I would like to import a CSV into Org-mode. Others have already asked about importing CSV to Org-mode tables. That's not what I am trying to do. I need to import CSV to Org-mode properties.
For example, a CSV like this:
Name,Tel,Mobile,Fax
John,11111,22222,33333
should become:
:PROPERTIES:
:Name: John
:Tel: 11111
:Mobile: 22222
:Fax: 33333
:END:
Do you happen to know a painless way to do it?
Hello.I am allowing a string to contain only alphabets and underscore,but is i enter fist character as alphabet or underscore and later if i put any invalid character then this validation is being done.I have done validation as follows:
function permission_validate()
{var permission=document.permissionForm.permission.value;var allowedStr=/[A-Za-z_]/;
if(!allowedStr.test(permission)){document.getElementById("permission_Er").innerHTML="* Required field can contain Only A-Z/az/_";
document.permissionForm.permission.focus();return false;}else{return true;}
I have a WF service with a custom activity and a custom designer (WPF). I want to add a validation that will check for the presence of some value in the web.config file.
At runtime I can overload void CacheMetadata(ActivityMetadata metadata) and thus I can do the validation happily there using System.Configuration.ConfigurationManager to read the config file.
Since I also want to do this at design time, I was looking for a way to do this in the designer.
My report has a parameter which uses a base enum. The enum has 4 different options to choose when running the report. How do I insert an option which uses all 4 at once?
For example, I have an enum named Phone and it has 4 types: 1 = None, 2 = Home, 3 = Mobile, 4 = Work. In a drop down, how do I add option 5 = None+Home+Mobile+Work?
Thank you!
and It's validated in XHTML 1.1 and WCAG 2.0 Guidelines doesn't have any info about it's use?
I know it's not valid in XHTML 1.0 strict but if many people using other ways like JavaScript, jquery, rel attribute, PHP etc.
Does it make sense? it means people don't want to follow validation rules. they just want to pass the validation.
I tried the reg expression
^([a-zA-Z0-9_.-])+@([a-zA-Z0-9_.-])+\.([a-zA-Z])+([a-zA-Z])+
for the email validation.
Since I want the user to allow submitting even with the empty email address.
So I changed the reg ex to
(^([a-zA-Z0-9_.-])+@([a-zA-Z0-9_.-])+\.([a-zA-Z])+([a-zA-Z])+)?
But this expression accepts any email address without any validation.
I ve connected my mobile phone to my PC and used this,
string[] lPorts = System.IO.Ports.SerialPort.GetPortNames();
and the result was an array of port names
"COM4"
"COM3"
"COM1"
"COM7"
"COM6"
Now,How to find which serial port is currently used/to which port my mobile phone is connected in c#?
How can I write regular expression in C# to validate that the input does not contain double spaces? I am using Regular Expression Validation. However I do not know what is the Validation Expression to get the result.
"white snake" : success
"white snake" : fail
Hi,
In one of my application I need to display all the Wifi and bluetooth devices which are paired to my mobile and it's Signal Strengths .Wifi side it is ok for me to display signal strength(RSSI).But i got a problem at Bluetooth side.I searched for the method which is suitable for this task,i found one method that is
intent.getShortExtra(BluetoothDevice.EXTRA_RSSI, Short.MIN_VALUE);
It is displaying only the new device RSSI which is not paired to my mobile.Is there any idea for getting all bluetooth devices RSSI.Plz give me idea or source code ?
Is there end-to-end voice encryption in GSM ?
If not, is voice communication between mobile handset and
mobile base station, at least encrypted ?
What keys are used there and which alogrithms ? any idea?
hi all
i am working on a project, it need email validation when user enter his email address check for availiblity. i wrote the php code in javascript it works fine but my problem is when some see my page source it display all user email address in javascript code. i want hide this one.
i wrote javascript code in seperate file but validation is not working.
if any one hide how hide javascript code in php, guide me plzz.
thanks
Hello Sir,i want to know how to calculate the accelerometer movement.When i place the mobile horizontally in idle state and similarly when i place the mobilein hands,So there accelerometer value change when it is place horizontally or while it is in hand vertically.How To Identify them,Any Sample Codes will be useful
Regards
Rakesh Shankar.P
Is use of position:fixed inside relative at some places ,Where content is not going to change, but are ok for Print, screen readers and mobile phone users?
or float is still better if we need good compatibility at Screen, print and for screen reader and mobile users.
Hello, I'm very new at USSD developing. I have a question:
Can I retrieve the IMEI number of a MS(Mobile Station) via an USSD PUSH Application?
The idea is to create an application that is pushed by the gateway, and is totally transparento to the Mobile phone user.
Can it be done?
Thanks for reading
This is the model with it's validation:
[MetadataType(typeof(TagValidation))]
public partial class Tag
{
}
public class TagValidation
{
[Editable(false)]
[HiddenInput(DisplayValue = false)]
public int TagId { get; set; }
[Required]
[StringLength(20)]
[DataType(DataType.Text)]
public string Name { get; set; }
//...
}
Here is the view:
<h2>Create</h2>
<script src="@Url.Content("~/Scripts/jquery.validate.min.js")" type="text/javascript"></script>
<script src="@Url.Content("~/Scripts/jquery.validate.unobtrusive.min.js")" type="text/javascript"></script>
@using (Html.BeginForm()) {
@Html.ValidationSummary(true)
<fieldset>
<legend>Tag</legend>
<div>@Html.EditorForModel()</div>
<p>
<input type="submit" value="Create" />
</p>
</fieldset>
}
<div>
@Html.ActionLink("Back to List", "Index")
</div>
And here is what get's renderd:
<form action="/Tag/Create" method="post">
<fieldset>
<legend>Tag</legend>
<div><input data-val="true" data-val-number="The field TagId must be a number." data-val-required="The TagId field is required." id="TagId" name="TagId" type="hidden" value="" />
<div class="editor-label"><label for="Name">Name</label></div>
<div class="editor-field"><input class="text-box single-line" data-val="true" data-val-length="The field Name must be a string with a maximum length of 20." data-val-length-max="20" data-val-required="The Name field is required." id="Name" name="Name" type="text" value="" /> <span class="field-validation-valid" data-valmsg-for="Name" data-valmsg-replace="true"></span></div>
...
</fieldset>
</form>
The problem is that TagId validation gets generated althoug thare is no Required attribute set on TagId property. Because of that I can't even pass the client-side validationin order to create new Tag in db.
What am I missing?
Hi all,
I am facing a strange problem.. may be i am overlooking something and not able to find the silly issue. Need your help! I have a Master page and a Content Page:
<form id="AccountForm" runat="server">
<div>
<asp:ContentPlaceHolder ID="MenuHolder" runat="server">
</asp:ContentPlaceHolder>
</div>
<hr />
<div>
<asp:ContentPlaceHolder ID="ContentHolder" runat="server">
</asp:ContentPlaceHolder>
</div>
And my content page has some form elements:
<asp:Content ID="Content3" ContentPlaceHolderID="ContentHolder" runat="server">
First Name: <asp:TextBox ID="fName" runat="server"></asp:TextBox> <br />
Middle Name: <asp:TextBox ID="mName" runat="server"></asp:TextBox> <br />
Family Name: <asp:TextBox ID="lName" runat="server"></asp:TextBox> <br />
Birthday: <asp:TextBox ID="birthday" runat="server"></asp:TextBox> <br />
Mobile Phone: <asp:TextBox ID="mobile" runat="server"></asp:TextBox> <br />
Alternate Phone: <asp:TextBox ID="phone" runat="server"></asp:TextBox> <br />
I also have the code for submit button in the content page where i try to retrieve the values from the form elements and persist it into DB. Here is the SubmitButton_Click code:
protected void SubmitButton_Click(object sender, EventArgs e)
{
log.Info("From Submit button: " + customerObject.first_name + " " + customerObject.family_name);
if (fName != null)
log.Info("First Name is not null");
log.Info("First Name:" + fName.Text);
log.Info("Middle Name:" + mName.Text);
log.Info("Family Name:" + fName.Text);
log.Info("Mobile:" + mobile.Text);
log.Info("Phone: " + phone.Text);
log.Info("Address:" + bAddressL1.Text + bAddressL2.Text);
Strangly.. i don't get any data that is filled into my text fields? Their objects are not null as well!! why is this behaviour happening? I am not trying to access elements in master page or other.. all the fields are in the content page.. only thing is there is no form element in the content page and the form element is in master page!
Thanks in advance for your suggestions and answers.
Abdel Raoof Olakara
I have a Telerik RadDatePicker, which I am binding to the SelectedDate property. I want this control to show a validation error when the default date set in the control is removed/deleted. I was able to achieve this, but the problem was that the validation error occurs only when Enter is pressed or when we click outside the control.
Is there a way tell RadDatePicker to update the source without moving the focus? (Tried UpdateSourceTrigger=PropertyChanged, but still it wasnt working)
if you look at this ipad application ( http://www.blackboard.com/Mobile/Mobile-Learn.aspx ), there is a slide tab named, "Dashboard." When you click on it, a new view slides out side ways. I'm aware that there is a split view that is new in iphone 3.2, but, I could not find anything on a slide tab or a side tab as implemented in this ipad application. How is this done?
I have a 'validate_on_create' statement in one of my controllers that I would like all of my seed data to skip. What are some solutions so that the create statement in my seeds file skips this validation. My current solution is commenting out the validation each time I run rake db:seed. Anything a little more clever?
Hi all,
i am working on a mobile application which needs to use bluetooth to send a file to another mobile device. I'm using Qt for symbian.
my problem is that Qt doesn't provide ready to use API for bluetooth.Only Qt extended(which runs on embedded linux) has API for bluetooth.
Do you have a clue to use bluetooth from Qt on symbian platform?
Thanks in advance
I am trying to change the background image whenever the document is loaded, and when it hits this point:
document.body.style.backgroundImage="url('../images/mobile-bckground.png')";
The page simply makes the background plain white. It is displayed like this in my javascript:
$(function() {
document.body.style.backgroundImage="url('../images/mobile-bckground.png')";
});
I have verified the image is in the right location, why is it doing this?
If I do
XPathDocument doc = new XPathDocument("filename.xml");
Does that load the entire document into memory? I'm writing a mobile phone app and the document might store lots of data that doesn't ever need to all be loaded at the same time. Mobile phones don't usually have too much ram!
I'm working on some HTML5 content to be included as part of an iPad app in a Web View.
As I understand it, Mobile Safari only supports SVG fonts, but my testing has show Mobile Safari to really struggle with SVG and the performance hit is a serious issue.
So... is it possible to put fonts in the App Bundle and somehow make them available to the webview?
What is the best practice for opening a map from the mobile internet explorer on windows phone 7? On BlackBerry you use a JavaScript method and on Android/iOS you simply link to a google maps URL.
I am planning to integrate the different ways of opening maps into my mobile geo javascript library and don't have a windows phone device.
http://code.google.com/p/geo-location-javascript/
Thanks,
Stan Wiechers