Click here to Skip to main content
       

.NET Framework

 
AnswerRe: Adding a flash webcam photo capture PinmemberEddy Vluggen17-Dec-12 0:42 
GeneralRe: Adding a flash webcam photo capture Pinmemberlhsunshine17-Dec-12 1:55 
AnswerRe: Adding a flash webcam photo capture PinmemberEddy Vluggen17-Dec-12 2:01 
GeneralRe: Adding a flash webcam photo capture Pinmemberlhsunshine17-Dec-12 2:07 
QuestionRe: Adding a flash webcam photo capture PinmemberEddy Vluggen17-Dec-12 2:09 
AnswerRe: Adding a flash webcam photo capture Pinmemberlhsunshine17-Dec-12 13:49 
AnswerRe: Adding a flash webcam photo capture PinmemberEddy Vluggen18-Dec-12 2:01 
GeneralRe: Adding a flash webcam photo capture Pinmemberlhsunshine18-Dec-12 18:03 
GeneralRe: Adding a flash webcam photo capture Pinmemberlhsunshine18-Dec-12 19:18 
GeneralRe: Adding a flash webcam photo capture PinmemberEddy Vluggen18-Dec-12 20:40 
GeneralRe: Adding a flash webcam photo capture Pinmemberlhsunshine19-Dec-12 2:28 
QuestionSplitting a url PinmemberEl daniel14-Dec-12 22:02 
Questionpulling across value from list to display in view PinmemberxnaLearner14-Dec-12 5:58 
AnswerRe: pulling across value from list to display in view PinmemberxnaLearner14-Dec-12 6:49 
Im now using
bool isFirst = true;
@int remainingHolidays = 0;
 
@foreach (var item in Model.HList4DD)
{
    <tr>
        <td>
            @Html.DisplayFor(modelItem => item.PersonId)
        </td>
        <td>
            @Html.DisplayFor(modelItem => item.HolidayDate)
        </td>
   
 
   if (isFirst)
   {
      remainingHolidays = item.Person.HolidaysRemaining;
      isFirst = false;
   }
        
        <td>
            @Html.ActionLink("Edit", "Edit", new { id = item.Id }) |
            @Html.ActionLink("Details", "Details", new { id = item.Id }) |
            @Html.ActionLink("Delete", "Delete", new { id = item.Id })
        </td>
    </tr>}
        
    
    <tr>
      <div class="editor-label">
         @*   @Html.LabelFor(model => model.PList4DD, "Person")*@
        </div>
 
        <div class="editor-field">
       
             <form action ="/Holidays/Index" id="some" method="post"> 
 
            @* *WORKING VERSION**@ @Html.DropDownListFor(model => model.HList4DD.First().HolidayDate, new SelectList(Model.PList4DD, "Id", "Name", Model.currentPersonID), "--select--")
        
 
       <script>
           function updateFormEnabled() 
           {
               if (verifyAdSettings()) 
               {
                   $('#sbmt').removeAttr('disabled');
               }
               else 
               {
                   $('#sbmt').attr('disabled', 'disabled');
               }
           }
 
           function verifyAdSettings() 
           {
               if ($('#HolidayDate').val() != '') 
               {
                   return true;
 
               }
               else 
               {
                   return false;
               }
           }
 

           $('#HolidayDate').change(updateFormEnabled);         
           </script>
 
      <td>
      @remainingHolidays.ToString()
   </td>
               
             <input type="submit" id= "sbmt" name="ViewHolidaysDD" value="View"/>
              </form>
         
  <script>
      $('#sbmt').attr('disabled', '');
        </script>
 
</table>
 

