Print Page | Close Window

Coping to Clipboard with GroupOrder Collection

Printed From: Codejock Forums
Category: Codejock Products
Forum Name: Report Control
Forum Description: Topics Related to Codejock Report Control
URL: http://forum.codejock.com/forum_posts.asp?TID=8241
Printed Date: 10 November 2024 at 2:09am
Software Version: Web Wiz Forums 12.04 - http://www.webwizforums.com


Topic: Coping to Clipboard with GroupOrder Collection
Posted By: Godzilla
Subject: Coping to Clipboard with GroupOrder Collection
Date Posted: 01 October 2007 at 5:57am

Hi

I am trying to Copy(over to the clipboard) the records in the Report Control with the first column added to the GroupOrder Collection - However I find that nothing is being copied across. Works fine if I don't have any columns in the GroupOrder Collections. Any suggestions on how to get around this..?

Thanks
Minan




Replies:
Posted By: sserge
Date Posted: 01 October 2007 at 6:18pm
Do you mean you select some group rows with regular ones? In this case them will be simply skipped when copying...

--
WBR,
Serge


Posted By: Godzilla
Date Posted: 02 October 2007 at 4:00am
Sorry Sergy - should of explained myself better..

I am doing all of this programmatically; so if I have a report without any columns added to the GroupOrder Collection and run the Copy function, which copies the data from all currently selected records to the clipboard, this works fine.

However if I add a column to the GroupOrder Collection and run the Copy function - nothing is sent to the clipboard..

Examples:
This is on a trigger for a Radio Button:

IF INT(RS-DisplayData:SCREEN-VALUE) = 1 THEN
   nvcom1:GroupsOrder:DeleteAll. 
  ELSE
   nvcom1:GroupsOrder:ADD(nvcom1:COLUMNS(0)).

so the user has the option to view this column as grouped or not.

This is the code I use to copy each row to the clipboard and build up a variable (as the clipboard is limited to 64kb).

  DO i = 0 TO nvcom1:records:COUNT - 1:
    nvcom1:rows(i):SELECTED = TRUE.
    nvcom1:COPY.
    cSel = cSel + CLIPBOARD:VALUE.
    nvcom1:rows(i):SELECTED = FALSE.
  END.

I hope this clarifies things...

Thanks again!
Minan


Posted By: sserge
Date Posted: 03 October 2007 at 5:26pm
Hi,

The code looks incorrect at least there:

DO i = 0 TO nvcom1:recordsrows:COUNT - 1:
...


--
WBR,
Serge


Posted By: Godzilla
Date Posted: 04 October 2007 at 4:19am
I managed to work away around this now.. I just delete any items in the GroupOrder Collection - Populate, copy the data across, and re-add the column back into the GroupOrder Collection and finally populate - the users seem happy with this
Thanks Anyway,
Minan



Print Page | Close Window

Forum Software by Web Wiz Forums® version 12.04 - http://www.webwizforums.com
Copyright ©2001-2021 Web Wiz Ltd. - https://www.webwiz.net