Think this should be a simple fix but can't find it for the life of me! Im using the below C# in a usercontrol which works great if i set a specific parent id in this example 1327 but i want the parent id to be a variable based on the option value from a select box.
Creating a new node
Hi all,
Think this should be a simple fix but can't find it for the life of me! Im using the below C# in a usercontrol which works great if i set a specific parent id in this example 1327 but i want the parent id to be a variable based on the option value from a select box.
<select ID="catagory" runat="server">
<option value="1327">June</option>
<option value="1384">August</option>
</select>
Document doc = Document.MakeNew(dealName.Text, dt, author, catagory.Value);
Any ideas?
Thanks
Pete
Nevermind cracked it just had to convert the string duh!
var numVal = Convert.ToInt32(catagory.Value);
is working on a reply...