TECHNOLOGIES
FORUMS
JOBS
BOOKS
EVENTS
INTERVIEWS
Live
MORE
LEARN
Training
CAREER
MEMBERS
VIDEOS
NEWS
BLOGS
Sign Up
Login
No unread comment.
View All Comments
No unread message.
View All Messages
No unread notification.
View All Notifications
Answers
Post
An Article
A Blog
A News
A Video
An EBook
An Interview Question
Ask Question
Forums
Monthly Leaders
Forum guidelines
albert albert
NA
524
0
committing to databaase without ',' but with '.'
Jun 10 2012 6:10 AM
Hi everybody,
I have this:
view - editing:
[code]
<td>
<div class="editor-label">
@Html.Label("Maandag")
</div>
<div class="editor-field">
@string.Format(new System.Globalization.CultureInfo("en-US"), "{0:0.##}", Model.Monday)
@Html.TextBox("Monday", Model.Monday.ToString(), new{@readonly = "readonly" })
@Html.ValidationMessageFor(model=> model.Monday)
</div>
</td>
[/code]
so I fill in the numbers as: 7.5, 8.5 but then in the Edit page the numbers will appear as comma's, like this: 7,5, 8,5.
And this is the Index page:
[code]
<td>
@Html.DisplayFor(modelItem => item.Monday) -
@Html.DisplayFor(modelItem => item.MondayHours)
</td>
[/code]
And this is the Edit page:
[code]
<td>
<div class="editor-label">
@Html.Label("Maandag")
</div>
<div class="editor-field">
@string.Format(new System.Globalization.CultureInfo("en-US"), "{0:0.##}", Model.Monday)
@Html.Editor("Monday",Model.Monday)
@Html.ValidationMessageFor(model=> model.Monday)
</div>
</td>
[/code]
Because if I go after the create page to the edit page the numbers are with comma's. So I have to fill in again the numbers, but then with dots.
THX for helping!!
Reply
Answers (
0
)
Cannot find Data Generator
Difference between trace and debug