February 2, 2010 at 8:49 am
We have an audit trail, but if you hit cancel it allows you to pass without putting info. Or if you hit the X in the upper right corner it lets you escape without make a choice as well. I need code the makes the user choose an option before continuing on.
February 2, 2010 at 8:58 am
It would be helpful if we had an idea about what kind of window you're talking about.
For best practices on asking questions, please read the following article: Forum Etiquette: How to post data/code on a forum to get the best help[/url]
February 2, 2010 at 9:03 am
Not sure what kind it is...here is the code for the section I'm trying to stop the loophole:
[/code]
:IF Len(aOLD[1,K])>0;
:IF Len(aNEW[1,K])<>Len(aOLD[1,K]);
cRS:="BOB";
:WHILE cRS='BOB' .or.Empty(cRS);
UserInput(350,20,400,240,"Reason",{"cTX,20,160,350,60,TEXT,Field "+aFLDS[K]+" was updated. Choose the reason", "cRS,50,60,200,80,CD,Reason,Entry Error,Sponsor Update,New Bottle,Additional TA Data Provided,Determined at Testing,Spelling Error,Comment Added,Determined at Testing"});
:IF cRS="BOB";
UsrMes('Warning','Reason for change must be entered');
:ENDIF;
:ENDWHILE;
:ELSE;
:IF aNEW[1,K]<>aOLD[1,K];
cRS:="BOB";
:WHILE cRS='BOB' .or.Empty(cRS);
UserInput(350,20,400,240,"Reason",{"cTX,20,160,350,60,TEXT,Field "+aFLDS[K]+" was updated. Choose the reason", "cRS,50,60,200,80,CD,Reason,Entry Error,Sponsor Update,New Bottle,Additional TA Data Provided,Determined at Testing,Comment Added,Determined at Testing"});
:IF cRS="BOB";
UsrMes('Warning','Reason for change must be entered');
:ENDIF;
:ENDWHILE;
:ENDIF;
[/code]
February 2, 2010 at 9:10 am
That's not a valid response for what I posted.
For best practices on asking questions, please read the following article: Forum Etiquette: How to post data/code on a forum to get the best help[/url]
February 2, 2010 at 9:22 am
Angela, what language is this code even written in? I don't recognize it. And while you might be requiring a reason for why a field was changed for audit purposes, how does that tie in with this forum (SQL Server 2005 Security)?
Wayne
Microsoft Certified Master: SQL Server 2008
Author - SQL Server T-SQL Recipes
February 2, 2010 at 9:22 am
I'm sorry I am self-taught on SQL here using StarLIMS which is its own version of SQL but does take most T-SQL commands. The StarLIMS is the front end client that I'm working in (MS SQL2K5 backend). Not quite sure what it is you're asking. I'm attaching a picture of it. Beyond that not sure what it is you are asking.
February 2, 2010 at 9:24 am
I guess I was thinking of it being audit....security...which forum do you think this fits in?
February 2, 2010 at 9:29 am
Angela S. (2/2/2010)
I guess I was thinking of it being audit....security...which forum do you think this fits in?
For what I have seen so far, none.
It doesn't look like you have some SQL-related problem, looks like something related to the vendor software. Anyway nothing we could ever help you with.
Try asking on the vendor's support site.
Regards
Gianluca
-- Gianluca Sartori
February 2, 2010 at 10:55 am
Angela S. (2/2/2010)
We have an audit trail, but if you hit cancel it allows you to pass without putting info. Or if you hit the X in the upper right corner it lets you escape without make a choice as well. I need code the makes the user choose an option before continuing on.
Angela,
After reading everything here, and viewing the image, I think what you need to do is to get into the language that this application was developed in. Most will have a "OnFormClose" event... tap into that to see if reason was filled out, or bring it back up.
But, as mentioned, this has nothing to do with SQL.
Wayne
Microsoft Certified Master: SQL Server 2008
Author - SQL Server T-SQL Recipes
February 2, 2010 at 11:22 am
like Wayne said, there should be an event for OnFormClose you cna use to prevent the form from being destroyed if a process has not completed; also, you should also have the ability to decide what kind form will be used;
in the example below, vb.NET changes a form from having the regualr minimize/maximize/close buttons in the right had to use a form with nothing at all if you change the ControlBox property; other languages might call it something different, but it is a property of any windows form.
similarly you can remove the min/max buttons with the MinimizeBox=false or MaximizeBox=false if the ControlBox = True.
Lowell
February 2, 2010 at 11:29 am
Very strange thing, Lowell, this post is considered harmful by google Chrome. It says http://www.stormrage.com contains malware...
-- Gianluca Sartori
February 2, 2010 at 11:44 am
malware? it's just my crappy dev site that holds all my ugly screenshots and script examples; i don't see anything wrong, can you pm me whatever you are seeing?
Lowell
Viewing 12 posts - 1 through 11 (of 11 total)
You must be logged in to reply to this topic. Login to reply