private short f_LoadWCMSGAreas(int lngMGroup) { My.MyApplication.Application.DoEvents(); modBSMiniRPT.MouseHour(); try { wcServerAPI.TConfDesc msgCONFD = new wcServerAPI.TConfDesc(); int Conf = 0; cmbMAreas.Items.Clear(); cmbMAreas.Items.Add(new clsList("(None)", -1)); Conf = wcServerAPI.GetFirstConference(lngMGroup, 0); while (Conf > -1) { if (wcServerAPI.GetConfDesc(Conf, ref msgCONFD)) { if (msgCONFD.name.Trim() == "") { } else { cmbMAreas.Items.Add(new clsList(msgCONFD.name.Trim(), msgCONFD.Number)); } Conf = wcServerAPI.GetNextConference(lngMGroup, 0, Conf); } else { Conf = -1; } } cmbMAreas.SelectedIndex = 0; } catch (Exception ex) { MessageBox.Show("Unexpected Error occurred" + Environment.NewLine + "Error: " + ex.ToString() + Environment.NewLine + "Message: " + ex.Message, "Unexpected Error", MessageBoxButtons.OK, MessageBoxIcon.Error); } modBSMiniRPT.MouseNormal(); My.MyApplication.Application.DoEvents(); return 0; }
public short PrepForMessage() { try { wcServerAPI.TMsgHeader wMSG = new wcServerAPI.TMsgHeader(); wcServerAPI.TConfDesc wCONF = new wcServerAPI.TConfDesc(); if (wcServerAPI.GetConfDesc(mvarConference, ref wCONF)) { if (wCONF.AllowReturnReceipt != 0) { chkRR.Enabled = true; } if (wCONF.ValidateNames != 0) { boolCheckValidNames = true; } switch (wCONF.MailType) { case wcServerAPI.mtNormalPublicPrivate: case wcServerAPI.mtNormalPrivate: case wcServerAPI.mtEmailOnly: chkPVT.Enabled = true; break; default: chkPVT.Enabled = false; break; } } if (mvarMSGID == -1) { txtMsgFrom.Text = modBSMiniRPT.BBSSysopName; } else { picMTools.Visible = true; switch (mvarEnumType) { case MsgWindowType.ENUM_EDITMESSAGE: ////Editing Message break; case MsgWindowType.ENUM_FORWARDMESSAGE: ////Forwarded Message break; case MsgWindowType.ENUM_NEWMESSAGE: ////New Message break; case MsgWindowType.ENUM_REPLYMESSAGE: ////Reply Message break; case MsgWindowType.ENUM_VIEWONLY: ////Read Only View picMTools.Visible = false; LoadMessageView(); break; } } } catch (Exception ex) { MessageBox.Show("Unexpected Error occurred" + Environment.NewLine + "Error: " + ex.ToString() + Environment.NewLine + "Message: " + ex.Message, "Unexpected Error", MessageBoxButtons.OK, MessageBoxIcon.Error); } return 0; }