ppierce
Registered:1278089087 Posts: 8
Posted 1506008470
· Edited
Reply with quote
#1
I am using IronSpeed version 7.1.0.18271 I have 3 text boxes in play: EmployeeID EmployeeFirstName and EmployeeLastName I want to populate the employee name information after the EmployeeID has been entered into The EmployeeID textbox. I plan to use a stored procedure to accomplish this but I am not if I should put my code in the TextChanged tab in the designer as shown below. Is that the correct place for my code?
pinbot
MVP Consultant
Registered:1191322079 Posts: 968
Posted 1506011955
Reply with quote
#2
That's a perfect place. Be sure to set "AutoPostBack" to true on the EID field or the event won't be fired. By default it's False.
__________________ C. Bryan Patrick II
Iron Speed Designer MVP Consultant
Pseudo Consulting
ppierce
Registered:1278089087 Posts: 8
Posted 1506104506
· Edited
Reply with quote
#3
First of all I was wrong the project is in C#. I placed my C# code in the empty code block in the TextChanged()Tab and as soon I do that The tab changes color. Then when I build the solution I get these errors. Unable to compile application. GreenGenie\ShowGreenGenieTable.Controls.cs(82,13): error CS0246: The type or namespace name 'SqlConnection' could not be found (are you missing a using directive or an assembly reference?) GreenGenie\ShowGreenGenieTable.Controls.cs(82,38): error CS0246: The type or namespace name 'SqlConnection' could not be found (are you missing a using directive or an assembly reference?) GreenGenie\ShowGreenGenieTable.Controls.cs(86,42): error CS0103: The name 'textbox1' does not exist in the current context GreenGenie\ShowGreenGenieTable.Controls.cs(90,17): error CS0246: The type or namespace name 'SqlCommand' could not be found (are you missing a using directive or an assembly reference?) GreenGenie\ShowGreenGenieTable.Controls.cs(90,38): error CS0246: The type or namespace name 'SqlCommand' could not be found (are you missing a using directive or an assembly reference?) GreenGenie\ShowGreenGenieTable.Controls.cs(93,35): error CS0103: The name 'CommandType' does not exist in the current context GreenGenie\ShowGreenGenieTable.Controls.cs(96,40): error CS0246: The type or namespace name 'SqlParameter' could not be found (are you missing a using directive or an assembly reference?) GreenGenie\ShowGreenGenieTable.Controls.cs(99,24): error CS0246: The type or namespace name 'SqlDataReader' could not be found (are you missing a using directive or an assembly reference?) Any suggestion on how I can fix this would be greatly appreciated. I am new to Iron Speed and am trying to make some modifications to an existing app.
ppierce
Registered:1278089087 Posts: 8
Posted 1506106545
Reply with quote
#4
Okay here is an update I was able to correct the issues with my code. The project will now compile and build. However when I change the text in employeeID textbox the code does not fire. Is there someway to put a breakpoint to see if it getting to my code?
annaedson
Registered:1268328626 Posts: 6
Posted 1506174157
Reply with quote
#5
Just wondering - after you changed the Employee ID did you tab out of the test box? Also, for setting breakpoints I always use Visual Studio.
ppierce
Registered:1278089087 Posts: 8
Posted 1506439771
Reply with quote
#6
Yes I did tab out. I have opened the app in visual studio and placed a break point on the code added by the designer but the code is not being called??