the @remainingHolidays.ToString() 5 lines or so up from the bottom is saying it doesnt exist in the current context?
AnswerRe: pulling across value from list to display in view Pinmemberfrazzle-me14-Dec-12 17:41 
GeneralRe: pulling across value from list to display in view PinmemberxnaLearner15-Dec-12 8:28 
Questionproblem with relationships PinmemberxnaLearner13-Dec-12 2:45 
AnswerRe: problem with relationships PinmemberRichard Deeming13-Dec-12 3:48 
GeneralRe: problem with relationships PinmemberxnaLearner13-Dec-12 4:37 
Question[VB.NET 2008] DataSet and XML files Pinmembersteve_949661313-Dec-12 0:06 
AnswerRe: [VB.NET 2008] DataSet and XML files PinmemberEddy Vluggen13-Dec-12 4:28 
GeneralRe: [VB.NET 2008] DataSet and XML files Pinmembersteve_949661313-Dec-12 21:21 
GeneralRe: [VB.NET 2008] DataSet and XML files PinmemberEddy Vluggen14-Dec-12 0:34 
QuestionAssembly with different .NET framework versions Pinmembermarca29212-Dec-12 10:05 
AnswerRe: Assembly with different .NET framework versions PinmemberGerry Schmitz12-Dec-12 12:25 
QuestionUse A Cookie To Send PersonID To Different Page PinmemberxnaLearner12-Dec-12 4:33 
Questiondont allow user to select existing date PinmemberxnaLearner10-Dec-12 5:46 
AnswerRe: dont allow user to select existing date PinprotectorPete O'Hanlon10-Dec-12 5:53 
GeneralRe: dont allow user to select existing date PinmemberxnaLearner10-Dec-12 6:23 
GeneralRe: dont allow user to select existing date PinmemberxnaLearner10-Dec-12 23:26 
GeneralRe: dont allow user to select existing date PinprotectorPete O'Hanlon10-Dec-12 23:32 
GeneralRe: dont allow user to select existing date PinmemberxnaLearner10-Dec-12 23:46 
GeneralRe: dont allow user to select existing date PinprotectorPete O'Hanlon10-Dec-12 23:51 
GeneralRe: dont allow user to select existing date PinmemberxnaLearner11-Dec-12 0:21 
GeneralRe: dont allow user to select existing date PinprotectorPete O'Hanlon11-Dec-12 1:02 
QuestionRun through loop for week and dont select weekends PinmemberxnaLearner10-Dec-12 4:13 
AnswerRe: Run through loop for week and dont select weekends PinprotectorPete O'Hanlon10-Dec-12 4:31 
GeneralRe: Run through loop for week and dont select weekends PinmemberxnaLearner10-Dec-12 4:52 
GeneralRe: Run through loop for week and dont select weekends PinprotectorPete O'Hanlon10-Dec-12 4:53 
QuestionDeploying a Windows Service Pinmemberindian14310-Dec-12 4:09 
AnswerRe: Deploying a Windows Service PinprotectorPete O'Hanlon10-Dec-12 5:04 
GeneralRe: Deploying a Windows Service Pinmemberindian14310-Dec-12 5:08 
GeneralRe: Deploying a Windows Service PinprotectorPete O'Hanlon10-Dec-12 5:20 
Questionrun through startDate to endDate and add each record to DB PinmemberxnaLearner10-Dec-12 2:04 
AnswerRe: run through startDate to endDate and add each record to DB PinmemberxnaLearner10-Dec-12 2:35 
QuestionASP.NET Post Textbox After Button Click PinmemberxnaLearner9-Dec-12 11:15 
AnswerRe: ASP.NET Post Textbox After Button Click PinmvpRichard MacCutchan9-Dec-12 21:54 
GeneralRe: ASP.NET Post Textbox After Button Click PinmemberxnaLearner10-Dec-12 0:14 
Question.netframework Pinmemberzofi518-Dec-12 4:30 
AnswerRe: .netframework PinmvpDave Kreskowiak8-Dec-12 6:37 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.


Advertise | Privacy | Mobile
Web04 | 2.8.140709.1 | Last Updated 12 Jul 2014
Copyright © CodeProject, 1999-2014
All Rights Reserved. Terms of Service
Layout: fixed | fluid