• Chuck
    1
    That you are probably tired of coding etc. And I have been messing around with AI -Copilot because been trying to insert a pdf file (Brisnet Ultimate past performance file) into my spreadsheet. Google Sheets and Excel have basically become interchangable. So.. the problem I am having is with the formatting for fitting purposes once the file has been downloaded and the scripts that do not show up in the sheet as they are in normal pdf.

    So went into AI Copilot and asked if there is code that can somehow make this automatic after I have figured out the formatting. I am just asking if it is possible as I just have a couple of questions, if somebody on here knows, or can help...it would be so appreciated because it has become the last step for me in terms of my own design. Once I can do this seamlessly, then for me I can build my macros for off the past performance and cut down on to where I only have to enter some notes. In Google Sheets they use an apps script which is a javascript and through Co-pilot they gave me a code which I have tried but I have no idea if it has deployed or not when I copy it to my Apps Script. The questions I have is this.? First of all here is the code.Create a New Google Sheet:
    Open Google Sheets and create a new spreadsheet where you want to insert the data.
    Name the sheet appropriately (e.g., “Brisnet Data”).
    Write the Apps Script Code:
    Go to script.google.com/create to create a new script.
    Replace the contents of the script editor with the following code:
    JavaScript
    function insertBrisnetData() {
    var spreadsheet = SpreadsheetApp.getActiveSpreadsheet();
    var sheet = spreadsheet.getSheetByName('Brisnet Data'); // Change to your sheet name

    // Assuming you have Brisnet data in an array called 'brisnetData'
    // Modify this array structure based on your actual data
    var brisnetData = [
    ,
    ,
    // Add more rows as needed
    ];

    // Insert data starting from row 2 (assuming row 1 is for headers)
    sheet.getRange(sheet.getLastRow() + 1, 1, brisnetData.length, brisnetData[0].length).setValues(brisnetData);

    // Format the data (e.g., date format, number format, conditional formatting)
    // Add any additional formatting steps here
    }

    AI-generated code. Review and use carefully. More info on FAQ.
    Customize the Code:
    Modify the brisnetData array to match your actual data structure.
    Adjust the sheet name and other details as needed.
    Run the Script:
    Save the script and run the insertBrisnetData function.
    It will insert the data into the next available row in your sheet:

    That is the Copilot copied verbatim.. I do not have the Brisnet file into array, I have been converting pdf file to csv file and then inserting into cells as a comma delimited. I have also taken a copy of Brisnet comma delimited data structure single file format.

    So, my question is I have copied this to apps script but once I have copied code ..where in the guts of the code, is where is the change made i.e.is the name of the file. Is there a way to write the code where the file again comes in seamlessly. If too much just say get lost...
bold
italic
underline
strike
code
quote
ulist
image
url
mention
reveal
youtube
tweet
Add a Comment

Please register to see more

Forum Members always see the latest updates and news first. Sign up today.