Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Connector CONDMEASUREMENT. I need to input data although show warning

Status
Not open for further replies.

Guest_imported

New member
Jan 1, 1970
0
0
0
Hi

My Name is Luis Alberto Miranda, I´m Chilean, I work with connector (mimsx.dll).

I need to input information about Condition Monitoring. although show warning message.

I’m write a visual basic program use class CondMesaurement

Dim MiBlock, Block As MIMSBlock
Dim MiReply As MIMSReply
Dim MiField As MIMSField
Dim MiRequest As MIMSRequest
Dim MiInstance As MIMSInstance


MIMS_Connect

Input #1, EquipRef, Fecha_Med, Hora_Med, Valor_Med, Tipo_Mon, Comp_Code, Comp_Mod_Code, Cond_Mon_Meas

MiBlock = gbMIMS.Blocks.New("Test")
MiRequest = MiBlock.Requests.New("Request")
MiBlock.Requests("Request").AddFieldNameValue "_Service", "CONDMEASUREMENT.Create"

MiBlock.Requests("Request").Instances.New ("Instance")

MiRequest.Instances("Instance").AddFieldNameValue "EquipRef", EquipRef

MiRequest.Instances("Instance").AddFieldNameValue "MeasureDate", Fecha_Med

MiRequest.Instances("Instance").AddFieldNameValue "MeasureTime", Hora_Med

MiRequest.Instances("Instance").AddFieldNameValue "MeasureValue", Valor_Med

MiRequest.Instances("Instance").AddFieldNameValue "CondMonType", Tipo_Mon

MiRequest.Instances("Instance").AddFieldNameValue "CompCode", Comp_Code

MiRequest.Instances("Instance").AddFieldNameValue "CompModCode", Comp_Mod_Code

MiRequest.Instances("Instance").AddFieldNameValue "CondMonMeas", Cond_Mon_Meas

Set MiReply = MiBlock.Send

The problem is that show the message “MEASUREMENT EXCEEDS UPPERS CAUTION LEVEL, CONFIRM”

I don’t know how to confirm…. What can i do ?

Is not a error message. Is a warning.

If you run the program MSQ345 can you review the message.

if press buttom “Save” two times you could save the measurement.

If you have any comment, let me know, please

Sorry for my bad English.

Regards
 
Hi,

On a general note, if you want to recreate the functionality of an MSQ using Mincom Connector (BOC), I'd suggest getting a snapshot of middleware (UI Connectivity) trace, of the MSQ's doing the function. With the "UI Connectivity Trace Level" set to low, the trace will include your block requests and the system replies. By following what the MSQ did, you can recreate a similar task.

Your specific issue, add the line as marked:

[SNIP]
MiBlock = gbMIMS.Blocks.New("Test")
MiRequest = MiBlock.Requests.New("Request")
MiBlock.Requests("Request").AddFieldNameValue "_Service", "CONDMEASUREMENT.Create"

' ADDED vvv
MiBlock.Requests("Request").AddFieldNameValue "_ReturnWarnings", "N"
' ADDED ^^^

MiBlock.Requests("Request").Instances.New ("Instance")
[SNIP]

This tells the system ... not to ReturnWarnings :) It accepts a "Y" Yes or "N" No.

Of course the system is generating a :~/ VALID :-0 WARNING :~/ !! So make sure it doesn't require user validation ... your probably doing something automated. LOL

You also mentioned another method. This is to repeat an identical "MiBlock.Send" (snip from code) command. The MSQ application's operate in a similar way when dealing with Warnings. In VB you can trap errors generated by "gbMIMS", and check the "gbMIMS.Errors" collection.

Thanks,

Peter.

PS In VB when you use this syntax:
Dim MiBlock, Block As MIMSBlock
MiBlock is a Variant not a MIMSBlock! mmmm Best to use a seperate dim statement for each var ... just being picky ;-)
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top